Monday, May 4, 2015

Time To Pivot

Progress
I continued to work with my different syncing test apps this week.  In the end I ended up going over a couple of tutorials on CloudKit.  Coupling this with some conversations I have had online I have come to the following conclusions:

CoreData+Sync is very complex and there is a lot of “magic” going on.  It works great when it works, but when it fails you are stuck.  Adding a framework like Ensembles helps, but it too adds more complexity.

I don’t like complexity in my software designs.  It is tough to develop initially, and tougher to debug a year later when you have to support it (and have forgotten what you did the first time).

I need a simpler solution.  Something I can see from both ends, both on the client side and on the server side.

If I assume a mostly always connected device, then there are natural points in an app’s lifecycle where it would/should sync with a server (i.e. app initialization/shutdown, object saving/deleting/updating).

So I think for my new app I will abandon CoreData all together.  In going over CloudKit I found it fairly understandable.  There is a lot of code to write, but if I design it properly I’m hoping I will be able to abstract out the “CloudKity-ness” and separate my objects from that.  We’ll see how that goes.

I think this is the first steps towards an app with a custom server.  Maybe in the end that is what I will end up with.  At least going this route I should be able to make that migration fairly easily.  I figure I could also use Parse if I chose to go cross-platform.

What I am giving up in this approach is all the SQL-goodness that a real CoreData solution would provide.  

I will also have to write a lot of low level code (but I think it will be straightforward). I’m still a little concerned about what happens when I get conflicts during sync-ing, but I think the solutions to those are solvable.

My goal this week will be to get my test app running supporting CloudKit and see how that code looks.  Hopefully I’ll have more on this next week.

Reading
I continued reading Spring in Action.  My goal is to complete it by the end of May. No work on the test app though.

News that caught my eye

Microsoft had it’s developer’s conference this week.  I was amazed at the HoloLens demos.  If they can pull that off, then the applications for that technology are HUGE.  It occurs to me that Microsoft is acting like a company that is “hungry”.  With all the cash they have that could make them a formidable force in the computing industry once again.  It will be fun watching this play out.  

No comments:

Post a Comment