O slideshow foi denunciado.
Seu SlideShare está sendo baixado. ×

OpenAPI Generator The Babel Fish of The API World - apidays Live Australia

Anúncio
Anúncio
Anúncio
Anúncio
Anúncio
Anúncio
Anúncio
Anúncio
Anúncio
Anúncio
Anúncio
Anúncio
Carregando em…3
×

Confira estes a seguir

1 de 41 Anúncio

Mais Conteúdo rRelacionado

Diapositivos para si (20)

Semelhante a OpenAPI Generator The Babel Fish of The API World - apidays Live Australia (20)

Anúncio

Mais de Cliffano Subagio (17)

Mais recentes (20)

Anúncio

OpenAPI Generator The Babel Fish of The API World - apidays Live Australia

  1. 1. Open API Generator
 The Babel Fish of the API World Cliffano Subagio | Shine Solutions Apidays Live Australia – 15 & 16 September 2021
  2. 2. About Cliffano Subagio Principal Engineer at Shine Solutions Member of OpenAPI Generator Technical Committee
  3. 3. Agenda 1. The polyglot systems and the Babel fis h 2. Intro to OpenAPI Generato r 3. My use case scenario s 4. Wrap up + let’s contribute
  4. 4. 1. The polyglot systems and the Babel Fish
  5. 5. © 2020 Shine Solutions Group Back in the 2000s,
 I was a Java developer 5 • Monolithic J2EE application s • 100% pure Java mindset within the community
  6. 6. Monolithic Application 6 Java
  7. 7. 
 YOW! 2012 talks
 by Fred Georg e Micro Services Architecture
 Language agnostic service s Programmer Anarchy
 Use of Ruby, Clojure, C++, Node.js
  8. 8. Multi Services 8 Ruby Clojure node.js Go Python Java .NET
  9. 9. If you stick one
 in your ear The Babel fish
  10. 10. You instantly understand
 anything sent to you
 in any language
  11. 11. Multi Services 11 Ruby Clojure node.js Go Python Java .NET
  12. 12. 2. Intro to OpenAPI Generator
  13. 13. OpenAPI Generator 13 • Open source code generator librar y • Written in Java, uses Mustache template s • Generates API clients, server stubs, doc s • Supports 40+ tech stack s • Community fork of Swagger CodeGen • Almost 10k GitHub stars
 Almost 2k contributors
  14. 14. How does it work? 14 OpenAPI
 Specification OpenAPI
 Generator API Clients API Servers API Docs Swagger-Parser Generator Templates
  15. 15. Example: ipify 15 api.ipify.org GET / ?format=json 200 OK
 { “ip”: “60.240.197.183” }
  16. 16. OpenAPI specification 16 metadata paths responses schemas parameters
  17. 17. Running the generator 17
  18. 18. Running the generator 18
  19. 19. What will be generated? 19 • Project structur e • OpenAPI Generator metadat a • READM E • CI confi g • Library dependencie s • Documentatio n • Unit test s • API client:
 Clients, data model s • API server stubs:
 Endpoints, controllers, payloads
  20. 20. Generated API clients 20 Python Ruby node.js
  21. 21. Generated API clients 21 Java
  22. 22. Example Ruby API client 22
  23. 23. Supported tech stacks 23
  24. 24. 3. My use case scenarios
  25. 25. SOA with custom ESB (mostly Java) 25 ESB Identity
 Service Adapter
 Service Data
 Service Consolidation
 Service Routing
 Service Message
 Service Monitor
 Service
  26. 26. SDK Clients for a REST API 26 API Gateway (OpenAPI) node.js Python Go Java
  27. 27. Infrastructure as Code 27 Legacy Enterprise Application CLI (node.js) Ruby
 API Client Python
 API Client SpringBoot App (Java) Ansible Playbook Puppet Module InSpec Profile
  28. 28. Performance testing 28 Web
 App JMeter JMX CSV
  29. 29. Jenkins CI/CD 29 Swaggy-
 Jenkins CLI Smart Light
 Notifiers Voice
 App
  30. 30. Top three maintenance tips… 30 1. Integration testing 2. Integration testing 3. Integration testing
  31. 31. 31 OpenAPI Spec v2 OpenAPI Spec v3 OpenAPI Generator v2 OAG v3 v4 v5 Python 2 Python 3 Ruby 1.9 Ruby 2.3 Ruby 2.5 Ruby 2.6 My application changes Dependency Vulnerabilities Environment changes Changes happen all the time!
  32. 32. 4. Wrap up + let’s contribute
  33. 33. Remember the Babel fish? 33 Ruby Clojure node.js Go Python Java .NET
  34. 34. OpenAPI Generator 34 https://openapi-generator.tech • Multi tech-stacks suppor t • Boilerplate code for fre e • Massive time saver
  35. 35. My first contribution 35 I optimised file downloading
 in Ruby API client’s
  36. 36. Failed to allocate memory at 2Gb
  37. 37. 100Mb+ memory consumption
  38. 38. Your contributions are welcomed!
 
 https://github.com/OpenAPITools/ openapi-generator
  39. 39. Helping OpenAPI Generator If you find OpenAPI Generator useful,
 please consider becoming a sponsor.
 
 https://opencollective.com/ openapi_generator
  40. 40. Thank you! Any questions? cliff.subagio@shinesolutions.com linkedin.com/in/cliffano/
  41. 41. Resources https://openapi-generator.tech/ https://github.com/OpenAPITools/openapi-generator/ https://en.wikipedia.org/wiki/ The_Hitchhiker%27s_Guide_to_the_Galaxy#Future_predictions https://www.youtube.com/watch?v=YWqHkYtREAE https://www.youtube.com/watch?v=cbFLGv41vBA https://www.youtube.com/watch?v=sns1DknIwhQ https://opencollective.com/openapi_generator https://en.wikipedia.org/wiki/OpenAPI_Specification https://swagger.io/specification/ https://github.com/cliffano/openapi-ipify https://github.com/cliffano/swaggy-jenkins https://github.com/shinesolutions/swagger-aem https://pixabay.com/photos/boat-shell-rowing-rowers-sport-3404551/

×