Hacker News new | past | comments | ask | show | jobs | submit login
Build an iOS App on Heroku in 10 Minutes (heroku.com)
132 points by matttthompson on Nov 19, 2012 | hide | past | favorite | 27 comments



Looks very nice, but I have a feeling that it's like iOS Storyboards: Great for simple demo apps, but very painful when you have slightly more complex needs.

For example I don't know how it can handle the following (kinda conventional for a web app) situation: Multiple users, some are admins and some are regular users, with some shared "data" (like, an item for sale) between the two. Moderators can add/remove/edit items and edit/remove users, users can browse/buy items, etc. - I think if you're building an app like this, you really have to roll your own CRUDful server (with ruby or whatever)...

Oh, and BTW, RestKit[1] is probably much more mature and feature-rich than AFIncrementalStore.

[1]: http://restkit.org


> Great for simple demo apps, but very painful when you have slightly more complex needs.

Unlike Storyboards, the effort you put into writing against a REST API isn't wasted if you decide to roll a new, more complex REST API (which Heroku is fantastic for).

The whole point is to get the developer up-and-running as quickly as possible. Code for the API you'll eventually have, but get by with a rough scaffolding so you can experiment and iterate rapidly.


This is OT, but just in case there's a good solution, what were your problems with storyboards?


Sometimes the app is not a strict tree of view controllers, but rather a graph containing some cycles. It is here that the whole metaphor of the navigation controller and the visual tools that Xcode gives you to automate it kind of break down and you end up writing lots of hairy custom code to manage your transitions.

Sometimes things are presented modally here but get navigated to normally over there - and once again you're mixing metaphors, implementing some navigation in the storyboard and some of it in code.

I thought the same thing would be true with Auto Layout, but luckily that one seems to have been a bit more "baked" when it shipped, insofar as I've not had any trouble implementing complex views with it WITHOUT ever writing any code.


This seems like a really easy way for iOS developers to build/prototype apps with a cloud backend.

Is there any security to this or is it just good for prototyping? What's to stop me from requesting user accounts with passwords?


Probably not a great idea as-is, without some level of user authentication. I'm definitely working on a nice, integrated solution for that.

In the meantime, you can mount Rack::CoreData (https://github.com/mattt/rack-core-data), which powers the Buildpack, alongside other authentication middleware to create a workable production application.


Just as a general advisory, from AFIncrementalStore's README:

> This is still in early stages of development, so proceed with caution when using this in a production application. > Any bug reports, feature requests, or general feedback at this point would be greatly appreciated.

While it is a great library already, and built up from solid core frameworks, it has its share of bugs and rough edges!



This looks like competition for Parse (and a few others I guess, but Parse was the first one I heard of). However I have tried neither. Is there anyone who's tried both? What are their pros/cons?


I haven't used the buildpack, but based on working with Parse and watching the screencast, here are some guesses:

1) Parse is more full-featured. Parse includes significant automatic support for things like modeling users, comes with UI components for e.g. sign up, and includes e.g. a UITableViewController subclass to automatically support things like automatic paging.

2) While Parse's documentation is superb, these features come at the cost of flexibility (though you don't have to use all of them, of course -- it could just be a REST backend if you wanted it to be, like the heroku buildpack seen here). You'll tie your iOS app to Parse with PFObjects, whereas you're much more flexible with a backend agnostic approach that you'll get just using a REST web service.

3) The Heroku buildpack will probably tie better to CoreData. There might be a clean approach for this with Parse (when I used it I was pretty new to iOS) but I ended up having PFObject and Core Data representations of objects, which is rather clunky. Conversely, if you aren't using Core Data, this build pack wouldn't be helpful for you.

Some conclusions: 1) people who are learning to write iOS apps and don't have experience writing a web server should probably use Parse because it will be easier. It is my suspicion, as a few others have commented, that you will run into problems like "Oh, how should I deal with user accounts and passwords" that Parse will handle, but you'll have to figure out if using the buildpack. The buildpack comes with all the advantages you'd associate with Heroku -- other people know what those are better than me.

Let me also say that Mattt Thompson is an inspiration (check out his github and NSHipster.com, which are fantastic and foreshadowed this project) and I predict this buildpack will be as awesome as he can make it.


This isn't a purely technical pros/cons, but still a good way of looking at them both:

- They are both well backed (Heroku by Salesforce money/profits, Parse by great investors), have awesome founders, talented employees, and are both YC companies.

- Parse is pretty much 100% mobile focused. This is their bread and butter.

- Heroku is Polyglot and spans dozens of platforms on multiple OS's, with no real focus.

I think this comes down to where you run the rest of your stack, how tightly you want things integrated, and which service is the easiest to use and most reliable. Is mobile 99% of what you do? Parse is probably the best choice. Is mobile 25% of your business and you're already using Heroku for everything else? I could go either way here. We use Heroku and AWS to drive 100% of our platform, but we're also not mobile (yet). I personally know the Parse guys and they are outstanding at what they do and growing at a phenomenal rate, so when we do dive into mobile I'll likely be giving them a shot first.


I'm in the "99% mobile" case.

It seems Parse offers many nice features in addition to transparent-ish "cloud" persistence, e.g Push notifications, etc.

Heroku's approach is really interesting. The idea of building a db model from the CoreData model is (I think) really elegant, but: - I'll also need to write an Android app - AFIncrementalStore is more generic but Parse's specialized classes seem more "plug-and-play".

I'll try Parse first.


Parse is no longer 100% mobile focused: https://www.parse.com/osx

Parse is moving onto Heroku's turf as well as Heroku is moving onto Parse's.


ymmv but we had a lot of problems with extreme slowness and downtime when using parse, it made development a bear and we were only using it for some testing. We wouldn't use it in production after our experience.


I think mileage definitely varies! I use Parse on a large app in production (100,000+ active users) and haven't experienced any downtime or slowness. Although perhaps my use-case is different to yours. You should try getting in touch with the Parse guys, I've found them very helpful and responsive. Just thought I'd offer the other side of the coin.


So with this, is Heroku going after Parse?


This looks awesome.

What would you do if you wanted to create a web-app version of your mobile app as well?

Would you hook it up to the api that is generated?


Absolutely--you can use the same API without modification to write a web, Android, or Mac client.


That's cool.

Is there any examples out there on how to integrate it with a web-app as well?

What's the big advantage in relation to Parse? I love Heroku, but Parse seems like a really smooth solution for iOS/Mac.


I think this and Parse are cool.

This looks better for getting started quickly if you have a Core Data app. It should also be easier to customise although Parse can do more for you (user registration is built in) but you need to be on the paid ($199/month) package to use your own branded login I think.

Also I can't quite tell but it might be possible to take the Heroku buildpack and deploy it on your own servers so i think you would have easier options to migrate away without a rebuild. This is worth something to me.


One possible advantage would be to touch the ecosystem outside of Apple.


Parse has first-party SDKs for Windows Phone, OS X, iOS, JS, and Android. There are third-party interfaces for many languages (PHP, Ruby, etc). It's not an Apple-only solution.


Heroku is the platform of choice for thousands of iOS, Android, Windows Phone, (and mobile web, of course) applications.

This screencast was merely a demonstration of what a rapid iOS development workflow with the Core Data Buildpack looks like.


What do you mean by this?


I watched the video. How does one add user account support? For example to handle multiple users in your example task app.


As someone who is just learning how to be okay at testing in rails/ruby, this both amazes and terrifies me.


this is perfect timing. We just spent the weekend getting an app deployed on heroku for desktop view. thanks!

lumawake.us




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: