Modeling the App Store and iTunes with Ember Data

Video in TIB AV-Portal: Modeling the App Store and iTunes with Ember Data

Formal Metadata

Modeling the App Store and iTunes with Ember Data
Title of Series
CC Attribution - ShareAlike 3.0 Unported:
You are free to use, adapt and copy, distribute and transmit the work or content in adapted or unchanged form for any legal and non-commercial purpose as long as the work is attributed to the author in the manner specified by the author or licensor and the work or content is shared also in adapted form only under the conditions of this license.
Release Date

Content Metadata

Subject Area
I've spent the last six months mapping the entire data model of App Store and iTunes. The application I've created is like no other search engine in existence. It's 2014 and we're still searching for documents. Today, I'm debuting the next-generation of search, and it's built entirely with Ember and Ember Data. You're going to see how I did it, and why Ember Data was the prefect tool for the job. Expect code samples, anchored by examples of real use within a polished Ember application. I expect the audience to leave my talk energized, seeing the power of Ember Data, wanting to try it out for themselves on the web of APIs that are now within their reach.
Data model Correlation and dependence Right angle Videoconferencing Formal language Number
Web 2.0 Software development kit Mobile app Goodness of fit Code Web-Designer Software developer Boilerplate (text) Bit Data structure
Building Scripting language Computer file Code Connectivity (graph theory) Multiplication sign Branch (computer science) Number Preprocessor Prototype Goodness of fit Skeleton (computer programming) Computer configuration Software framework Touchscreen Software developer Plastikkarte Directory service Cartesian coordinate system Inclusion map Skeleton (computer programming) Moving average Quicksort Electric generator Sinc function
Web page Mobile app Logic Data conversion Mereology Regular graph Library (computing)
Group action Mobile app Touchscreen Software State of matter Multiplication sign Keyboard shortcut Data storage device Group action
Multiplication sign Videoconferencing
Mobile app Inheritance (object-oriented programming) Observational study Link (knot theory) State of matter Multiplication sign Keyboard shortcut Data storage device Video game Quicksort Resultant Connected space
Taylor series Structural load Multiplication sign IRIS-T Gamma function Directed graph
Mobile app
Web page Web application Touchscreen Mobile app Internetworking Multiplication sign 1 (number) Uniqueness quantification Software testing Food energy Number
Category of being Search engine (computing)
Data model Metropolitan area network
Group action Mobile app Software developer Code Connectivity (graph theory) Type theory Nachlauf <Strömungsmechanik> Data model Latent heat Type theory String (computer science) Single-precision floating-point format Software Data type Reverse engineering
Scripting language Slide rule Data model Mobile app Process (computing) Debugger Moment (mathematics) Social class
Mobile app Dynamical system Inheritance (object-oriented programming) Link (knot theory) Code Computer-generated imagery Data storage device Mereology Template (C++) Data model Type theory Medical imaging Data model Different (Kate Ryan album) Core dump Social class Code refactoring Iteration Aerodynamics Office suite Data type Routing Social class
Complex (psychology) Latent heat Existential quantification Functional (mathematics) Mobile app Different (Kate Ryan album) Data type
Web page Touchscreen Mobile app Game controller Context awareness Software developer View (database) Shared memory Template (C++) Template (C++) Uniform resource locator Spherical cap Term (mathematics) Single-precision floating-point format Revision control Social class Physical system
Point (geometry) Polymorphism (materials science) Serial port Code Adaptive behavior Virtual machine Electronic mailing list Bit Field (computer science) Type theory Personal digital assistant Different (Kate Ryan album) Object (grammar) Data type
Group action Identifiability Mapping Code File format Uniqueness quantification Content (media) Special unitary group Regular graph Mereology Type theory Category of being Data model Query language Software Histology Computer worm Table (information) Data type Writing Resultant Reverse engineering Social class Data type
Filter <Stochastik> Slide rule Link (knot theory) Serial port Link (knot theory) Structural load Parameter (computer programming) Twitter Database normalization Type theory Crash (computing) Data model Word Hooking Query language Hypermedia String (computer science) Hash function Flag Category of being YouTube Resultant
Web page Search theory State observer Game controller Group action Mapping Set (mathematics) Maxima and minima Data analysis Parameter (computer programming) Data model Population density Personal digital assistant Query language Video game Figurate number Identity management Resultant
Web page Data model Uniformer Raum View (database) Metadata Template (C++)
Web page Code Structural load Translation (relic) Template (C++) Partial derivative YouTube Descriptive statistics Template (C++)
Mobile app Information Structural load Multiplication sign Content (media) Computer icon Data model Hypermedia Logic Utility software Game theory Partial derivative Physical system
Web page Mobile app Server (computing) Information Multiplication sign Structural load Data storage device Amsterdam Ordnance Datum Web browser Rectangle Resultant Product (business)
Point (geometry) INTEGRAL Video game Selectivity (electronic) Abelian category Subset
Type theory Demo (music) Complete metric space Resultant
Web page Mobile app Touchscreen State of matter Software developer Website Freezing Hydraulic jump
Mathematics Different (Kate Ryan album) Musical ensemble XML Disk read-and-write head Rhombus Open set Hydraulic jump Number
the language I think the at the the the a right
OK assignments were god like now because it's I so yeah talk is modeling the answer with iTunes and modeling AppStore and iTunes number data it's an incredibly long title for a talk and yeah so who I
am I was a Rails developer of for many years like probably most people use started in web development last 5 6 years and I was quite productive with Rabin rails was able to make lots of good apps that were functional and you did the whole crud being very easily and I was happy with that way of working and dabbled in Sinatra in that was how I build apps later can became a Bakwin developer as a lot of people dead when that became the technology let me do things that I could not do with rails like structure my JavaScript code I deftly member googling around looking for a way to structure JavaScript code and finding you know just write a japery plug-in and that's structuring JavaScript and I wanted something a little bit more and I think way back when gave it to me and I built a large back app and that's why I really loved amber when I 1st
saw it and bath July 2012 I pulled this off the Wayback Machine and it's also the same documentation I've been referencing modern building the entire out I so it's been great and the I really like the be download buttons with the rounded Web 2 comma decimal 0 and so
I now member developer and that's all I do is amber development if I can do it I I I don't really pitch other options to people because that's where most productive I can churn out prototypes in hours not days in the code makes more sense you writing more direct to the UI as you all know and it's wonderful whether applications come over making an unwatchable about l last year since today of 2013 I I've probably written about 20 or 30 amber applications and you call number at you know a single component on the screen it switches between 2 tabs but written things that small and larger and doing so I made up making
this framework of topics with Member and it's a skeleton for brunch and branches of filled tool for JavaScript and CSS preprocessors in all sorts of things I'm branch is a really good tool because it's been around for a long time has a lot of community support in its super fast and so I use it for everything I use of my VM workflow I have a special plug-in that lets you create files or directories and starting so many brand new member apps you kind of want roll up these concepts and something and I've been using Topas of them broaden building thing Masche yesterday so when I another card
people it's that I agree with Amber and I like having that conversation with people about what it is amber does for your why do I think there is a muscular logic that technology and business part it is going to scare people but I think that conversations are really going to have because I think people get it you know it's weird when you go to an app and you click on a tab that's obviously part of the sub navigation and the whole page refreshes it's just broken it's like there's something wrong with this rise in the data libraries which the things and it's going to feel broken very center even regular users so that's a story that starts in
August 2013 and I would sit around and I have this brand-new app that I really like called launch-centre pro
emotional prose an iPhone app that lets you make shortcuts to make every action every day actions lightning quick and a stuff the business bequest saying just like pop it open and always works when you expected to you just you get to the main screen of actions you choose 1 your often running that's an awesome thing to have on a device you want your pocket hundreds of times a day and so I wanted 1 specific thing that I do all the time which is try the people software by
searching the app store so you probably want center you start up with the new action for searching the app store on your phone because you want to go in the AppStore happen-might wait for it to load and try to find the search by and and then clear out your previous search that still there because everything's states state so what you do is you
start up wants pro nucleic after research the typing your search which I always in searching for a new Burgess make sure nothing news come out that missed out on and this happens every single time and you see a got my search in there so it's really teasing me that something might have worked like it certainly seems like items of the abstract knows what's going on a travel more time to be
sure and then and this is I recorded this video last night's this isn't like something that that is not still have so and is to
prove that this is like actually alive in a connection I just like breaking this on purpose looks go and do the real search he looked on a complete it's certainly states can do something this time in results so that's study experience of you wanna shortcut search in the app store and like parents' so crappy like why can't I just pop open answer to make it work so I started thinking about it and I was like I don't solve this problem myself why 1st looking to see if the other solutions and there weren't any them and that sort of thing about what the experience is like to be shared something from the app store and I feel
like this is kind of the feeling you get its life all I love that you know where you see the result in Google and you know exactly what's been happening like that link is you get to dismiss
that nice dialog every single time of what is that checkbox do and does that mean I can never ever open up again there and then inevitably you get this guy is
very happy that they have I love this sink devices do something like you know anything like it's like socks
and it's terrible and it's you know obviously the thing that Amber is great at and so why don't we make something using those tools and it turns out that there is like an API frightens and there's like the website forever J. S so as like what's do this what's make something better and
so 3 hours later I got this thing and it is exactly what looks like there's no like to like text you can see it literally just shows the app titles and click on it and you get that
and it's like OK I've got like thing wraps the items API and by the way this is ridiculously easy to do with Embraer number data each fired up and you can make a wraparound symbiosis API and run them out of business with the energy of the ones I mean there are a lot of apps out there right for the picking of they have the eyes and they are not learning having 2 things with JavaScript web application technology in the sciences so I was
like That's it and upon giver pages to about my Internet dollars in starting to get you anything else and that's it that the that plenty of times it goes absolutely nowhere and you know it's like I use it in 6 other people do and I get 85 pull requests from 1 guy want to the 1 extra thing and that's about it so started thing about was like now this is like a lot bigger then this then the whole Ural thing is an important and I started to use my own app over the next week and I was like this is really compelling to have something to better that you can use every single device and not worry about popping up your friend down there in the tests are in the dock so I thought maybe it's and make a search
engine with and it's a categories a concept because usually think like search engine giant you know server that's going out and actually things and stemming and all this complex stuff and so it's
kind of like crazy you can see where this is going to this madness that the the
death of man yes but exon
of December member of Hamburg makes this easy like you know you can search you these of people they guys here every once a symbiosis done this better than why we take what they've done better and use ourselves so Beckett's us to like the data model and it's more than
just outside his action as a crack with a cell phone and I learned more and more about the items API over the last many many months than anybody should ever have to especially reverse engineering and not knowing all works so there's a
lotta data types and a lot of this data types have things in common and you wonder with a model them in a specific ways and use things like that where use common concepts between the not constant rewriting code it's not just like components you actually need something more granular than that so for me it all started with the type the is anatomy that every single Member data model gets automatically and it's the name of the model in a string and its unified based on the way you define the models names you Apr . hiding their iPhone app in your iPhone underscore Apple a type the
so I define a whole bunch of things up front ends so every single model knows a lot of things about itself but what astronomers a one-stop Brout path isn't CSS class always things which lets me do by magic things to define all these complex models and make them work with my app and 2
c no everything in this talk is in in coffee script of because it's like that's on the slide but that's why I'm using a script it's not because it's better than jobs script writing apps of I did what he did at that moment I'm
sorry I so you get to do things like this link to model name brand name and model and that's like working code and it will always work for Iverson woman models it will link to the correct name of the thing in the rout and I don't have to write like a custom template for every single thing they work for a reason I'm saying thing I do it for our generation iterate through all the models and then create the outstanding dynamically you might say what introduces dynamic signal for the 1st part of it was because then you have a dynamic segment at the front of all of you your else you have to wait past everything through and I had to issues of that has occurred rather have the rats be defined up front you might go refactor into dynamic segment have work out OK but I still like having a star at the front of your office that we're but CSS classes super useful because then you can just chunk those undertaking such as images of there's different types of images for having the app store and to customize the way the CSS look for those and by standardizing the names of classes I is Red assassin all inherit from this new things to add a new datatype its new class it's added mango and start not modifying without thinking about
so I the core model is the items item and it has your offer work image suffix which is like PNG careful these other things and price all the stuff that's common to every single thing on him store and so everything inherits from this item and
that's songs after all the different data types but they're still more than that a still more specific complexity in different situations and it gets pretty deepens the rabble
so but makes sense and of being a great tool for this in Nixon's let you encapsulate functionality into a little tiny piece you can include wherever you need it and so I mean makes sense for genre something's of genres why things do actually and specifically the interesting Mixon's are Appen review makes sense so the app
makes in terms of being into an app because Mac caps and iPhone apps iPad apps tenable share things but they aren't necessarily all descendants of an app class so that worked out well for me the review Megson's really interesting because that this means that B has reviews and by including this mix and through my out then the item automatically gets added to its template of the BN view reviews they want to be fetched from these separately the for reviews which we'll get into the 2nd year but it's a very powerful system where I can encapsulated the same exact thing exists in rails with concerns and it's a really great way to factor your code so that you don't have to copy and paste employs things in 1 place you try to do the controller something so it and so this
is kind the breakdown of differ Mixon's these things reusing because it turns out you can get reviews for so song because that's not even designed a page for a single song on iTunes you actually see the court's always in the context of a novel but absent movies have reviews and so you can kind of see how different things are easier this turns these Nixon's throughout the at there is a really interesting
stuff the really member data suffers the adapters serializes so if not familiar with them a data adapters or the bit of code that you make that's customer lets you talk to your point of whatever that is my case it's a lotta different points including items API the review API some private the eyes and and the serializes return that data into the stuff that Emberton is expecting so that it all comes in uniformly and you can use as objects cleanly so I teams has very promiscuous
data types but I mean by that is when you make a request to me that you don't know what kind of data you're getting back at you may actually get movies that we're asking for songs if you don't do things right were 3 guys having a bad day it really does happen but sometimes they just returned different data types for the same request and c have the humiliate filter them and so what I ended up doing was making serial as a for all items items in 1 thinks that others you realize produce have have 1 and it combines the notion of a classifier which machines a 2nd and then it's polymorphic so the it gets back a list of things and adjust we forever types and show that and say this is actually that based on the criteria that I've looked at and also support sideloading so that the things that its loading polymorphic we already bear so I ask for me don't make another request the items the it's odd even
loaded so the items class violence and like this and it just has these different properties that I know about the sun reverse-engineering the items API and figuring out what they call things internally they don't always use the same kind of identifiers to talk about data types so you end of having a light you different is the artist types collection types there's tons of other idiosyncrasies with the API but this can encapsulates all them quick lookup table and that makes everything really easily so I also gather results from other EPRI is not just the main items API and 1 of them is the top charts and top turds come in and they're in a completely whacked build up a different format than the regular writings API but the 1 thing they do have is the IDD unique identifier for that piece of data in items and so what I can do then is just load them all and as as items item results is what I call them and then I just say Give me my chart results in map by the actual results which will then go to make a fine many query to the actions API which happily supports multiple ideas that will resolve all those ideas and will figure out what the data types are so the end result is is that enough to write code the past the top shirts into a model that worked for me I can take the idea and let it be a 2nd request took turns out doesn't take much longer in about a couple 2nd request so me a bunch of but the big part is
relationships and tons relationships inside the data I map but their charter relationships rereading albums down the songs backed artists even child relationships that items themselves as an expose but they have data for and it's really easy to do with amber data and then I also met relationships from external API eyes that interesting to have what with your content
so I always load YouTube videos reviews when they're and run tomatoes for movies and what I do is I flagged those relationships as always love and this is not a
feature of a data meant this myself but it's a really simple mentation just looks at this flag in the serializes if it exists it's gonna set the links are to be for that name to true and what that means is that Amber data will then try to fetch that no matter what and I'm going to hook into a later to give a dynamic world based in the name so the way I get you to be a results is I need to make a query to the U 2 maybe I so I wait for the model the load from iTunes I get its name using my custom logically the filters stuff out the name of items does weird things the name and then eventually I'm going to make a query in the adapter is going to see that I had a your Alekhine that was in a string as a remote your and so I just say give me the relationship he your out name that I said in the previous slide as you 2 results you're out the thing was called you to results noticing you're all they're going to that shit based the custom parameters for that model and then I'll get you to results that thing and also lets new stuff like gym in the media types that you don't search for crash and get no results for the movie crash word movie in there I can customize it that tweet all the results for everything so you get relevant results for this research so pagination is another
really hard thing to do with a data analysis not built
and and I built my own model for it hold the Thatcher and it handles all these things for me automatically so it make sure they never go past the maximum results that because the different the eyes and of how much like how many results they possibly provide me and I don't wanna make Greece constantly about citizen of the EPI they under overlooked some happen and that does our result detection so if I get back less results that I ask for I know that must be the end of the data set in my fetches very specific to the fact that I and using it another person's API that have no control over so I have to be kind of a Boston like can where cases things like that but I do do in a density map which is a concept that Member data users to keep a single copy of every single model and I do the same thing Thatcher said if you happen to back up to a previous search the federal will still be the same 1 as the US the search that took place before the results will be instantly load right there and as well since it has a unique ID I can do things like say you were looking at 3 pages of results on the show you 3 pages of results in the 4th pages still down there waiting for you preloaded dispatcher and the defining the controller based on the query parameters of persons set up as the might said show me movie results and that's were belongs said to me what a figure that out I hadn't searched and search model and I was doing observers to switch out the data manually arose isolate this was a trawler once group GM new moved the controller me my life a lot easier MIT set preloads results so templates this is can getting to the
end of the technology used to build the whole stewardess see it pretty soon I'm than
apostles that's what I call what I'm
doing with the different views that I'm using for the items items so each the pages base the template for templates and you can fill in the blanks however you want there and the idea is that the model can upfront say I want a custom template for my metadata 1 section or from a metadata to section that we're not writing a template for every single that i've only customizing the pieces that I want because you want to save your a uniform on people navigating so metadata 1 can be filled and stuff and it's very easy to write this kind of bad
code you just basically is the final method that's temple the fall and if it exists in the dot templates then it's very use it if not you fall back to the base 1 that's just a generic template might be empty and so for movies I just define a few different templates and now I get this customized
experience where he movie and surround made a stories see the duration and see the description using YouTube videos that all the men from those 3 little partials and page loads up but we find the same thing
happens of apps and I actually share the logic in the so that old appetites can share the same partials and so you'll see that anger
birds loads up and shows kind of the content there in the different genre all that kind of information the same thing with a mac act that shows up those it's blanks puts the icon and handles all stuff so what I built was this robust system for modeling their API and the working for a really long time and I've been using it every single day
so when we don't know both
something it's better than this that's for sure that you don't wait for it works on all devices and it's really fast and it's cold find no vowels
because cool and it's the neural it
and it creates a beautiful Urals slogs you can share with your friends and loads up faster than iTunes a server rendered pages ever could the Atkison of the Dana the went very well of it works on all devices and so you can access the here and device just as easily it's not gonna pop open the app store there there is no that would send its in the iPhone will open up in the web browser and they can look at and decide if they wanna look at it it's incredibly fast and it's faster than the native app for user many time it's definitely faster than that of and the most important thing is that it's a product search persons like a document search so if you're looking for a nap you go to Google Research in trying to find this 1 specific thing you know about looking for that rounded rectangle front there and it's great for finding documents but it's not good for finding products and this is the idea of fine is that you find the product 1st you're getting there and then I give you the relevant information about the products was give you 2 results reviews anything else I can point about the app so you are looking through all this stuff sifting through these Urals to something that's meaningful to you and this is the logo for it
and the I didn't forget once a pro
and which was the whole point of this so
there's an integration for life in a pro and you just tap that button and adds selection a pronated search Find from there and it is probably coast on
DigitalOcean which I had not been paid for but will accept payment for that's it find
I give you a demo of it after they see
so here it is Simon search for Angry Birds missing in getting as you type of completions there from some unknown API and it back
results pretty quickly as already preloaded might have been there and browse through them click
Carnap here and you're seeing everything would nonconference Wi-Fi pretty fast look at a
screen shot from back but the but the
actual website for the 1st it created the app
freezing where i jump to the
developer page on find and see all the apps they've ever made and pray that conference Wi-Fi will eventually be say that but that's pretty awesome and jump into another app seeing loading states for everything
and little pop and all that it has a gets of the different API it's using but months to go 1 quick thing jump to the top charts and you can see here that I've the most important piece of a number of which is a multiple select the changes setup blues songs and music and so that's 1 and the head of the things that the and the and of the the I think the a of a a


  447 ms - page object


AV-Portal 3.21.3 (19e43a18c8aa08bcbdf3e35b975c18acb737c630)