Bestand wählen
Merken

Implementing basic GeoCouch support in Couchbase Lite

Zitierlink des Filmsegments
Embed Code

Automatisierte Medienanalyse

Beta
Erkannte Entitäten
Sprachtranskript
this would be the
minimum womb I'm room of my my see my cerumen MWU my name womb my my mind and see my the but
the people and the use and and the the in thing is in the in the in the in the and and the and we know that the the the and the and the you that is we need the and it is probably the most in my and and
we know that the and everybody so I guess it's about time to get started out as a short talk at the game plan for about 20 minutes so hopefully this
will be the Q & a of the abandoned my talk here I guess sort of the headline and new from from my talk descriptions on the show you how we implemented the geo indexes released started implementing the geo indexes that we have in the version of couch Baselight for IOS and so I will show that but before I do that I'm and show a couple other things
and so on I'll give just like it as quick as I can make it an overview of how the and catchphrase mobile components that together so you'll see you know from the outside what is really looking at the source code of the inside of I and then I'll do that AP I roadmap for you know for this event to show off because I wanted something just as basic as could be to do a little bit of GO working and utilizes indexer and I also want to Chancellor swift so I picked it up like on Monday and started typing in got something good enough to show as of last nite of so that don't the you would pass AppStore review with its and you know it it's sort of the tricks all show that off and then I'll show the implementation of well at least I started and maybe title bit about my open source of implementation strategy in general for getting things to happen so get answers to jump right into account space mobile is an umbrella term that we have for the 3 open source Apache license of components so touch base light runs on I Android or anywhere you can run on the JVM that and it is a database you don't need to data is local 1st just working always with this local data in your hand that handles the network for you talking distinct gateway which is sort of doing the job that an application server might typically do uh and on the back and catchphrase server is what ck wages for storage and as far as you know the alignment of the stars or whatever it could be other stuff of which it happens you catch this server for storage of to and so it's a sort of a flexible way to town tell the your is useful stack where the data should fall along a little bit about that other data flow control we have uh but a little more catch this light will run up would targeting instead of running all places that you would run you want to run on mobile database so if you're doing some kind of remote data collection app at will run on a platform that's in your remote teams hand already uh from expanding our platform lists all the time uh as far as what you want from it as a developer it speaks Jason so no more scheme was you just putting J. Song objects in the database and then defines indexes over them it's all written in Objective-C or Java depending on the platform we also version of it written in . net so the goal is to use light weight is a can for the platform that and also take advantage of of all the security features of the platforms offer uh just so so I can kind of like everyone's had space and distributed systems but you that were actually working with or talking about having a database this on a mobile device uh real look a little bit how the conflict resolution and conflict management works in couch baseline and this is also the same as how works in a practicality be for cloud during the other uh sort of compatible document databases and where you see here is a tree that represents the history of this document over time and so what happened was originally was just nickname and a phone number and the names started to get filled out some more details of in the next revision and the more you know the 1 way you see they are 2 different devices have a document hand and made different changes 1 change the name and added an e-mail address and the other 1 deleted e-mail address so who's right how do we uh you know how do we decide what and so I a lot of databases will throw out or forced you to make that decision on right now instead of a light to defer the decision until later but instead what we do is we store the leaf nodes of for any of the branches of this tree indefinitely until you resolve the conflict of so that means that you can say 0 this is the kind of conflict you know gets generated almost machine rate so I should have some in a special back and process it's merging these or this is the kind of conflicts that can really only be merged by having a person look at it and so all the right code for a managing these conflicts that had around mobile device so that's just an example of the kind of thinking you gotta do is here you have people collaborating on data when they're not necessarily connected with each other and it's sort of the handling all that stuff right but is is all we do you don't have to worry about the network and its kind of you know it gives you an abstraction layer hopefully the means of this is almost never comes up but when and as you you know that we've thought through so seek way is the component that sits in the cloud and handles the some replication but that also some the other more application level concerns so who's allowed to see which document but as far as the documents come into the system and they are routed to essentially these named streams and then uses a granted access the streams depending on your business logic uh was also validation so you can say 0 no sorry you're not allowed to update that document or you know that phone number needs to be in a valid form the and so just a little illustration of what channels look like or you got a channel for sports like losses in news reading out another channel for services go another channel for nature and you can see some devices or subscribe to some you know all different overlapping groups of channels you can also have but channel for admins and only allow certain users access to that channel and this is the part where guests new interesting for a group that maybe you know doing geodata in you know in the world uh we've got users who are doing a pure peer-to-peer so maybe the devices connect directly to each other when you're out in the field of we've also got users you're doing hybrid aware it when the devices can you uplink them that go back to the cloud and you our goal is to make it so that you can decide those sorts of things later but you know you can have your application logic BT couple from your replication logic and I will get into these details too much but just to show the uh you know the whole surface area for the clouds either application of the idea is that we can get it into a a single page of code and so you know this isn't like some idea Lapeer but even if you know the more complex example applications that we've built that have had you know but 3 or 4 different schemas as far as document types in the application you still have the full of in a cloud sigh routing and access control for all the data in an application in you know less than 41 the JavaScript by using this so I don't know what it would look like but I can imagine is nearly all Facebook being you know a thousand 2001 the JavaScript areas like this but it does force you to rethink some things and and do some work in the background to that you would otherwise do synchronously but I will skip that and and will skip talking about the storage
layer a and a couple of ideas of what people are doing with it like in campus learning where you can also in collaborate in the classroom takes of homework when you're offline come back together sink maybe even seek constant student when you're disconnected and so if a campus is a role in this sort of thousands of students this year pixel is using uh it essentially for sensor data collection so that cameras mounted on embark rights and also like a screw meter and in recording how much fun people are having a so that they make and you know sell them pictures of funding Facebook app or something Microsoft and I did a little they helped us with our launch event but the little demo of a purely serverless messaging technology based on a touch base and pouch TV that we saw some of earlier today all all wrapped in tore for and running on Android phone so that was pretty cool to see that in for my yourself so now hopefully
this'll work out for us and I've got this about the right amount and showed off something together demo up it essentially just takes all your pictures and sticks them on a map and and that's not like super duper groundbreaking work but yeah it was kind of nice to but believes in the database in the middle and I'll show some of the some of the benefits that so before I actually launch the out of hand of walks through the main functionality code so that when you see the apple doesn't solve all the support and so the 1st thing we do
in encoded when the apple as we set up couch based light and in swift that's you know not too too difficult you get a shared instance of this and this manager object it wants to you know live on a main thread and watch out for some errors and you know by in call this whatever you want the and it around in your app so views and sinker than the 2 other little pieces of set up that we do and the views here at the bottom of this religious this 1 view that I wrote to say hey that document has latitude and longitude let's index it as a G 0 point so here you can read all this code that there's no a link to the EPA's upon get up and stuff so you really get to later but essentially what's going on here In the bottom market code is that we just had to find a function that when it's passed a document if that document is 1 of these geotagged documents it tells scotch base like to put it in the geo index but see how you could have here geo in whatever format and then map into the correct format at runtime essentially so that you know you have documents all different kind assume showing up on the same map for instance but in this case is just a real simple because I and many document for each photo with the latitude and longitude and then this this other block code here all I'm doing is telling it to synchronize with a you are all of a server that's running sink anyway and so that's like the extent of the me having to worry about the network the to the application is enough to make sure you know that I know that you are 0 so now we can import the photos we've got enumerate the assets which it doesn't look like a lotta code but it was a super well documented for swift so I had to figure that out and to go out again but at the end of it all you've got an asset that you can pull image off of as well as with the Exif data and pass out the latitude and longitude it's already in all camera images so the other little bit database work that I'm doing after I've got it is to put the properties into the database and then attach the image to its also you that here so I'm just making a dictionary of latitude and longitude and I have the I saved version of the document and make 1 more change to it by a attaching the J peg data so that I got from the apple military and so the result is that I get these pictures on the map of and the way that i populate that is I give couch Baselight 80 bounding box and I say give me back all the points inside this bounding box but so we've actually got a query and all get into the details but what's happening here is known this this what the code here subscribing the the the application to changes to the underlying database so that any time a new point is written will automatically the queries you don't have to subscribe the database and let yourself the and then the bounding box itself is a little bit tricky because you've got to calculated from the visible map rectangle and this is probably like a whole bunch of projection mass that some people here really think a lot about thank you for thinking about had them all I had to do a struggle which was the top corner interest the bottom corner for a while and so every time the user moved to new region this code gets called it refreshes the bounding box all I've got to the library and the and then we actually refreshing we have to do this 1 little called manually which I think is a bug in the library should be Bolivar but so that a a sort of the
idea now and see what happens if I the but try to run it and so on of got sinking gateway running I've got it the all pointer back the many years really good screen here like the actual stuff so there's a way the and the ad 1 chain and it just
calls a couple of local photos out but they were already on a simulator and so hopefully assuming the network reachability is all happening properly organisms from sink for free to chat examining the a despite the scary error messages well you can see later in the coming out from the following all it was once the acts it found the URL did the same guy automatically only when the server the server pushing down to the to the simulator client that a library refreshes itself and draws a map with the with the new points and the so it yeah that's about as much buzz as they get without writing from you know any any tricky Alaska of so yeah if anyone wants to make it so that when you take a picture and important right away instead of having it with the new wanted like that would be a pull request of so let's see the and then I want to give the hopefully this next
implementations slide um so this is called the actual death of the 1st Committee the implemented at the original bounding box search in countless late IOS and so you can see down at the bottom that were executed in a actually a sequel statement were inserting points into a table and so we're just inserting that X and y then then later on we're going to query those with the bounding box as the but you know it's basically in the where clause and the and it was as simple as this radius took about from the time between when we got there and when much got their of active on and to get this up to where it was you know this much code enough test to prove it worked on and it's not the you know we need more than that to do what I showed you because it's been upgraded since then to where the geometries they get index you know actually boxes themselves instead of just points a and you know that kind of stuff you'd expect the then new wanna like you put a real G. layer on top of and you know for the sections fancy stuff to do what got us to go down that path and this is kind of a guess that the open source lesson is that this is probably the smallest possible patches it could get into a pull request that you with its own tests and might get a feature over here like throwing how real also the community can start dumping of bonanza him using this even though it was a toy like if it was real bounding boxes that real users so and so I you know I considered like doing of the whole movie of all the commits that came after this because you know the just the commit messages from all the Mexican after this is way more than the code that is it started and you know it's like got a proper G adjacent passer it's got from the deleted handle more than 1 kind of input geometry and that all things it should have but uh if you you know she'll get started and then you get there so maybe number lesson from that is still find some project the which had Geo support and Paggio support and who knows all happen in the end it might not even take that
that if you know who are interested in in doing this stuff developer . couch base . com but will get you to this page
that has all the good stuff for a getting started end hopefully you find it to be you know easy-to-use from GEO perspective uh the geo stuff is all right only officially on silence opponents of that's why if people are using Dominican down also then we get it everywhere I so yes I think you any questions
this if the thank you develop of the so obviously you know
musicals bottom sequels fairly new and especially midges world or have you had any experience or known of you know for example right now we have a larger set and posters of I haven't seen very many examples like tools you know so you have this data encounter space but 1 of the extracted of a given by some of the and experience yeah that's a super point so we had an early wave of of adoption with an Apache cash abuses that using it for geo data and civic data I was good for America and there is in Portland there's pDx API and civic API that was essentially just and some volunteers who it imported by different and not just post yes but all kinds of digest aunts and adjacent format and the reason why they were excited to do that is because once you have it into Jason document database that can sink the becomes and you know that becomes a tool that you can actually we used to provide services with so for instance if I want to do a mobile app of for you know the to the you where all the wheelchair ramps are sidewalks and I would have a really high level of service for that dataset and maintain on you know my on high-capacity servers because you know I have users ages support them but it allows me to do not to rely on a volunteer to refresh the import from the city and so you know whatever the city does a new data dump and I gets updated then you know the copula here is essentially automatic so there's a whole ecosystem of people who are using it for that reason I mean did you find people put up with them you know Leicestershire GeoTools just because the data sharing tools so but it will the the we people's write their own scripts in our own formats all the time if you can just on format and the synchronizing database and moving it around you get for free as long as you're not talking to you about what it was the a Chris very nice some presentations and I have a lot of questions but under the limit myself to 1 and that is how we if you have a a serverless wants aerial hard you pass the the information about the other clients on no honey keep them knowing who the other people are this is super hard problem and 1 that we we point on actually so when you see people using it today there either you running their own In essentially directory service somewhere around so people using it for in-flight service will have you know 1 well known IP address a DNS server something that does that work but more the Microsoft case they're letting toward you that work of store as a directory service to rate degree Project Christmas apologies if you answered some I was daydreaming but on the covari apps in the App Store currently that we could look at other end of poverty in the works that you can download and play with cells yeah there's a there's a bunch of stuff in the App Store but I'm not aware of anything is using the GEO stuff in the App Store so there is our to do light to do tracker is reference from the documentation that we've got the AppStore but there's a bunch of stuff if you look on the couch face like in the wild get wiki so this is you well there's probably a dozen things of going to from there for a long time and then you know at least of dozens more there are even neural in that wiki the I think the the infinite campus is uh probably in if you wanna see something really full-featured there is in the App Store
I'm not sure if you need to talk to me mean and usually like cell 2 of 2 distributions so you
the links thank the
Lindenmayer-System
Streuungsdiagramm
Hypermedia
Einheit <Mathematik>
Extrempunkt
Computeranimation
Retrievalsprache
Spieltheorie
Automatische Handlungsplanung
Computeranimation
Retrievalsprache
Bit
Einfügungsdämpfung
Prozess <Physik>
Natürliche Zahl
Adressraum
Applet
Gateway
Versionsverwaltung
Gruppenkeim
Kartesische Koordinaten
Komplex <Algebra>
Raum-Zeit
Computeranimation
Übergang
Homepage
Netzwerktopologie
Deskriptive Statistik
Streaming <Kommunikationstechnik>
RPC
Prozess <Informatik>
Datenreplikation
Bildauflösung
App <Programm>
Synchronisierung
Datennetz
Abstraktionsebene
Datenhaltung
Computersicherheit
Mobiles Internet
Nummerung
Quellcode
Ein-Ausgabe
Ereignishorizont
Entscheidungstheorie
Arithmetisches Mittel
Zugriffskontrolle
Dienst <Informatik>
Datenfeld
Funktion <Mathematik>
Rechter Winkel
Automatische Indexierung
Strategisches Spiel
Server
Message-Passing
Maschinenschreiben
Facebook
Gewicht <Mathematik>
Hyperbelverfahren
Mathematisierung
Digital Rights Management
Implementierung
Zahlenbereich
Term
Räumliche Anordnung
Systemplattform
Mathematische Logik
Code
Konflikt <Informatik>
Knotenmenge
Bildschirmmaske
Flächentheorie
Datentyp
Gateway
Zusammenhängender Graph
Softwareentwickler
Speicher <Informatik>
Open Source
Verzweigendes Programm
Systemverwaltung
Validität
Einfache Genauigkeit
Peer-to-Peer-Netz
Datenreplikation
Physikalisches System
Datenfluss
Quick-Sort
Objekt <Kategorie>
Flächeninhalt
Mereologie
Gamecontroller
Streuungsdiagramm
Maschinenschreiben
Facebook
Demo <Programm>
Stellenring
Multimedia
Virtuelle Maschine
t-Test
Code
Computeranimation
Datenhaltung
Unendlichkeit
Physikalisches System
Spezialrechner
Modul <Datentyp>
Datennetz
Meter
Digital Rights Management
Mobiles Internet
Peer-to-Peer-Netz
Lineares Funktional
App <Programm>
Zusammenhängender Graph
Motion Capturing
Pixel
Synchronisierung
Datenhaltung
Telekommunikation
Quick-Sort
Ereignishorizont
Eingebettetes System
Rechter Winkel
Resultante
Retrievalsprache
Offene Menge
Bit
Punkt
Versionsverwaltung
Kartesische Koordinaten
Gerichteter Graph
Computeranimation
Spezialrechner
Minimum
Punkt
App <Programm>
Lineares Funktional
Sichtenkonzept
Datennetz
Synchronisierung
Kategorie <Mathematik>
Installation <Informatik>
Datenhaltung
Ruhmasse
Abfrage
Systemaufruf
Verkettung <Informatik>
Automatische Indexierung
Server
Dateiformat
Projektive Ebene
Instantiierung
Fehlermeldung
Quader
Mathematisierung
Digital Rights Management
Rechteck
Solitärspiel
Räumliche Anordnung
Code
Datenhaltung
Digitale Photographie
Programmbibliothek
Gateway
Maßerweiterung
Zeiger <Informatik>
Bildgebendes Verfahren
Touchscreen
Konfigurationsraum
Thumbnail
Mathematisierung
Rechenzeit
Indexberechnung
Binder <Informatik>
Quick-Sort
Programmfehler
Data Dictionary
Mapping <Computergraphik>
Objekt <Kategorie>
Blockcode
Punkt
Quader
Selbst organisierendes System
Zahlenbereich
Implementierung
Fortsetzung <Mathematik>
Extrempunkt
Räumliche Anordnung
Gerichteter Graph
Code
Computeranimation
Client
Digitale Photographie
Diskrete Simulation
Minimum
Programmbibliothek
Gammafunktion
Implementierung
Softwaretest
Radius
Befehl <Informatik>
Transinformation
Datennetz
Division
Open Source
Stellenring
Ein-Ausgabe
Mapping <Computergraphik>
Patch <Software>
Einheit <Mathematik>
Automatische Indexierung
Server
Projektive Ebene
Garbentheorie
Hill-Differentialgleichung
Eigentliche Abbildung
Message-Passing
Tabelle <Informatik>
Fehlermeldung
Softwareentwickler
Perspektive
COM
Softwareentwickler
Räumliche Anordnung
Computeranimation
Homepage
Kovarianzfunktion
Punkt
Gemeinsamer Speicher
Wellenlehre
Zellularer Automat
Fortsetzung <Mathematik>
Kombinatorische Gruppentheorie
Räumliche Anordnung
Netzadresse
Raum-Zeit
Computeranimation
Übergang
Client
Gruppe <Mathematik>
Direkte numerische Simulation
Minimum
Skript <Programm>
Inverser Limes
Vorlesung/Konferenz
Speicher <Informatik>
App <Programm>
Datenhaltung
Kopula <Mathematik>
Wiki
Bitrate
Unendlichkeit
Softwarewartung
Dienst <Informatik>
Minimalgrad
Menge
Server
Dateiformat
Projektive Ebene
Speicherabzug
Information
Verzeichnisdienst
Instantiierung
Unendlichkeit
Distributionstheorie
Modul <Datentyp>
Chatten <Kommunikation>
Multimedia
Mobiles Internet
Zellularer Automat
Vorlesung/Konferenz
Data Envelopment Analysis
Binder <Informatik>
Computeranimation

Metadaten

Formale Metadaten

Titel Implementing basic GeoCouch support in Couchbase Lite
Serientitel FOSS4G 2014 Portland
Autor Anderson, Chris
Lizenz CC-Namensnennung 3.0 Deutschland:
Sie dürfen das Werk bzw. den Inhalt zu jedem legalen Zweck nutzen, verändern und in unveränderter oder veränderter Form vervielfältigen, verbreiten und öffentlich zugänglich machen, sofern Sie den Namen des Autors/Rechteinhabers in der von ihm festgelegten Weise nennen.
DOI 10.5446/31976
Herausgeber FOSS4G, Open Source Geospatial Foundation (OSGeo)
Erscheinungsjahr 2014
Sprache Englisch
Produktionsjahr 2014
Produktionsort Portland, Oregon, United States of America

Inhaltliche Metadaten

Fachgebiet Informatik
Abstract Couchbase Lite is an Apache-licensed native JSON database for iOS and Android with offline synchronization support.At a hackathon last year it took a couple of hours to add GeoCouch-style bbox queries to Couchbase Lite. I'll walk through the implementation of the geo indexer and how it fits into the Couchbase Lite codebase.Also expect to be wowed by examples of the power of sync + geo.
Schlagwörter json
mobile
GeoCouch
database
nosql

Ähnliche Filme

Loading...
Feedback