JSOP in 60 seconds

David Nuescheler
David NueschelerVP, Enterprise Technology at Adobe
Introducing:

JSOP
Pitch & Goal
- Browser enabled, HTTP-based protocol
  designed to exchange fine-grained
  information efficiently.

- Easy to consume by todays
  Web-”Gear” (browsers, flash & friends)

- Probably suitable for an RFC @ IETF
Basics
- Serialization to JSON (optionally YAML/XML)
- GET (batch/hierarchical)
- PUT (batch/hierarchical)
- PATCH (json diff content type)
- Support for binary as multipart
Retro-style
- PUT & PATCH -> multipart POST
- Allows for Simple HTML forms
Extensions
- Sort-Order
- Query
- Typing
- Locking
- Versioning
- Essentially: WebDAV + friends but simple
Sample GET
Request:
GET /myfolder.json HTTP/1.1

Response:
{
"createdBy" : "uncled",
"name" : "myfolder",
"id" : "50d9317a-3a95-401a-9638-333a0dbf04bb"
"type" : "folder"
}
Sample GET 2
Request:
GET /myfolder.4.json HTTP/1.1

Response:
{
"createdBy" : "uncled",
"name" : "myfolder",
"id" : "50d9317a-3a95-401a-9638-333a0dbf04bb"
"type" : "folder"

"child1" :
  {
  "grandchild11" :
    {
    "depth3" :
      {
      "depth4 : { ... }
      }
    }
  }
}
Sample PUT
PUT /myfolder HTTP/1.1

{
"createdBy" : "uncled",
"name" : "myfolder",
"id" : "50d9317a-3a95-401a-9638-333a0dbf04bb"
"type" : "folder"

"child1" :
  {
  "grandchild11" :
    {
    "depth3" :
      {
      "depth4 : { ... }
      }
    }
  }
}
Sample PATCH
PATCH /myfolder HTTP/1.1

+newdoc : { "type" : "document", "createdBy" : "me" }
-olddoc
>movingdoc : /otherfolder/mydocument
^lastModifiedBy : "me"
PATCH diff ops
"+":
create Node/Property/Resource

"^":
update Node/Property/Resource

"-":
delete Node/Property/Resource

">":
move Node/Property/Resource
PATCH diff
diff       ::=   members
members    ::=   pair | pairs
pair       ::=   key [ " : " value ]
pairs      ::=   pair line-end pair | pair line-end pairs
line-end   ::=   "rn" | "n" | "r"
key        ::=   opchar id
opchar     ::=   "+" | "^" | "-" | ">"
id         ::=   * identification url (path | id) *
value      ::=   value+ | value- | value^ | value>
value+     ::=   * a JSON object *
value-     ::=   ""
value^     ::=   * any JSON value except JSON object *
value>     ::=   id
POST wrap 1
POST /myfolder/my.gif HTTP/1.1
Content-Type: multipart/form-data;
boundary=---------21447684891610979728262467120
Content-Length: 123

---------21447684891610979728262467120
Content-Disposition: form-data; name="data"
Content-Type: image/gif

GIF89a...................!.......,............s...f.;
---------21447684891610979728262467120
Content-Disposition: form-data; name="jsop:diff"
Content-Type: text/plain

^lastModifiedBy : "me"
+exif { cameraMake : "Apple", cameraModel : "Apple" }
---------21447684891610979728262467120--
POST wrap 2
POST /myfolder/my.gif HTTP/1.1
Content-Type: multipart/form-data;
boundary=---------21447684891610979728262467120
Content-Length: 123

---------21447684891610979728262467120
Content-Disposition: form-data; name="exif/cameraMake"
Content-Type: text/plain

Another Vendor
---------21447684891610979728262467120--
POST wrap 3
POST /myfolder/ HTTP/1.1
Content-Type: multipart/form-data;
boundary=---------21447684891610979728262467120
Content-Length: 123

---------21447684891610979728262467120
Content-Disposition: form-data; name=""; filename="my.gif"
Content-Type: image/gif

GIF89a...................!.......,............s...f.;
---------21447684891610979728262467120
Content-Disposition: form-data; name=""; filename="yo.gif"
Content-Type: image/gif

GIF89a...................!.......,............s...f.;
---------21447684891610979728262467120 --
1 of 14

More Related Content

What's hot(20)

Php file handling in Hindi Php file handling in Hindi
Php file handling in Hindi
Vipin sharma1.6K views
Railson dickinson 5 mil seguidoresRailson dickinson 5 mil seguidores
Railson dickinson 5 mil seguidores
Railson Dickinson205 views
Intro To Couch DbIntro To Couch Db
Intro To Couch Db
Shahar Evron18K views
MongoDB Advanced TopicsMongoDB Advanced Topics
MongoDB Advanced Topics
César Rodas3.5K views
MongoDB Grand Rapids RUGMongoDB Grand Rapids RUG
MongoDB Grand Rapids RUG
John Nunemaker2.4K views
An introduction to CouchDBAn introduction to CouchDB
An introduction to CouchDB
David Coallier4K views
MongoDB at RuPyMongoDB at RuPy
MongoDB at RuPy
Mike Dirolf1.1K views
B03-GenomeContent-IntermineB03-GenomeContent-Intermine
B03-GenomeContent-Intermine
Bioinformatics Open Source Conference484 views
Php File OperationsPhp File Operations
Php File Operations
Jamshid Hashimi3.5K views
MongoDB at FrozenRailsMongoDB at FrozenRails
MongoDB at FrozenRails
Mike Dirolf3.6K views
MongoDB (Advanced)MongoDB (Advanced)
MongoDB (Advanced)
TO THE NEW | Technology2.5K views
08 php-files08 php-files
08 php-files
hoangphuc2587459 views
Hands On Spring DataHands On Spring Data
Hands On Spring Data
Eric Bottard1.6K views
HTML5HTML5
HTML5
Raphael Agneli246 views

Viewers also liked(6)

AEM Hub - on the road with AEMAEM Hub - on the road with AEM
AEM Hub - on the road with AEM
David Nuescheler2.5K views
Aem hub oak 0.2 fullAem hub oak 0.2 full
Aem hub oak 0.2 full
Michael Marth5.4K views
EVOLVE'16 | Deploy | Abhishek Dwevedi | Introduction to AEM Front End Develop...EVOLVE'16 | Deploy | Abhishek Dwevedi | Introduction to AEM Front End Develop...
EVOLVE'16 | Deploy | Abhishek Dwevedi | Introduction to AEM Front End Develop...
Evolve The Adobe Digital Marketing Community497 views
EVOLVE'16 | Deploy | Varun Mitra | Introduction to AEM  EVOLVE'16 | Deploy | Varun Mitra | Introduction to AEM
EVOLVE'16 | Deploy | Varun Mitra | Introduction to AEM
Evolve The Adobe Digital Marketing Community588 views

Similar to JSOP in 60 seconds

RESTful JSON web databasesRESTful JSON web databases
RESTful JSON web databaseskriszyp
6.1K views30 slides
REST with Eve and PythonREST with Eve and Python
REST with Eve and PythonPiXeL16
1.9K views57 slides
03 form-data03 form-data
03 form-datasnopteck
403 views23 slides
Rpi python webRpi python web
Rpi python websewoo lee
840 views37 slides

More from David Nuescheler(20)

The New Marketer?The New Marketer?
The New Marketer?
David Nuescheler2.8K views
Adobe MAX: The Future Enterprise DeveloperAdobe MAX: The Future Enterprise Developer
Adobe MAX: The Future Enterprise Developer
David Nuescheler1.5K views
Adobe MAX - WEM: 10 Whirlwind demosAdobe MAX - WEM: 10 Whirlwind demos
Adobe MAX - WEM: 10 Whirlwind demos
David Nuescheler2.6K views
The Future of ECMThe Future of ECM
The Future of ECM
David Nuescheler1.3K views
Introducing CQ5.4: Sneak-Peek Introducing CQ5.4: Sneak-Peek
Introducing CQ5.4: Sneak-Peek
David Nuescheler4.7K views
JCP Heartbeat MonitorJCP Heartbeat Monitor
JCP Heartbeat Monitor
David Nuescheler876 views
FrOScamp Zurich: Introducing JCR - 2010FrOScamp Zurich: Introducing JCR - 2010
FrOScamp Zurich: Introducing JCR - 2010
David Nuescheler1.3K views
Future of WCM - CM Forum BelgiumFuture of WCM - CM Forum Belgium
Future of WCM - CM Forum Belgium
David Nuescheler1.1K views
Agile Edge ValtechAgile Edge Valtech
Agile Edge Valtech
David Nuescheler787 views
What's new in CQ 5.3? Top 10 features.What's new in CQ 5.3? Top 10 features.
What's new in CQ 5.3? Top 10 features.
David Nuescheler2K views
JBoye Presentation: WCM Trends for 2010JBoye Presentation: WCM Trends for 2010
JBoye Presentation: WCM Trends for 2010
David Nuescheler1.5K views
Introducing JSR-283Introducing JSR-283
Introducing JSR-283
David Nuescheler1.7K views
What's new in JSR-283?What's new in JSR-283?
What's new in JSR-283?
David Nuescheler4.5K views
Top 8 WCM Trends 2010Top 8 WCM Trends 2010
Top 8 WCM Trends 2010
David Nuescheler1.4K views
CQ5 Singapore Workshop at NCSCQ5 Singapore Workshop at NCS
CQ5 Singapore Workshop at NCS
David Nuescheler648 views

Recently uploaded(20)

Java Platform Approach 1.0 - Picnic MeetupJava Platform Approach 1.0 - Picnic Meetup
Java Platform Approach 1.0 - Picnic Meetup
Rick Ossendrijver20 views
Liqid: Composable CXL PreviewLiqid: Composable CXL Preview
Liqid: Composable CXL Preview
CXL Forum114 views
CXL at OCPCXL at OCP
CXL at OCP
CXL Forum158 views
ISWC2023-McGuinnessTWC16x9FinalShort.pdfISWC2023-McGuinnessTWC16x9FinalShort.pdf
ISWC2023-McGuinnessTWC16x9FinalShort.pdf
Deborah McGuinness80 views
METHOD AND SYSTEM FOR PREDICTING OPTIMAL LOAD FOR WHICH THE YIELD IS MAXIMUM ...METHOD AND SYSTEM FOR PREDICTING OPTIMAL LOAD FOR WHICH THE YIELD IS MAXIMUM ...
METHOD AND SYSTEM FOR PREDICTING OPTIMAL LOAD FOR WHICH THE YIELD IS MAXIMUM ...
Prity Khastgir IPR Strategic India Patent Attorney Amplify Innovation22 views

JSOP in 60 seconds

  • 2. Pitch & Goal - Browser enabled, HTTP-based protocol designed to exchange fine-grained information efficiently. - Easy to consume by todays Web-”Gear” (browsers, flash & friends) - Probably suitable for an RFC @ IETF
  • 3. Basics - Serialization to JSON (optionally YAML/XML) - GET (batch/hierarchical) - PUT (batch/hierarchical) - PATCH (json diff content type) - Support for binary as multipart
  • 4. Retro-style - PUT & PATCH -> multipart POST - Allows for Simple HTML forms
  • 5. Extensions - Sort-Order - Query - Typing - Locking - Versioning - Essentially: WebDAV + friends but simple
  • 6. Sample GET Request: GET /myfolder.json HTTP/1.1 Response: { "createdBy" : "uncled", "name" : "myfolder", "id" : "50d9317a-3a95-401a-9638-333a0dbf04bb" "type" : "folder" }
  • 7. Sample GET 2 Request: GET /myfolder.4.json HTTP/1.1 Response: { "createdBy" : "uncled", "name" : "myfolder", "id" : "50d9317a-3a95-401a-9638-333a0dbf04bb" "type" : "folder" "child1" : { "grandchild11" : { "depth3" : { "depth4 : { ... } } } } }
  • 8. Sample PUT PUT /myfolder HTTP/1.1 { "createdBy" : "uncled", "name" : "myfolder", "id" : "50d9317a-3a95-401a-9638-333a0dbf04bb" "type" : "folder" "child1" : { "grandchild11" : { "depth3" : { "depth4 : { ... } } } } }
  • 9. Sample PATCH PATCH /myfolder HTTP/1.1 +newdoc : { "type" : "document", "createdBy" : "me" } -olddoc >movingdoc : /otherfolder/mydocument ^lastModifiedBy : "me"
  • 10. PATCH diff ops "+": create Node/Property/Resource "^": update Node/Property/Resource "-": delete Node/Property/Resource ">": move Node/Property/Resource
  • 11. PATCH diff diff ::= members members ::= pair | pairs pair ::= key [ " : " value ] pairs ::= pair line-end pair | pair line-end pairs line-end ::= "rn" | "n" | "r" key ::= opchar id opchar ::= "+" | "^" | "-" | ">" id ::= * identification url (path | id) * value ::= value+ | value- | value^ | value> value+ ::= * a JSON object * value- ::= "" value^ ::= * any JSON value except JSON object * value> ::= id
  • 12. POST wrap 1 POST /myfolder/my.gif HTTP/1.1 Content-Type: multipart/form-data; boundary=---------21447684891610979728262467120 Content-Length: 123 ---------21447684891610979728262467120 Content-Disposition: form-data; name="data" Content-Type: image/gif GIF89a...................!.......,............s...f.; ---------21447684891610979728262467120 Content-Disposition: form-data; name="jsop:diff" Content-Type: text/plain ^lastModifiedBy : "me" +exif { cameraMake : "Apple", cameraModel : "Apple" } ---------21447684891610979728262467120--
  • 13. POST wrap 2 POST /myfolder/my.gif HTTP/1.1 Content-Type: multipart/form-data; boundary=---------21447684891610979728262467120 Content-Length: 123 ---------21447684891610979728262467120 Content-Disposition: form-data; name="exif/cameraMake" Content-Type: text/plain Another Vendor ---------21447684891610979728262467120--
  • 14. POST wrap 3 POST /myfolder/ HTTP/1.1 Content-Type: multipart/form-data; boundary=---------21447684891610979728262467120 Content-Length: 123 ---------21447684891610979728262467120 Content-Disposition: form-data; name=""; filename="my.gif" Content-Type: image/gif GIF89a...................!.......,............s...f.; ---------21447684891610979728262467120 Content-Disposition: form-data; name=""; filename="yo.gif" Content-Type: image/gif GIF89a...................!.......,............s...f.; ---------21447684891610979728262467120 --