Moving right along was a session on ember data with Igor Terzic. This session was a little tough for me to follow so I’ll do the best I can on the write up notes. Ember data is also something that is discussed a lot and that I understand but haven’t really had a chance to dive into as much as I’d like to so far. I think this affected my ability to follow the talk because the talk was partially on what’s new in ember data, partially on what’s coming soon, and partially on where it’s been in the past. I know it’s been an arduous journey for ember data to get to where it is today so I think if I knew a bit more about the ember data history, the talk would have been even better for me.
The speaker was super entertaining and his slides were interesting but the talk definitely jumped around a bit making comprehensible notes and distilling themes and key ideas a little challenging. So here goes…
Ember data is a framework to solve problems. It is a data persistence framework. All problems can be categorized into a quadrant. The axis are unique vs. common and easy vs. hard. Easier problems can be easily fixed which means they’re locked down less. The core principle of Ember Data here is that changes to the data api should not affect the app code.
All adapter and serializer code was rewritten in the past few months. And in the future, the idea is to continue to tighten up the api.
The speaker went through a few different core problems and whether they were easy, medium, or hard. First up was data transformation. Data transformation is an easy problem. It is easy but unique. The second problem is asynchronicity which is related to promised which have gotten better. Asynchronicity is a medium problem because it is hard but common. Now in ember, there is a complete asynchronous promise-based solution and in the future, there will be an even more tight api related to promises. Relationships can be synchronous or asynchronous. Additionally, in the future there will be an easy way to implement lazy arrays and all relationships will be promisified in the future. Ember data returns promise proxy mixin.
Next, we come to the caching problem. Caching is a hard and common problem. In this case, Igor discussed an identity map as a way to access records based on a type ID. The main improvement in ember data around this is a standardized data retrieval process which will lead to greater productivity.
Finally, locality is discussed. Locality is a hard and unique problem. This is basically explained as data coming in all the time from lots of different places. Basically, locality = craziness. Locality depends on your api data transfers, how the data is coming you're your application, etc. Adding relationships of things makes this issues even more complex. Ember data tries to change the relationship syncing problem. Now there is also more focus on the problems at hand.
More information here: http://emberjs.com/blog/2014/03/18/the-road-to-ember-data-1-0.html
29-Mar-2014 by Allison McMillan Read Time: Approx. 2 minutes