Let’s take it as read that if you’re a seasoned Cocoa Developer and you’re considering using Core Data in your project, you probably should be using Core Data.
Why wouldn’t you already be using Core Data? I think there are two common reasons:
It is! Learning Core Data is like taking everything you know about database design and use, throwing away a very specific chunk of it, and then replacing it with unfamiliar-sounding words with not-immediately-apparent meanings like NSManagedObjectContext. It’s a hard framework to learn and your first attempt at using it is almost certainly going to suck.
Your project started simple, with simple data models. As the project grew, so did the models, and maybe you weren’t so strict with the MVC. So what? Rules were made to be broken, amirite? But now you’re spending a lot of time maintaining that logic in models. Getters and setters have side-effects, you need to be careful about what order you access properties in, etc.
Whatever your reasons for not already using Core Data (maybe you’re data model is really simple - take a look here), using Core Data might make things a lot easier for you when writing or maintaining your app. But when do you know to switch?
I’m just finishing up a refactoring job that’s taken 3 days; in the process of transition to using Core Data, I’ve noticed a lot of code getting deleted, indicating that it was definitely time to make the switch. This is code that shouldn’t have been written in the first place, but I wasn’t using Core Data. I’d like to enumerate some indicators that you should already be using Core Data.
(Naturally, I would never admit to ever having any of these in my code.)
The transition is also a fantastic opportunity to do things in your code that you probably already should have been doing, like the following.
When you’re done your transition, you’ll look back at how you were doing things before and wonder why you waited so long. I know I did.