Data Formats: Reading and writing JSON – XML - YAML

CSUC - Consorci de Serveis Universitaris de Catalunya
CSUC - Consorci de Serveis Universitaris de CatalunyaPromotion & Marketing Coordinator en CSUC - Consorci de Serveis Universitaris de Catalunya
GN5-1
Public (PU)
Internet2 Technology Exchange, 19-09-2023
Minneapolis, USA
Data Formats: Reading and writing
JSON – XML - YAML
Maria Isabel Gandia Carriedo, CSUC/RedIRIS
network-eacademy@lists.geant.org
2 | GN5-1
Definitions
• Data modelling (YANG, TOSCA)
• Defines a representation of real-world
entities, their relationships and
structure
• Data formats (XML, JSON, YAML)
• Define how to encode the information
in a standardized way
• Protocols (NETCONF, RESTCONF, gRPC...)
• Define the operations, the requests
and responses of interactions
The real world
Gets represented as a
Data model
Is encoded in a
Data format
Protocol
Are used within a
3 | GN5-1
Data Serialisation Examples – Human Readable
XML
</>
JSON
{}
YAML
indentation
---
device:
type: router
vendor: MyOAVvendor
ports: 4
description: Access
{
“device”: {
“type”: “router”,
“vendor”: “MyOAVvendor”,
“ports”: 4,
“description”: “Access”
}
}
<network>
<device>
<type>router</type>
<vendor>MyOAVvendor</vendor>
<ports>4</ports>
<description>Access</description>
</device>
</network>
4 | GN5-1
Writing JSON, XML and YAML files
• You can write JSON, XML and YAML files with any text editor like vim or emacs
• If you like syntax highlighting, editors/IDEs such as Visual Studio Code,
Notepad++, Sublime.
5 | GN5-1
Challenges Achievements Conclusions Q&A
Some Free Tools to Help You Write, Validate and Convert Your Files
• You can check your syntax, format your files or convert them using useful free
tools:
• https://www.freeformatter.com
• https://www.liquid-technologies.com/online-xml-validator
• https://onlineyamltools.com/edit-yaml
• https://www.yamllint.com/
• https://www.json2yaml.com/
6 | GN5-1
Some Cases Where We Use JSON, YAML, XML
• Web API output (AWS, Google maps, Github, X,...)
• Jenkins
• ELK stack (Elasticsearch, Logstash, Kibana)
JSON:
• Jenkins
• NETCONF
• RESTCONF
XML:
• Ansible
• Kubernetes
• Docker
YAML:
- hosts: core
tasks:
- name: Describe router interfaces
ios_interface:
name: "{{ item.name }}"
description: "{{ item.description }}"
state: present
provider: "{{ credentials }}"
with_items:
- { name: Ethernet0/0, description: “One" }
- { name: Ethernet0/1, description: “Two” }
<copy-config>
<target>
<startup/>
</target>
<source>
<running/>
</source>
</copy-config>
7 | GN5-1
Challenges Achievements Conclusions Q&A
More Information in the Network Automation eAcademy
https://wiki.geant.org/display/NETDEV/OAV+Training+Portal
• Formats: YAML (30')
• Formats: XML (60’)
• Formats: JSON (45’)
www.geant.org
Thank You!
https://wiki.geant.org/display/NETDEV/NeA
network-eacademy@lists.geant.org
netdev@lists.geant.org
1 de 8

Recomendados

Microtask Crowdsourcing Applications for Linked Data por
Microtask Crowdsourcing Applications for Linked DataMicrotask Crowdsourcing Applications for Linked Data
Microtask Crowdsourcing Applications for Linked DataEUCLID project
2.2K vistas34 diapositivas
Computing Outside The Box June 2009 por
Computing Outside The Box June 2009Computing Outside The Box June 2009
Computing Outside The Box June 2009Ian Foster
766 vistas68 diapositivas
layer3_switching por
layer3_switchinglayer3_switching
layer3_switchingRobert Ciampa
136 vistas14 diapositivas
Diploma in Information Technology por
Diploma in Information TechnologyDiploma in Information Technology
Diploma in Information Technologymahatmagandhiuniversity
554 vistas10 diapositivas
Diploma in computer applications por
Diploma in computer applicationsDiploma in computer applications
Diploma in computer applicationsmahatmagandhiuniversity
641 vistas10 diapositivas
Toward universal information access on the digital object cloud por
Toward universal information access on the digital object cloudToward universal information access on the digital object cloud
Toward universal information access on the digital object cloudNational Institute of Informatics
233 vistas19 diapositivas

Más contenido relacionado

Similar a Data Formats: Reading and writing JSON – XML - YAML

Reference Representation in Large Metamodel-based Datasets por
Reference Representation in Large Metamodel-based DatasetsReference Representation in Large Metamodel-based Datasets
Reference Representation in Large Metamodel-based DatasetsMarkus Scheidgen
1.3K vistas49 diapositivas
Computing Outside The Box September 2009 por
Computing Outside The Box September 2009Computing Outside The Box September 2009
Computing Outside The Box September 2009Ian Foster
624 vistas69 diapositivas
Big Data to SMART Data : Process Scenario por
Big Data to SMART Data : Process ScenarioBig Data to SMART Data : Process Scenario
Big Data to SMART Data : Process ScenarioCHAKER ALLAOUI
2.1K vistas70 diapositivas
D0373024030 por
D0373024030D0373024030
D0373024030theijes
463 vistas7 diapositivas
DATABASE SYSTEMS PERFORMANCE EVALUATION FOR IOT APPLICATIONS por
DATABASE SYSTEMS PERFORMANCE EVALUATION FOR IOT APPLICATIONSDATABASE SYSTEMS PERFORMANCE EVALUATION FOR IOT APPLICATIONS
DATABASE SYSTEMS PERFORMANCE EVALUATION FOR IOT APPLICATIONSijdms
20 vistas14 diapositivas
Apache Drill: An Active, Ad-hoc Query System for large-scale Data Sets por
Apache Drill: An Active, Ad-hoc Query System for large-scale Data SetsApache Drill: An Active, Ad-hoc Query System for large-scale Data Sets
Apache Drill: An Active, Ad-hoc Query System for large-scale Data SetsMapR Technologies
3.3K vistas36 diapositivas

Similar a Data Formats: Reading and writing JSON – XML - YAML(20)

Reference Representation in Large Metamodel-based Datasets por Markus Scheidgen
Reference Representation in Large Metamodel-based DatasetsReference Representation in Large Metamodel-based Datasets
Reference Representation in Large Metamodel-based Datasets
Markus Scheidgen1.3K vistas
Computing Outside The Box September 2009 por Ian Foster
Computing Outside The Box September 2009Computing Outside The Box September 2009
Computing Outside The Box September 2009
Ian Foster624 vistas
Big Data to SMART Data : Process Scenario por CHAKER ALLAOUI
Big Data to SMART Data : Process ScenarioBig Data to SMART Data : Process Scenario
Big Data to SMART Data : Process Scenario
CHAKER ALLAOUI2.1K vistas
D0373024030 por theijes
D0373024030D0373024030
D0373024030
theijes463 vistas
DATABASE SYSTEMS PERFORMANCE EVALUATION FOR IOT APPLICATIONS por ijdms
DATABASE SYSTEMS PERFORMANCE EVALUATION FOR IOT APPLICATIONSDATABASE SYSTEMS PERFORMANCE EVALUATION FOR IOT APPLICATIONS
DATABASE SYSTEMS PERFORMANCE EVALUATION FOR IOT APPLICATIONS
ijdms20 vistas
Apache Drill: An Active, Ad-hoc Query System for large-scale Data Sets por MapR Technologies
Apache Drill: An Active, Ad-hoc Query System for large-scale Data SetsApache Drill: An Active, Ad-hoc Query System for large-scale Data Sets
Apache Drill: An Active, Ad-hoc Query System for large-scale Data Sets
MapR Technologies3.3K vistas
Multi-Model Data Query Languages and Processing Paradigms por Jiaheng Lu
Multi-Model Data Query Languages and Processing ParadigmsMulti-Model Data Query Languages and Processing Paradigms
Multi-Model Data Query Languages and Processing Paradigms
Jiaheng Lu140 vistas
Network Layered Models Rroosend por rroosend
Network Layered Models RroosendNetwork Layered Models Rroosend
Network Layered Models Rroosend
rroosend680 vistas
Bridging Socially-Enhanced Virtual Communities por Daniel Schall
Bridging Socially-Enhanced Virtual CommunitiesBridging Socially-Enhanced Virtual Communities
Bridging Socially-Enhanced Virtual Communities
Daniel Schall1.3K vistas
The need of Interoperability in Office and GIS formats por Markus Neteler
The need of Interoperability in Office and GIS formatsThe need of Interoperability in Office and GIS formats
The need of Interoperability in Office and GIS formats
Markus Neteler964 vistas
Getting started with YANG por CoreStack
Getting started with YANGGetting started with YANG
Getting started with YANG
CoreStack2.2K vistas
Opportunities for X-Ray science in future computing architectures por Ian Foster
Opportunities for X-Ray science in future computing architecturesOpportunities for X-Ray science in future computing architectures
Opportunities for X-Ray science in future computing architectures
Ian Foster363 vistas
How to make data more usable on the Internet of Things por PayamBarnaghi
How to make data more usable on the Internet of ThingsHow to make data more usable on the Internet of Things
How to make data more usable on the Internet of Things
PayamBarnaghi2K vistas
Azure Databricks for Data Scientists por Richard Garris
Azure Databricks for Data ScientistsAzure Databricks for Data Scientists
Azure Databricks for Data Scientists
Richard Garris281 vistas
Triplificating and linking XBRL financial data por Roberto García
Triplificating and linking XBRL financial dataTriplificating and linking XBRL financial data
Triplificating and linking XBRL financial data
Roberto García1.5K vistas
Modèles de données et langages de description ouverts 6 - 2021-2022 por François-Xavier Boffy
Modèles de données et langages de description ouverts   6 - 2021-2022Modèles de données et langages de description ouverts   6 - 2021-2022
Modèles de données et langages de description ouverts 6 - 2021-2022

Más de CSUC - Consorci de Serveis Universitaris de Catalunya

The Research Portal of Catalonia: Growing more (information) & more (services) por
The Research Portal of Catalonia: Growing more (information) & more (services)The Research Portal of Catalonia: Growing more (information) & more (services)
The Research Portal of Catalonia: Growing more (information) & more (services)CSUC - Consorci de Serveis Universitaris de Catalunya
141 vistas25 diapositivas
Facilitar la gestión, visibilidad y reutilización de los datos de investigaci... por
Facilitar la gestión, visibilidad y reutilización de los datos de investigaci...Facilitar la gestión, visibilidad y reutilización de los datos de investigaci...
Facilitar la gestión, visibilidad y reutilización de los datos de investigaci...CSUC - Consorci de Serveis Universitaris de Catalunya
72 vistas26 diapositivas
La gestión de datos de investigación en las bibliotecas universitarias españolas por
La gestión de datos de investigación en las bibliotecas universitarias españolasLa gestión de datos de investigación en las bibliotecas universitarias españolas
La gestión de datos de investigación en las bibliotecas universitarias españolasCSUC - Consorci de Serveis Universitaris de Catalunya
107 vistas13 diapositivas
Disposes de recursos il·limitats? Prioritza estratègicament els teus projecte... por
Disposes de recursos il·limitats? Prioritza estratègicament els teus projecte...Disposes de recursos il·limitats? Prioritza estratègicament els teus projecte...
Disposes de recursos il·limitats? Prioritza estratègicament els teus projecte...CSUC - Consorci de Serveis Universitaris de Catalunya
19 vistas40 diapositivas
Les persones i les seves capacitats en el nucli de la transformació digital. ... por
Les persones i les seves capacitats en el nucli de la transformació digital. ...Les persones i les seves capacitats en el nucli de la transformació digital. ...
Les persones i les seves capacitats en el nucli de la transformació digital. ...CSUC - Consorci de Serveis Universitaris de Catalunya
19 vistas16 diapositivas
Enginyeria Informàtica: una cursa de fons por
Enginyeria Informàtica: una cursa de fonsEnginyeria Informàtica: una cursa de fons
Enginyeria Informàtica: una cursa de fonsCSUC - Consorci de Serveis Universitaris de Catalunya
11 vistas17 diapositivas

Más de CSUC - Consorci de Serveis Universitaris de Catalunya(20)

Último

LLMs in Production: Tooling, Process, and Team Structure por
LLMs in Production: Tooling, Process, and Team StructureLLMs in Production: Tooling, Process, and Team Structure
LLMs in Production: Tooling, Process, and Team StructureAggregage
57 vistas77 diapositivas
Hypervisor Agnostic DRS in CloudStack - Brief overview & demo - Vishesh Jinda... por
Hypervisor Agnostic DRS in CloudStack - Brief overview & demo - Vishesh Jinda...Hypervisor Agnostic DRS in CloudStack - Brief overview & demo - Vishesh Jinda...
Hypervisor Agnostic DRS in CloudStack - Brief overview & demo - Vishesh Jinda...ShapeBlue
164 vistas13 diapositivas
Future of AR - Facebook Presentation por
Future of AR - Facebook PresentationFuture of AR - Facebook Presentation
Future of AR - Facebook PresentationRob McCarty
65 vistas27 diapositivas
Webinar : Desperately Seeking Transformation - Part 2: Insights from leading... por
Webinar : Desperately Seeking Transformation - Part 2:  Insights from leading...Webinar : Desperately Seeking Transformation - Part 2:  Insights from leading...
Webinar : Desperately Seeking Transformation - Part 2: Insights from leading...The Digital Insurer
91 vistas52 diapositivas
Transcript: Redefining the book supply chain: A glimpse into the future - Tec... por
Transcript: Redefining the book supply chain: A glimpse into the future - Tec...Transcript: Redefining the book supply chain: A glimpse into the future - Tec...
Transcript: Redefining the book supply chain: A glimpse into the future - Tec...BookNet Canada
41 vistas16 diapositivas
NTGapps NTG LowCode Platform por
NTGapps NTG LowCode Platform NTGapps NTG LowCode Platform
NTGapps NTG LowCode Platform Mustafa Kuğu
437 vistas30 diapositivas

Último(20)

LLMs in Production: Tooling, Process, and Team Structure por Aggregage
LLMs in Production: Tooling, Process, and Team StructureLLMs in Production: Tooling, Process, and Team Structure
LLMs in Production: Tooling, Process, and Team Structure
Aggregage57 vistas
Hypervisor Agnostic DRS in CloudStack - Brief overview & demo - Vishesh Jinda... por ShapeBlue
Hypervisor Agnostic DRS in CloudStack - Brief overview & demo - Vishesh Jinda...Hypervisor Agnostic DRS in CloudStack - Brief overview & demo - Vishesh Jinda...
Hypervisor Agnostic DRS in CloudStack - Brief overview & demo - Vishesh Jinda...
ShapeBlue164 vistas
Future of AR - Facebook Presentation por Rob McCarty
Future of AR - Facebook PresentationFuture of AR - Facebook Presentation
Future of AR - Facebook Presentation
Rob McCarty65 vistas
Webinar : Desperately Seeking Transformation - Part 2: Insights from leading... por The Digital Insurer
Webinar : Desperately Seeking Transformation - Part 2:  Insights from leading...Webinar : Desperately Seeking Transformation - Part 2:  Insights from leading...
Webinar : Desperately Seeking Transformation - Part 2: Insights from leading...
Transcript: Redefining the book supply chain: A glimpse into the future - Tec... por BookNet Canada
Transcript: Redefining the book supply chain: A glimpse into the future - Tec...Transcript: Redefining the book supply chain: A glimpse into the future - Tec...
Transcript: Redefining the book supply chain: A glimpse into the future - Tec...
BookNet Canada41 vistas
NTGapps NTG LowCode Platform por Mustafa Kuğu
NTGapps NTG LowCode Platform NTGapps NTG LowCode Platform
NTGapps NTG LowCode Platform
Mustafa Kuğu437 vistas
"Running students' code in isolation. The hard way", Yurii Holiuk por Fwdays
"Running students' code in isolation. The hard way", Yurii Holiuk "Running students' code in isolation. The hard way", Yurii Holiuk
"Running students' code in isolation. The hard way", Yurii Holiuk
Fwdays36 vistas
TrustArc Webinar - Managing Online Tracking Technology Vendors_ A Checklist f... por TrustArc
TrustArc Webinar - Managing Online Tracking Technology Vendors_ A Checklist f...TrustArc Webinar - Managing Online Tracking Technology Vendors_ A Checklist f...
TrustArc Webinar - Managing Online Tracking Technology Vendors_ A Checklist f...
TrustArc176 vistas
"Surviving highload with Node.js", Andrii Shumada por Fwdays
"Surviving highload with Node.js", Andrii Shumada "Surviving highload with Node.js", Andrii Shumada
"Surviving highload with Node.js", Andrii Shumada
Fwdays58 vistas
What’s New in CloudStack 4.19 - Abhishek Kumar - ShapeBlue por ShapeBlue
What’s New in CloudStack 4.19 - Abhishek Kumar - ShapeBlueWhat’s New in CloudStack 4.19 - Abhishek Kumar - ShapeBlue
What’s New in CloudStack 4.19 - Abhishek Kumar - ShapeBlue
ShapeBlue265 vistas
The Power of Generative AI in Accelerating No Code Adoption.pdf por Saeed Al Dhaheri
The Power of Generative AI in Accelerating No Code Adoption.pdfThe Power of Generative AI in Accelerating No Code Adoption.pdf
The Power of Generative AI in Accelerating No Code Adoption.pdf
Saeed Al Dhaheri39 vistas
The Power of Heat Decarbonisation Plans in the Built Environment por IES VE
The Power of Heat Decarbonisation Plans in the Built EnvironmentThe Power of Heat Decarbonisation Plans in the Built Environment
The Power of Heat Decarbonisation Plans in the Built Environment
IES VE84 vistas
State of the Union - Rohit Yadav - Apache CloudStack por ShapeBlue
State of the Union - Rohit Yadav - Apache CloudStackState of the Union - Rohit Yadav - Apache CloudStack
State of the Union - Rohit Yadav - Apache CloudStack
ShapeBlue303 vistas
Why and How CloudStack at weSystems - Stephan Bienek - weSystems por ShapeBlue
Why and How CloudStack at weSystems - Stephan Bienek - weSystemsWhy and How CloudStack at weSystems - Stephan Bienek - weSystems
Why and How CloudStack at weSystems - Stephan Bienek - weSystems
ShapeBlue247 vistas
Live Demo Showcase: Unveiling Dell PowerFlex’s IaaS Capabilities with Apache ... por ShapeBlue
Live Demo Showcase: Unveiling Dell PowerFlex’s IaaS Capabilities with Apache ...Live Demo Showcase: Unveiling Dell PowerFlex’s IaaS Capabilities with Apache ...
Live Demo Showcase: Unveiling Dell PowerFlex’s IaaS Capabilities with Apache ...
ShapeBlue129 vistas
Setting Up Your First CloudStack Environment with Beginners Challenges - MD R... por ShapeBlue
Setting Up Your First CloudStack Environment with Beginners Challenges - MD R...Setting Up Your First CloudStack Environment with Beginners Challenges - MD R...
Setting Up Your First CloudStack Environment with Beginners Challenges - MD R...
ShapeBlue178 vistas
Business Analyst Series 2023 - Week 4 Session 8 por DianaGray10
Business Analyst Series 2023 -  Week 4 Session 8Business Analyst Series 2023 -  Week 4 Session 8
Business Analyst Series 2023 - Week 4 Session 8
DianaGray10145 vistas
DRaaS using Snapshot copy and destination selection (DRaaS) - Alexandre Matti... por ShapeBlue
DRaaS using Snapshot copy and destination selection (DRaaS) - Alexandre Matti...DRaaS using Snapshot copy and destination selection (DRaaS) - Alexandre Matti...
DRaaS using Snapshot copy and destination selection (DRaaS) - Alexandre Matti...
ShapeBlue141 vistas

Data Formats: Reading and writing JSON – XML - YAML

  • 1. GN5-1 Public (PU) Internet2 Technology Exchange, 19-09-2023 Minneapolis, USA Data Formats: Reading and writing JSON – XML - YAML Maria Isabel Gandia Carriedo, CSUC/RedIRIS network-eacademy@lists.geant.org
  • 2. 2 | GN5-1 Definitions • Data modelling (YANG, TOSCA) • Defines a representation of real-world entities, their relationships and structure • Data formats (XML, JSON, YAML) • Define how to encode the information in a standardized way • Protocols (NETCONF, RESTCONF, gRPC...) • Define the operations, the requests and responses of interactions The real world Gets represented as a Data model Is encoded in a Data format Protocol Are used within a
  • 3. 3 | GN5-1 Data Serialisation Examples – Human Readable XML </> JSON {} YAML indentation --- device: type: router vendor: MyOAVvendor ports: 4 description: Access { “device”: { “type”: “router”, “vendor”: “MyOAVvendor”, “ports”: 4, “description”: “Access” } } <network> <device> <type>router</type> <vendor>MyOAVvendor</vendor> <ports>4</ports> <description>Access</description> </device> </network>
  • 4. 4 | GN5-1 Writing JSON, XML and YAML files • You can write JSON, XML and YAML files with any text editor like vim or emacs • If you like syntax highlighting, editors/IDEs such as Visual Studio Code, Notepad++, Sublime.
  • 5. 5 | GN5-1 Challenges Achievements Conclusions Q&A Some Free Tools to Help You Write, Validate and Convert Your Files • You can check your syntax, format your files or convert them using useful free tools: • https://www.freeformatter.com • https://www.liquid-technologies.com/online-xml-validator • https://onlineyamltools.com/edit-yaml • https://www.yamllint.com/ • https://www.json2yaml.com/
  • 6. 6 | GN5-1 Some Cases Where We Use JSON, YAML, XML • Web API output (AWS, Google maps, Github, X,...) • Jenkins • ELK stack (Elasticsearch, Logstash, Kibana) JSON: • Jenkins • NETCONF • RESTCONF XML: • Ansible • Kubernetes • Docker YAML: - hosts: core tasks: - name: Describe router interfaces ios_interface: name: "{{ item.name }}" description: "{{ item.description }}" state: present provider: "{{ credentials }}" with_items: - { name: Ethernet0/0, description: “One" } - { name: Ethernet0/1, description: “Two” } <copy-config> <target> <startup/> </target> <source> <running/> </source> </copy-config>
  • 7. 7 | GN5-1 Challenges Achievements Conclusions Q&A More Information in the Network Automation eAcademy https://wiki.geant.org/display/NETDEV/OAV+Training+Portal • Formats: YAML (30') • Formats: XML (60’) • Formats: JSON (45’)