SlideShare a Scribd company logo
{
    “Talk” :
      “JSON Validation
      using JSON Schema and
      Jackson”,

    “by” : “Stephane Rondal”
}
stephane.rondal@arexo.be
@stephanerondal
JSON
JSON
 • Very present in Web 2.0 and mobile apps
JSON
 • Very present in Web 2.0 and mobile apps
 • With REST, typically serves as the data exchange format
JSON
 • Very present in Web 2.0 and mobile apps
 • With REST, typically serves as the data exchange format
 • Sometimes even derived automatically from POJOs
JSON
 • Very present in Web 2.0 and mobile apps
 • With REST, typically serves as the data exchange format
 • Sometimes even derived automatically from POJOs
 • Part of the interface between client and server
JSON
 • Very present in Web 2.0 and mobile apps
 • With REST, typically serves as the data exchange format
 • Sometimes even derived automatically from POJOs
 • Part of the interface between client and server
 • Stability / Backward-compatibility??
JSON
 • Very present in Web 2.0 and mobile apps
 • With REST, typically serves as the data exchange format
 • Sometimes even derived automatically from POJOs
 • Part of the interface between client and server
 • Stability / Backward-compatibility??
JSON Schema
JSON Schema


Represents the structure of a JSON document
Much like XML Schema does for XML documents
n’t r un
         a it, do
 X ML ?W          t!
          ay   ye
       aw
Much like XML Schema does for XML documents
Keeping the simple and
lightweight aspects of JSON we
          have all come to love
JSON Schema
JSON Schema
 • A schema is a JSON document
JSON Schema
 • A schema is a JSON document
 • Specifies
   •   Properties
       •Type (simple, complex)
       •Required/Optional
       •Simple constraints
   •   And more...
{

   "description": "An Address following the convention ...",

   "type":"object",

   "properties": {

   
 "post-office-box": { "type": "string" },

   
 "extended-address": { "type": "string" },

   
 "street-address": { "type": "string" },

   
 "locality":{ "type": "string", "required": true },

   
 "region": { "type": "string", "required": true },

   
 "postal-code": { "type": "string" },

   
 "country-name": { "type": "string", "required": true}

   },

   "dependencies": {

   
 "post-office-box": "street-address",

   
 "extended-address": "street-address"

   }
}
An IETF draft standard (3rd version)
Why
   use
  JSON
Schema ?
Devoxx - JSON Validation using JSON Schema and Jackson
Documentation
Automation
Code / UI Generation
Or Why Not ?
Demo
References
 • www.json.org
 • json-schema.org
 • tools.ietf.org/html/draft-zyp-json-schema-03
 • github.com/fge/json-schema-validator
Devoxx - JSON Validation using JSON Schema and Jackson
Q&A

More Related Content

PPTX
J s o n
PPT
java script json
PPTX
PPT
JavaScript Object Notation (JSON)
DOCX
What is JSON? Why use JSON? JSON Types? JSON Helpful Tools?
PPTX
JSON - JavaScript Object Notation
J s o n
java script json
JavaScript Object Notation (JSON)
What is JSON? Why use JSON? JSON Types? JSON Helpful Tools?
JSON - JavaScript Object Notation

What's hot (20)

PPTX
PPTX
JSON: The Basics
PDF
MongoDB Mojo: Building a Basic Perl App
PPT
Java Script Based Client Server Webapps 2
ODP
Json Tutorial
PPTX
Java script and json
PPTX
Conceptos básicos. seminario web 3 : Diseño de esquema pensado para documentos
PDF
Top JSON Interview Questions for Freshers
PDF
Writing Domain Specific Languages with JSON Schema
PDF
Fluentdでログ収集「だけ」やる話 #study2study
PDF
MongoDB Schema Design (Event: An Evening with MongoDB Houston 3/11/15)
PDF
COUNTWORDSFREE - WORD COUNTER
PPT
RESTful JSON web databases
ODT
Rest With Json Vs Soap With Xml
PPT
JSON - Quick Overview
PDF
萌典與零時政府
JSON: The Basics
MongoDB Mojo: Building a Basic Perl App
Java Script Based Client Server Webapps 2
Json Tutorial
Java script and json
Conceptos básicos. seminario web 3 : Diseño de esquema pensado para documentos
Top JSON Interview Questions for Freshers
Writing Domain Specific Languages with JSON Schema
Fluentdでログ収集「だけ」やる話 #study2study
MongoDB Schema Design (Event: An Evening with MongoDB Houston 3/11/15)
COUNTWORDSFREE - WORD COUNTER
RESTful JSON web databases
Rest With Json Vs Soap With Xml
JSON - Quick Overview
萌典與零時政府
Ad

Similar to Devoxx - JSON Validation using JSON Schema and Jackson (20)

PDF
Json at work overview and ecosystem-v2.0
PDF
Hands on JSON
PPT
Advanced Json
PDF
Json
PPTX
JSON Support in Salesforce - winter 12
PPTX
Unit-2.pptx
PPT
json.ppt download for free for college project
PPTX
Introduction to JavaScript Object Notation(JSON)
PDF
CS8651 IP Unit 2 pdf regulation -2017 anna university
PPTX
LU 1.3. JSON & XML.pptx about how they work and introduction
PPT
Json - ideal for data interchange
PDF
Json the-x-in-ajax1588
PDF
LF_APIStrat17_Embracing JSON Schema
PDF
CouchDB at JAOO Århus 2009
PPTX
Pythonlearn-13-WebServices.pptx
PPTX
Json
PPTX
JSON, XML and Data Science introduction.pptx
PDF
Differential Sync and JSON Patch @ SpringOne2GX 2014
PPTX
Json at work overview and ecosystem-v2.0
Hands on JSON
Advanced Json
Json
JSON Support in Salesforce - winter 12
Unit-2.pptx
json.ppt download for free for college project
Introduction to JavaScript Object Notation(JSON)
CS8651 IP Unit 2 pdf regulation -2017 anna university
LU 1.3. JSON & XML.pptx about how they work and introduction
Json - ideal for data interchange
Json the-x-in-ajax1588
LF_APIStrat17_Embracing JSON Schema
CouchDB at JAOO Århus 2009
Pythonlearn-13-WebServices.pptx
Json
JSON, XML and Data Science introduction.pptx
Differential Sync and JSON Patch @ SpringOne2GX 2014
Ad

More from Stephane Rondal (6)

PPTX
Introduction to Minecraft Modding at YaJUG
PPTX
Apprendre a Coder au WAJUG
PPTX
Introduction to SAFe, the Scaled Agile Framework
PPTX
Management is Dead
PPTX
Lessons learned from scaling Agile to distributed, offshore teams
PPTX
Agile Tour Brussels 2012 - Estimating user stories
Introduction to Minecraft Modding at YaJUG
Apprendre a Coder au WAJUG
Introduction to SAFe, the Scaled Agile Framework
Management is Dead
Lessons learned from scaling Agile to distributed, offshore teams
Agile Tour Brussels 2012 - Estimating user stories

Devoxx - JSON Validation using JSON Schema and Jackson

  • 1. { “Talk” : “JSON Validation using JSON Schema and Jackson”, “by” : “Stephane Rondal” }
  • 4. JSON • Very present in Web 2.0 and mobile apps
  • 5. JSON • Very present in Web 2.0 and mobile apps • With REST, typically serves as the data exchange format
  • 6. JSON • Very present in Web 2.0 and mobile apps • With REST, typically serves as the data exchange format • Sometimes even derived automatically from POJOs
  • 7. JSON • Very present in Web 2.0 and mobile apps • With REST, typically serves as the data exchange format • Sometimes even derived automatically from POJOs • Part of the interface between client and server
  • 8. JSON • Very present in Web 2.0 and mobile apps • With REST, typically serves as the data exchange format • Sometimes even derived automatically from POJOs • Part of the interface between client and server • Stability / Backward-compatibility??
  • 9. JSON • Very present in Web 2.0 and mobile apps • With REST, typically serves as the data exchange format • Sometimes even derived automatically from POJOs • Part of the interface between client and server • Stability / Backward-compatibility??
  • 11. JSON Schema Represents the structure of a JSON document
  • 12. Much like XML Schema does for XML documents
  • 13. n’t r un a it, do X ML ?W t! ay ye aw Much like XML Schema does for XML documents
  • 14. Keeping the simple and lightweight aspects of JSON we have all come to love
  • 16. JSON Schema • A schema is a JSON document
  • 17. JSON Schema • A schema is a JSON document • Specifies • Properties •Type (simple, complex) •Required/Optional •Simple constraints • And more...
  • 18. { "description": "An Address following the convention ...", "type":"object", "properties": { "post-office-box": { "type": "string" }, "extended-address": { "type": "string" }, "street-address": { "type": "string" }, "locality":{ "type": "string", "required": true }, "region": { "type": "string", "required": true }, "postal-code": { "type": "string" }, "country-name": { "type": "string", "required": true} }, "dependencies": { "post-office-box": "street-address", "extended-address": "street-address" } }
  • 19. An IETF draft standard (3rd version)
  • 20. Why use JSON Schema ?
  • 23. Automation Code / UI Generation
  • 25. Demo
  • 26. References • www.json.org • json-schema.org • tools.ietf.org/html/draft-zyp-json-schema-03 • github.com/fge/json-schema-validator
  • 28. Q&A

Editor's Notes