Download presentation
Presentation is loading. Please wait.
Published byBrenda Short Modified over 6 years ago
1
Rest Services with Play Framework, Adding Security with JWT
Sydney
2
Independent Consultor #geek #traveler #speaker
Community Leader JDuchess Chapter Guatemala, Devs+502 Ex-JUG Member Guatemala Java Users Group (GuateJUG) Independent Consultor Full Stack Developer, Front-end y Back-end with Java, Mobile Development Android and iOS CTO at Produactivity #geek #traveler #speaker Mercedes Wyss @itrjwyss
3
Agenda Play Framework Web Services Restful JSONs JWT (Json Web Tokens)
4
Agenda Play Framework Web Services Restful JSONs JWT (Json Web Tokens)
Database Connection (JPA, JDBC)
6
Play Framework Makes it easy to build web applications with Java and Scala. Is based on a lightweight, stateless, web-friendly architecture. Built on Akka, provides predictable and minimal resources consumption (CPU, memory, threads) for highly-scalable applications.
8
Servidor: 1 CPU 1 GB Ram
10
Java or Scala
11
Is Reactive
12
MVC Architecture
13
App Server Since Version 2.6.x Fewer Configurations
14
JRebel Behavior More code, Less deploys
15
How start a Play project?
We need to use SBT Create sbt new playframework/play-scala-seed.g8 sbt new playframework/play-java-seed.g8 Deploy sbt run
16
$ sudo sbt new playframework/play-java-seed.g8
This template generates a Play Java project name [play-java-seed]: OracleCodeSydney organization [com.example]: com.produactivity scala_version [2.12.2]: play_version [2.6.1]: Template applied in ./oraclecodesydney $
17
$ cd oraclecodesydney/
Oraclecodesydney $ sbt run
20
Full Project Structure
21
Simple Project Structure
27
Agenda Play Framework Web Services Restful JSONs JWT (Json Web Tokens)
29
Web Services HyperText Transfer Protocol (HTTP)
Allows communication between a client and a server Provide a standard means of interoperating between different software apps Characterized for interoperability and extensibility Based on XML
30
Linda. com (June 2017) https://www. lynda
31
SOAP Simple Object Access Protocol XML-based
Use WSDL as specification description (Web Services Description Language) Need to follow a communication protocol
33
Restful Software Architecture based on HTTP methods
(Get, Post, Put, Delete, etc) Typically use JSON, but can use XML, Text
34
Madhaiyan Muthu (June 2017) https://www. slideshare
38
Agenda Play Framework Web Services Restful JSONs JWT (Json Web Tokens)
40
JSON JavaScript Object Notation
Is a lightweight data-interchange format Self-describing Human-reading Is a Protocol
41
JSON Example
42
JSON Scheme
47
Agenda Play Framework Web Services Restful JSONs JWT (Json Web Tokens)
49
JWT Is an open standard (RFC 7519) that defines a compact and self-contained way for securely transmitting information between parties as a JSON object.
50
Auth0 (June 2017) https://cdn.auth0.com/content/jwt/jwt-diagram.png
51
JWT Structure
52
JWT Structure
53
JWT Structure
54
To End Let’s See the Magic Live
México
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.