Demo of Swagger-Codegen CXF server stub generator including coverage of the Swagger-Toolchain (Swagger-UI/Swagger-Editor/Swagger2Markup) and demo of how to customize a language in Swagger-Codegen
@DevFest Vienna 2016
Swagger is a specification and complete framework implementation for describing, producing, consuming, and visualizing RESTful web services. The overarching goal of Swagger is to enable client and documentation systems to update at the same pace as the server. The documentation of methods, parameters, and models are tightly integrated into the server code, allowing APIs to always stay in sync. With Swagger, deploying managing, and using powerful APIs has never been easier.
[JavaLand 2015] Developing JavaScript Mobile Apps Using Apache CordovaHazem Saleh
The document discusses how to develop JavaScript mobile apps using Apache Cordova, an open-source framework that allows developers to create mobile apps using HTML, CSS and JavaScript and access native device functions. It provides an overview of Cordova, how to configure and use Cordova commands, the Cordova APIs, and tips for integrating jQuery Mobile with Cordova apps. Code samples and links are included to help developers get started building Cordova apps.
Developing Native Mobile Apps Using JavaScript, ApacheCon NA 2014Hazem Saleh
This document provides an overview of developing native mobile apps using Apache Cordova. Cordova allows developing apps with HTML, CSS and JavaScript that can be deployed across platforms. It introduces Cordova, discusses its advantages over native development, and covers Cordova commands, APIs and integration with jQuery Mobile. An example Memo app demo is also presented.
Continuous Integration and development environment approachAleksandr Tsertkov
Continuous integration provides quick feedback on recent code changes through automated builds run regularly from a CI server. Each build has a status of success or failure and publishes artifacts like binaries, test results, and metrics. Peer code review helps improve code quality by having developers systematically review each other's code in small teams using tools like Reviewboard, Crucible, and CodeCollaborator. The engineering environment approach presented utilizes dedicated servers for remote development, with components like Subversion for version control, CruiseControl for continuous integration, and Crucible for peer review to facilitate collaboration.
This document summarizes a presentation about developing custom plugins and testing Cordova apps. It discusses:
- Creating custom Cordova plugins using Plugman to scaffold code and define JavaScript interfaces. Native implementations are then added.
- Integrating cloud push notifications using the IBM Bluemix plugin, including registering devices, subscribing to tags, and receiving notifications.
- Unit testing Cordova apps with Jasmine, a JavaScript testing framework that supports synchronous and asynchronous code. Async tests require calling a done callback.
- Demos of creating a custom plugin and unit testing a Cordova app with Jasmine are included.
[JMaghreb 2014] Developing JavaScript Mobile Apps Using Apache CordovaHazem Saleh
Apache Cordova is a platform for building native mobile applications using common Web technologies (HTML, CSS and JavaScript). Apache Cordova offers a set of APIs that allow the mobile application developers to access mobile native functions such as (Audio, Camera, File, Battery, Contacts …etc) using JavaScript. Although there are many JavaScript mobile application frameworks, jQuery mobile is one of the best mobile web application frameworks which allows the web developers to develop web applications that are mobile friendly. This session illustrates how to use Apache Cordova with the combination of jQuery mobile in order to develop a native Android application and deploy on a real Android device. The demo application (“Memo” application) utilizes mobile native functions (Audio and Camera) using pure JavaScript.
1) Apache Cordova allows developers to use web technologies like HTML, CSS, and JavaScript to build mobile apps that can access native device features and be deployed to app stores.
2) Cordova uses a command line interface for creating projects, adding platforms, and building apps. It also provides APIs for accessing device features through plugins.
3) jQuery Mobile is a popular framework for building the user interface of Cordova apps, though other frameworks can also be used. Special considerations are needed for each mobile platform.
[Devoxx Morocco 2015] Apache Cordova In ActionHazem Saleh
Apache Cordova is a platform for building native mobile apps using common Web technologies (HTML, CSS and JavaScript). Apache Cordova offers a set of APIs that allow the mobile app developers to utilize mobile native functions such as (Audio, Camera, Contacts …etc) using JavaScript. jQuery mobile is one of the best mobile web application frameworks, which allows the web developers to develop neat mobile web applications. This session discusses why there is a need for Hybrid mobile development, the current challenges of mobile development, and how using Apache Cordova can help in overcoming many of these technical challenges. It also highlights the best practices of using Apache Cordova with jQuery mobile. Finally, it demonstrates a real Cordova mobile app for showing the audience the best practices of designing, developing, and deploying hybrid Android and iOS mobile apps.
Swagger is a specification and complete framework implementation for describing, producing, consuming, and visualizing RESTful web services. The overarching goal of Swagger is to enable client and documentation systems to update at the same pace as the server. The documentation of methods, parameters, and models are tightly integrated into the server code, allowing APIs to always stay in sync. With Swagger, deploying managing, and using powerful APIs has never been easier.
[JavaLand 2015] Developing JavaScript Mobile Apps Using Apache CordovaHazem Saleh
The document discusses how to develop JavaScript mobile apps using Apache Cordova, an open-source framework that allows developers to create mobile apps using HTML, CSS and JavaScript and access native device functions. It provides an overview of Cordova, how to configure and use Cordova commands, the Cordova APIs, and tips for integrating jQuery Mobile with Cordova apps. Code samples and links are included to help developers get started building Cordova apps.
Developing Native Mobile Apps Using JavaScript, ApacheCon NA 2014Hazem Saleh
This document provides an overview of developing native mobile apps using Apache Cordova. Cordova allows developing apps with HTML, CSS and JavaScript that can be deployed across platforms. It introduces Cordova, discusses its advantages over native development, and covers Cordova commands, APIs and integration with jQuery Mobile. An example Memo app demo is also presented.
Continuous Integration and development environment approachAleksandr Tsertkov
Continuous integration provides quick feedback on recent code changes through automated builds run regularly from a CI server. Each build has a status of success or failure and publishes artifacts like binaries, test results, and metrics. Peer code review helps improve code quality by having developers systematically review each other's code in small teams using tools like Reviewboard, Crucible, and CodeCollaborator. The engineering environment approach presented utilizes dedicated servers for remote development, with components like Subversion for version control, CruiseControl for continuous integration, and Crucible for peer review to facilitate collaboration.
This document summarizes a presentation about developing custom plugins and testing Cordova apps. It discusses:
- Creating custom Cordova plugins using Plugman to scaffold code and define JavaScript interfaces. Native implementations are then added.
- Integrating cloud push notifications using the IBM Bluemix plugin, including registering devices, subscribing to tags, and receiving notifications.
- Unit testing Cordova apps with Jasmine, a JavaScript testing framework that supports synchronous and asynchronous code. Async tests require calling a done callback.
- Demos of creating a custom plugin and unit testing a Cordova app with Jasmine are included.
[JMaghreb 2014] Developing JavaScript Mobile Apps Using Apache CordovaHazem Saleh
Apache Cordova is a platform for building native mobile applications using common Web technologies (HTML, CSS and JavaScript). Apache Cordova offers a set of APIs that allow the mobile application developers to access mobile native functions such as (Audio, Camera, File, Battery, Contacts …etc) using JavaScript. Although there are many JavaScript mobile application frameworks, jQuery mobile is one of the best mobile web application frameworks which allows the web developers to develop web applications that are mobile friendly. This session illustrates how to use Apache Cordova with the combination of jQuery mobile in order to develop a native Android application and deploy on a real Android device. The demo application (“Memo” application) utilizes mobile native functions (Audio and Camera) using pure JavaScript.
1) Apache Cordova allows developers to use web technologies like HTML, CSS, and JavaScript to build mobile apps that can access native device features and be deployed to app stores.
2) Cordova uses a command line interface for creating projects, adding platforms, and building apps. It also provides APIs for accessing device features through plugins.
3) jQuery Mobile is a popular framework for building the user interface of Cordova apps, though other frameworks can also be used. Special considerations are needed for each mobile platform.
[Devoxx Morocco 2015] Apache Cordova In ActionHazem Saleh
Apache Cordova is a platform for building native mobile apps using common Web technologies (HTML, CSS and JavaScript). Apache Cordova offers a set of APIs that allow the mobile app developers to utilize mobile native functions such as (Audio, Camera, Contacts …etc) using JavaScript. jQuery mobile is one of the best mobile web application frameworks, which allows the web developers to develop neat mobile web applications. This session discusses why there is a need for Hybrid mobile development, the current challenges of mobile development, and how using Apache Cordova can help in overcoming many of these technical challenges. It also highlights the best practices of using Apache Cordova with jQuery mobile. Finally, it demonstrates a real Cordova mobile app for showing the audience the best practices of designing, developing, and deploying hybrid Android and iOS mobile apps.
Document your rest api using swagger - Devoxx 2015johannes_fiala
This session will show you how you can easily document your REST API's using Spring & Swagger.
It will show you how to use the Swagger-Spring integration in a Spring Boot application:
Setup a basic REST API using Spring-Boot together with Swagger-Springfox
Access and test the REST-API using the Swagger-UI client
Generate client code stubs for your language (e.g. Java, PHP, Python, ...) using Swagger-Codegen
Graphically display your REST-API using the Chrome plugin Swagger.ed
Devoxx Belgium Nov. 2015
Angular based enterprise level frontend architectureHimanshu Tamrakar
This document discusses different frontend architectures for Angular applications:
1. Using npm packages to create and distribute libraries that can be installed and used by other applications.
2. Implementing a mono repo architecture where related projects share a single code repository and node_modules folder.
3. Developing applications using a micro frontend architecture where features are developed as separate modules that can be independently deployed.
The document compares the advantages and disadvantages of each approach and provides examples of how to implement them using Angular CLI or Nx.
Writer APIs in Java faster with Swagger InflectorTony Tam
Swagger provides a clean contract for your REST API. Swagger Inflector is a project which uses Swagger as the language of the API, automatically wiring REST endpoints directly to controllers in the Jersey 2.x framework. By doing so, the specification and code are always up to date, removing potentially error-prone redundant code and bringing development on the JDK up to speed with typeless languages.
This document summarizes a presentation about using Jenkins in AWS. It discusses installation options for Jenkins including using the LTS version or AWS Marketplace. It also overview Jenkins plugins and security options. The presentation demonstrates integrating Jenkins with AWS services like EC2 for managing slave instances, CodeDeploy for deployments, CodeCommit for source control, and CodePipeline for continuous delivery pipelines. It provides details on setting up IAM roles, policies and configuring the required AWS plugins in Jenkins.
Scale your PHP application with Elastic Beanstalk - CloudParty GenovaCorley S.r.l.
This document discusses how to scale a PHP application using ElasticBeanstalk. ElasticBeanstalk allows running applications across dynamically sized fleets of EC2 instances that are managed using simple configuration files. It handles tasks like deploying code and configuration changes, monitoring and scaling application traffic. Some key points discussed include running different environments for development, testing and production; using Composer to manage dependencies and configuration; customizing using .ebextensions files; and monitoring and collecting logs.
The document discusses the benefits of using Gradle for Android application builds over other build tools like Ant and Maven. It highlights how Gradle combines the flexibility of Ant with the dependency management of Maven. It also describes key Gradle features like building different variants of an app for different flavors, customizing builds for debug vs release, and managing dependencies. The document provides examples of basic Gradle configuration, defining dependencies, customizing builds, and managing resources and placeholders.
[AnDevCon 2016] Mutation Testing for AndroidHazem Saleh
Unit testing coverage is a great way to show us the amount of tested lines and branches of code, but is this really enough? The answer is "no" since unit testing coverage does not really fully measure the efficiency of the unit tests.
This is why there is a need for having techniques that show unit tests efficiency. Mutation testing is one of these powerful techniques. The main idea of mutation testing is to perform byte code modifications (mutations) to original Android app source code and then run app unit tests to check if they are strong enough to fail as a result of these mutations.
This session discusses mutation testing techniques, and demonstrates PIT as a powerful mutation testing tool for Android apps with demos.
Crystal clear service interfaces w/ Swagger/OpenAPIScott Triglia
Learn how to better communicate between Python services. We'll use simple-to-follow examples and go from a service with undocumented endpoints to one which has full docs and validation on requests. Learn how to use Swagger tooling for python, including the bravado (client) and pyramid_swagger (server) libraries. In the end, you'll (hopefully!) find nirvana and make the machines do all the hard work for you.
Midas - on-the-fly schema migration tool for MongoDB.Dhaval Dalal
Midas is an on-the-fly schema migration for MongoDB.
Currently, applications have to hand-roll their own schema migration infrastructure or use some third-party tool.
It is difficult to migrate TBs of data without downtime (unacceptable from SLA stand-point!).
This is where Midas fills the gap.
It intercepts responses at MongoDB Protocol level and upgrades or downgrades document schema in-transit.
As Midas works at protocol level, it is agnostic of Language specific MongoDB drivers (Ruby, Python, C#
and Java drivers) and their versions within those languages.
Further, Midas is agnostic of the MongoDB configurations like Standalone, Replica Sets, Sharded environments.
Features Summary:
* Expansion operations - add, copy, merge, split, transform.
* Contraction operations - remove
* Schema migration for multiple applications simultaneously
* Support multi node configuration for application
* Without shutting down Midas, you can -
* Add or remove applications on-the-fly
* Add or remove nodes on-the-fly
* Add or remove deltas/changeset on-the-fly
Continous UI testing with Espresso and JenkinsSylwester Madej
Talk from Droidcon Zagreb 2015 about approach to Continous Integration and integration testing we are using in Outline.
In short: we use Jenkins CI on Intel NUC to build, analyse and test apps. To speed up tests we are using Spoon with some devices connected to our CI server via USB hub.
The document discusses several frequently encountered issues when testing cross-browser, including time dependence, managing test virtual machines, random DOM IDs, testing layout, unit testing JavaScript, model layer access in tests, starting state, and parallel test runs. Some solutions proposed include using fixtures to manage database state, cleaning up the database between tests, and starting multiple browser instances in parallel to speed up test runs.
How We Built a Mobile Electronic Health Record App Using Xamarin, Angular, an...Matt Spradley
1) The document describes how the author built a mobile electronic health record app using Xamarin, Angular, and Web API.
2) They used Angular for the web UI and Xamarin for native platform capabilities. A JavaScript bridge was used to connect the two.
3) Azure Service Bus Relay was employed to allow communication with on-premise servers despite network restrictions. This demonstrated good performance.
JavaScript for ABAP Programmers - 4/7 ScopeChris Whealy
This document discusses JavaScript execution contexts and variable/property declarations in the global context. There are three execution contexts: the global context, function contexts, and eval contexts. The global context is created once for the entire runtime and is accessible via the window object in browsers. Variables are declared with var and belong to the variable object of their context, while properties without var automatically belong to the global/window object. This can make global variables appear similar to properties.
JavaScript for ABAP Programmers - 1/7 IntroductionChris Whealy
JavaScript was originally created as Mocha in 1995 by Brendan Eich at Netscape in 10 days and was renamed LiveScript and then JavaScript to complement Sun Microsystem's Java, though it is not the same as Java. It borrows elements from languages like Scheme and Perl. JavaScript is standardized by ECMA and various JavaScript engines like SpiderMonkey, Chakra, V8, and Nitro execute it client-side in browsers or server-side in implementations like HANA XSJS. The main differences between JavaScript and ABAP are that JavaScript is weakly typed, has lexical scope, treats functions as first-class citizens, uses prototypal inheritance, and allows both imperative and functional programming.
Introduction to Codenvy / JugSummerCamp 2014Florent BENOIT
This document provides an overview of Codenvy, an open source cloud IDE platform. It summarizes Codenvy's user base, products, company information, and key features. The document demonstrates Codenvy's dashboard, code editor, factory configuration, command line tool, SDK for extensions, and plugins for AngularJS and connecting to data sources.
This document provides an agenda for a presentation on mobile continuous integration and Appium. It includes topics like what Xamarin is, continuous integration, deploying and installing APKs, using Appium for automation, and configuring Android emulators for speed. Code samples are also provided for setting up a test project in Appium, finding objects, and common WebDriver commands.
The Java microservice lib. QBit is a reactive programming lib for building microservices - JSON, HTTP, WebSocket, and REST. QBit uses reactive programming to build elastic REST, and WebSockets based cloud friendly, web services. SOA evolved for mobile and cloud. QBit is a Java first programming model. It uses common Java idioms to do reactive programming.
It focuses on Java 8. It is one of the few of a crowded field of reactive programming libs/frameworks that focuses on Java 8. It is not a lib written in XYZ that has a few Java examples to mark a check off list. It is written in Java and focuses on Java reactive programming using active objects architecture which is a focus on OOP reactive programming with lambdas and is not a pure functional play. It is a Java 8 play on reactive programming.
Services can be stateful, which fits the micro service architecture well. Services will typically own or lease the data instead of using a cache.
CPU Sharded services, each service does a portion of the workload in its own thread to maximize core utilization.
The idea here is you have a large mass of data that you need to do calculations on. You can keep the data in memory (fault it in or just keep in the largest part of the histogram in memory not the long tail). You shard on an argument to the service methods. (This was how I wrote some personalization engine in the recent past).
Worker Pool service, these are for IO where you have to talk to an IO service that is not async (database usually or legacy integration) or even if you just have to do a lot of IO. These services are semi-stateless. They may manage conversational state of many requests but it is transient.
ServiceQueue wraps a Java object and forces methods calls, responses and events to go through high-speed, batching queues.
ServiceBundle uses a collection of ServiceQueues.
ServiceServer uses a ServiceBundle and exposes it to REST/JSON and WebSocket/JSON.
Events are integrated into the system. You can register for an event using an annotation @EventChannel, or you can implement the event channel interface. Event Bus can be replicated. Event busses can be clustered (optional library). There is not one event bus. You can create as many as you like. Currently the event bus works over WebSocket/JSON. You could receive events from non-Java applications.
Find out more at: https://github.com/advantageous/qbit
Document your rest api using swagger - Devoxx 2015johannes_fiala
This session will show you how you can easily document your REST API's using Spring & Swagger.
It will show you how to use the Swagger-Spring integration in a Spring Boot application:
Setup a basic REST API using Spring-Boot together with Swagger-Springfox
Access and test the REST-API using the Swagger-UI client
Generate client code stubs for your language (e.g. Java, PHP, Python, ...) using Swagger-Codegen
Graphically display your REST-API using the Chrome plugin Swagger.ed
Devoxx Belgium Nov. 2015
Angular based enterprise level frontend architectureHimanshu Tamrakar
This document discusses different frontend architectures for Angular applications:
1. Using npm packages to create and distribute libraries that can be installed and used by other applications.
2. Implementing a mono repo architecture where related projects share a single code repository and node_modules folder.
3. Developing applications using a micro frontend architecture where features are developed as separate modules that can be independently deployed.
The document compares the advantages and disadvantages of each approach and provides examples of how to implement them using Angular CLI or Nx.
Writer APIs in Java faster with Swagger InflectorTony Tam
Swagger provides a clean contract for your REST API. Swagger Inflector is a project which uses Swagger as the language of the API, automatically wiring REST endpoints directly to controllers in the Jersey 2.x framework. By doing so, the specification and code are always up to date, removing potentially error-prone redundant code and bringing development on the JDK up to speed with typeless languages.
This document summarizes a presentation about using Jenkins in AWS. It discusses installation options for Jenkins including using the LTS version or AWS Marketplace. It also overview Jenkins plugins and security options. The presentation demonstrates integrating Jenkins with AWS services like EC2 for managing slave instances, CodeDeploy for deployments, CodeCommit for source control, and CodePipeline for continuous delivery pipelines. It provides details on setting up IAM roles, policies and configuring the required AWS plugins in Jenkins.
Scale your PHP application with Elastic Beanstalk - CloudParty GenovaCorley S.r.l.
This document discusses how to scale a PHP application using ElasticBeanstalk. ElasticBeanstalk allows running applications across dynamically sized fleets of EC2 instances that are managed using simple configuration files. It handles tasks like deploying code and configuration changes, monitoring and scaling application traffic. Some key points discussed include running different environments for development, testing and production; using Composer to manage dependencies and configuration; customizing using .ebextensions files; and monitoring and collecting logs.
The document discusses the benefits of using Gradle for Android application builds over other build tools like Ant and Maven. It highlights how Gradle combines the flexibility of Ant with the dependency management of Maven. It also describes key Gradle features like building different variants of an app for different flavors, customizing builds for debug vs release, and managing dependencies. The document provides examples of basic Gradle configuration, defining dependencies, customizing builds, and managing resources and placeholders.
[AnDevCon 2016] Mutation Testing for AndroidHazem Saleh
Unit testing coverage is a great way to show us the amount of tested lines and branches of code, but is this really enough? The answer is "no" since unit testing coverage does not really fully measure the efficiency of the unit tests.
This is why there is a need for having techniques that show unit tests efficiency. Mutation testing is one of these powerful techniques. The main idea of mutation testing is to perform byte code modifications (mutations) to original Android app source code and then run app unit tests to check if they are strong enough to fail as a result of these mutations.
This session discusses mutation testing techniques, and demonstrates PIT as a powerful mutation testing tool for Android apps with demos.
Crystal clear service interfaces w/ Swagger/OpenAPIScott Triglia
Learn how to better communicate between Python services. We'll use simple-to-follow examples and go from a service with undocumented endpoints to one which has full docs and validation on requests. Learn how to use Swagger tooling for python, including the bravado (client) and pyramid_swagger (server) libraries. In the end, you'll (hopefully!) find nirvana and make the machines do all the hard work for you.
Midas - on-the-fly schema migration tool for MongoDB.Dhaval Dalal
Midas is an on-the-fly schema migration for MongoDB.
Currently, applications have to hand-roll their own schema migration infrastructure or use some third-party tool.
It is difficult to migrate TBs of data without downtime (unacceptable from SLA stand-point!).
This is where Midas fills the gap.
It intercepts responses at MongoDB Protocol level and upgrades or downgrades document schema in-transit.
As Midas works at protocol level, it is agnostic of Language specific MongoDB drivers (Ruby, Python, C#
and Java drivers) and their versions within those languages.
Further, Midas is agnostic of the MongoDB configurations like Standalone, Replica Sets, Sharded environments.
Features Summary:
* Expansion operations - add, copy, merge, split, transform.
* Contraction operations - remove
* Schema migration for multiple applications simultaneously
* Support multi node configuration for application
* Without shutting down Midas, you can -
* Add or remove applications on-the-fly
* Add or remove nodes on-the-fly
* Add or remove deltas/changeset on-the-fly
Continous UI testing with Espresso and JenkinsSylwester Madej
Talk from Droidcon Zagreb 2015 about approach to Continous Integration and integration testing we are using in Outline.
In short: we use Jenkins CI on Intel NUC to build, analyse and test apps. To speed up tests we are using Spoon with some devices connected to our CI server via USB hub.
The document discusses several frequently encountered issues when testing cross-browser, including time dependence, managing test virtual machines, random DOM IDs, testing layout, unit testing JavaScript, model layer access in tests, starting state, and parallel test runs. Some solutions proposed include using fixtures to manage database state, cleaning up the database between tests, and starting multiple browser instances in parallel to speed up test runs.
How We Built a Mobile Electronic Health Record App Using Xamarin, Angular, an...Matt Spradley
1) The document describes how the author built a mobile electronic health record app using Xamarin, Angular, and Web API.
2) They used Angular for the web UI and Xamarin for native platform capabilities. A JavaScript bridge was used to connect the two.
3) Azure Service Bus Relay was employed to allow communication with on-premise servers despite network restrictions. This demonstrated good performance.
JavaScript for ABAP Programmers - 4/7 ScopeChris Whealy
This document discusses JavaScript execution contexts and variable/property declarations in the global context. There are three execution contexts: the global context, function contexts, and eval contexts. The global context is created once for the entire runtime and is accessible via the window object in browsers. Variables are declared with var and belong to the variable object of their context, while properties without var automatically belong to the global/window object. This can make global variables appear similar to properties.
JavaScript for ABAP Programmers - 1/7 IntroductionChris Whealy
JavaScript was originally created as Mocha in 1995 by Brendan Eich at Netscape in 10 days and was renamed LiveScript and then JavaScript to complement Sun Microsystem's Java, though it is not the same as Java. It borrows elements from languages like Scheme and Perl. JavaScript is standardized by ECMA and various JavaScript engines like SpiderMonkey, Chakra, V8, and Nitro execute it client-side in browsers or server-side in implementations like HANA XSJS. The main differences between JavaScript and ABAP are that JavaScript is weakly typed, has lexical scope, treats functions as first-class citizens, uses prototypal inheritance, and allows both imperative and functional programming.
Introduction to Codenvy / JugSummerCamp 2014Florent BENOIT
This document provides an overview of Codenvy, an open source cloud IDE platform. It summarizes Codenvy's user base, products, company information, and key features. The document demonstrates Codenvy's dashboard, code editor, factory configuration, command line tool, SDK for extensions, and plugins for AngularJS and connecting to data sources.
This document provides an agenda for a presentation on mobile continuous integration and Appium. It includes topics like what Xamarin is, continuous integration, deploying and installing APKs, using Appium for automation, and configuring Android emulators for speed. Code samples are also provided for setting up a test project in Appium, finding objects, and common WebDriver commands.
The Java microservice lib. QBit is a reactive programming lib for building microservices - JSON, HTTP, WebSocket, and REST. QBit uses reactive programming to build elastic REST, and WebSockets based cloud friendly, web services. SOA evolved for mobile and cloud. QBit is a Java first programming model. It uses common Java idioms to do reactive programming.
It focuses on Java 8. It is one of the few of a crowded field of reactive programming libs/frameworks that focuses on Java 8. It is not a lib written in XYZ that has a few Java examples to mark a check off list. It is written in Java and focuses on Java reactive programming using active objects architecture which is a focus on OOP reactive programming with lambdas and is not a pure functional play. It is a Java 8 play on reactive programming.
Services can be stateful, which fits the micro service architecture well. Services will typically own or lease the data instead of using a cache.
CPU Sharded services, each service does a portion of the workload in its own thread to maximize core utilization.
The idea here is you have a large mass of data that you need to do calculations on. You can keep the data in memory (fault it in or just keep in the largest part of the histogram in memory not the long tail). You shard on an argument to the service methods. (This was how I wrote some personalization engine in the recent past).
Worker Pool service, these are for IO where you have to talk to an IO service that is not async (database usually or legacy integration) or even if you just have to do a lot of IO. These services are semi-stateless. They may manage conversational state of many requests but it is transient.
ServiceQueue wraps a Java object and forces methods calls, responses and events to go through high-speed, batching queues.
ServiceBundle uses a collection of ServiceQueues.
ServiceServer uses a ServiceBundle and exposes it to REST/JSON and WebSocket/JSON.
Events are integrated into the system. You can register for an event using an annotation @EventChannel, or you can implement the event channel interface. Event Bus can be replicated. Event busses can be clustered (optional library). There is not one event bus. You can create as many as you like. Currently the event bus works over WebSocket/JSON. You could receive events from non-Java applications.
Find out more at: https://github.com/advantageous/qbit
Consumer Driven Contracts and Your Microservice Architecture @ Warsaw JUGMarcin Grzejszczak
This document discusses using Spring Cloud Contract to help define contracts between microservices. It notes that without contracts, tests between services can break when implementations change. The document demonstrates coding a sample app to check ages for alcohol purchases, then generating contract stubs using Spring Cloud Contract. It addresses questions like storing contracts in a shared repo, generating stubs without writing scripts using WireMock and RestDocs, and learning more about Spring Cloud Contract.
This document introduces Swagger, an open-source framework for describing, producing, consuming, and visualizing RESTful APIs. It provides a specification for describing APIs in a machine-readable format. Swagger allows automatically generating documentation from code and enabling tooling around REST APIs. The document discusses Swagger specifications, how to list and view API details, integration with various programming languages and frameworks, development and deployment processes, and alternatives to Swagger.
Spring Cloud Contract And Your Microservice ArchitectureMarcin Grzejszczak
Consumer driven contracts (CDC) are like TDD applied to the API. It’s especially important in the world of microservices. Since it’s driven by consumers, it’s much more user friendly. Of course microservices are really cool, but most people do not take into consideration plenty of potential obstacles that should be tackled. Then instead of frequent, fully automated deploys via a delivery pipeline, you might end up in an asylum due to frequent mental breakdowns caused by production disasters. We will write a system using the CDC approach together with Spring Boot, Spring Cloud Contract verifier. I'll show you how easy it is to write applications that have a consumer driven API and that will allow a developer to speed up the time of writing his better quality software.
Building REST APIs with Spring Boot and Spring CloudKenny Bastani
In this talk I will introduce you to Spring Cloud, a set of tools for building cloud-native JVM applications. We will take a look at some of the common patterns for microservice architectures and how to use Cloud Foundry to deploy multiple microservices to the cloud.
We will also dive into a microservices example project of a cloud-native application built using Spring Boot and Spring Cloud. Using this example project, I'll show you how to use Lattice to spin up a microservice cluster on AWS. We will then explore what a cloud-native application looks like when using self-describing REST APIs that link multiple microservices together.
Consumer Driven Contracts and Your Microservice ArchitectureMarcin Grzejszczak
TDD introduced many improvements into the development process, but in our opinion the biggest impact relates to code design. Looking at the code from the usage perspective (by first writing an acceptance test) allows us to focus on usability rather than concrete implementation. Unfortunately, we usually rest on our laurels not trying to uplift this practice to the architecture level.
This presentation will show you how you can use the Spring Cloud Contract Verifier functionality in order to have a fully automated solution to stub your HTTP / Messaging collaborators. Just by adding proper configuration, you'll surround the microservices you are testing with faked stubs that are tested against their producer, making much more realistic tests.
We will write a system using the CDC approach together with Spring Boot, Spring Cloud and Spring Cloud Contract Verifier. I'll show you how easy it is to write applications that have a consumer-driven API, allowing a developer to speed up the time for writing better quality software.
API Developer Experience: Why it Matters, and How Documenting Your API with S...SmartBear
Whether you’re new to Swagger, or have already been using the framework for API design, there’s a good chance you still have questions about how to improve your API documentation. Creating API documentation your consumers will love can take some work, but the investment will have a significant payoff in the form of a great developer experience, easier implementation, and improved adoption of your API.
This presentation covers good developer experience in detail, focusing on why and how to provide an optimal experience for developers using your API. We will also cover how Swagger has changed the API design and documentation landscape, and finally show some good practices for API documentation using Swagger in SwaggerHub’s integrated API development platform.
Things to expect in this webinar:
What is Developer Experience (DX)?
What does it mean for an API to have good DX?
API documentation in the context of good DX?
An introduction to the Swagger framework
Designing APIs from a usability perspective using Swagger and SwaggerHub
Microservices Tracing With Spring Cloud and Zipkin @Szczecin JUGMarcin Grzejszczak
The hype related to microservices continues. It’s already common knowledge that creating distributed systems is not easy. It’s high time to show how that complexity can be contained.
Service Discovery and Registry (Zookeeper / Consul / Eureka), easy request sending with client side load balancing (Feign + Ribbon), request proxying with Zuul. Everything is easy with Spring Cloud. Just add a dependency, a couple of lines of configuration and you’re ready to go.
That’s fixing difficulties related to writing code - what about solving the complexity of debugging distributed systems? Log correlation and visualizing latency of parts of the system? Spring Cloud Sleuth with Zipkin to the rescue!
The presentation will consist of some theory but there’ll also be live coding and demos.
Jcon 2017 How to use Swagger to develop REST applicationsjohannes_fiala
Demo of the Swagger toolchain (Swagger Editor, Eclipse KaiZen Plugin, Swagger-Codegen server/client generator, Swagger2Markup) all with Apache CXF3 + Spring Boot integration
How to generate a REST CXF3 application from Swagger ApacheConEU 2016johannes_fiala
This presentation shows you how you can generate server stubs from a Swagger contract,
configure the jaxrs-cxf language to enable Spring-configuration, Spring-Boot integration + tests, automatic BeanValidation on the server side,
generate client code for java and javascript, use/integrate swagger-ui, use swagger2markup
use custom Swagger-Codegen templates + how you can create your own language implementation.
The document provides an overview of application lifecycle management (ALM) in a serverless world. It discusses key concepts like continuous integration/delivery and testing practices for serverless applications. Serverless architectures using AWS Lambda and API Gateway are highlighted, along with how to manage deployments, configurations, and monitor applications.
This document provides an overview of serverless applications and how to build one. It discusses what serverless means, common use cases, how to bundle and deploy code, continuous integration and delivery, versioning, monitoring, and more. Specific AWS services for building serverless applications are also covered, including AWS Lambda, API Gateway, DynamoDB, S3, CloudFormation, CodeBuild, CodePipeline, X-Ray and CloudWatch.
This document discusses consuming RESTful APIs using Swagger v2.0. It provides an overview of Swagger and how it can be used to automatically generate client code for APIs in multiple languages like Android and iOS. It also discusses some common issues with code generation and outlines Outware's approach to address these issues, including customizing the code generation, publishing clients as dependencies, and maintaining consistency across platforms.
API Gateway is a fully managed service that makes it easy for developers to create, publish, maintain, monitor, and secure APIs at any scale. It allows hosting multiple API versions and stages, generating SDKs, adding authentication, throttling requests, and caching responses to improve performance and reduce latency. API Gateway supports building and deploying REST and WebSocket APIs. Pricing is based on the number of API calls and amount of data transferred out. Optional dedicated caching tiers are also available.
This session will introduce Spring/Alfresco development tools such as WebScript editor, WebScript Documentation plugin, FreeMarker editor, JavaScript editor, Surf Roo addon and Surf Spring template projects. We'll demonstrate how to use these tools to create, build, deploy and test Surf or Webscript-based projects. We'll also have a discussion on the future of Alfresco development tools and the SDK.
This document summarizes Amazon API Gateway, a fully managed service that allows developers to create, publish, maintain, monitor, and secure APIs at any scale. Key features include hosting multiple API versions and stages, generating SDKs for clients, throttling requests to protect backends, caching API responses, and metering usage with API keys. It also describes how to configure resources and methods, deploy APIs to stages, leverage authentication options like AWS SigV4, and view pricing which includes 1 million free requests per month.
Google Cloud Endpoints provides tools and libraries to easily create shared backends for web and mobile clients. It generates API and client libraries from App Engine applications, simplifying client access. Endpoints supports services like authentication and handles scalability. Developers annotate their backend code, then generate clients using Maven or other tools. This allows writing clients that call the backend through the generated library.
This document discusses the development of rich internet applications with ASP.NET. It provides an overview of technologies like Knockout, ASP.NET Web API, HTML5, and SignalR that enable building single page applications with client-side rendering. Knockout uses data binding and the observer pattern to update the DOM based on view model changes. The ASP.NET Web API builds on MVC to provide RESTful services that return JSON/XML data rather than views. HTML5 features like client-side validation, web storage, and Web Sockets improve the client-side experience. SignalR uses WebSockets for real-time communication between server and client.
Microsoft is taking a multifaceted approach to interoperability including collaboration with partners, developing interoperable products/technologies, promoting standards, and providing developer resources. This includes tools like Eclipse for Silverlight which allows Eclipse developers to build applications with Silverlight, and SDKs for Azure that enable PHP, Java and Ruby developers to leverage Microsoft cloud services. Customer feedback has been positive for these cross-platform tools and Microsoft is continuing work on interoperability bridges between technologies like RIA, SOA, identity and web services.
Today’s cutting edge companies have software release cycles measured in days instead of months. This agility is enabled by the DevOps practice of continuous integration and delivery, which automates building, testing, and deploying all code changes. This automation helps you catch bugs sooner and accelerates developer productivity. In this session, we’ll share the processes followed by Amazon engineers and discuss how you can bring them to your company by using a set of application lifecycle management tools from AWS: the newly announced AWS CodeBuild service, AWS CodePipeline, and AWS CodeDeploy.
This document provides an overview and agenda for a presentation on Google Web Toolkit (GWT). It introduces GWT as a Java framework for building AJAX applications that compiles to JavaScript. The agenda covers building user interfaces with GWT widgets, handling events, and applying styles. It also discusses client-side RPC, creating and deploying GWT apps, history management, internationalization, JUnit testing, and the Javascript Native Interface. Later sections cover GWT best practices, security, performance, caching, design considerations, and common issues.
This document provides an overview and agenda for a presentation on Google Web Toolkit (GWT). It introduces GWT as a Java framework for building AJAX applications, discusses its benefits like leveraging Java tools for development and debugging. It covers key topics like building user interfaces with GWT widgets, event handling, styles, client-side RPC, creating and deploying GWT apps, history management, internationalization, JUnit testing, and the Javascript Native Interface. It also discusses GWT best practices, performance, security and internationalization.
This document provides an overview of serverless computing with Azure Functions. It discusses what serverless is and the benefits it provides like reduced DevOps workload and faster time to market. It describes the components of the serverless application platform in Azure Functions including development tools, triggers and bindings, and monitoring. It also demonstrates using Functions in the Azure portal and discusses deployment isolation, serverless APIs, and monitoring with Application Insights.
Web API or WCF - An Architectural ComparisonAdnan Masood
ASP.NET Web API is a framework that makes it easy to build HTTP services that reach a broad range of clients, including browsers and mobile devices. The new ASP.NET Web API is a continuation of the previous WCF Web API projection. WCF was originally created to enable SOAP-based services and other related bindings. However, for simpler RESTful or RPCish services (think clients like jQuery) ASP.NET Web API is a good choice.
In this meeting we discussed what do you need to understand as an architect to implement your service oriented architecture using WCF or ASP.NET web API. With code samples, we will elaborate on WCF Web API’s transition to ASP.NET Web API and respective constructs such as Service vs. Web API controller, Operation vs. Action, URI templates vs ASP.NET Routing, Message handlers, Formatters and Operation handlers vs Filters, model binders. WebApi offers support for modern HTTP programming model with full support for ASP.NET Routing, content negotiation and custom formatters, model binding and validation, filters, query composition, is easy to unit test and offers improved Inversion of Control (IoC) via DependencyResolver.
You will walk away with a sample set of services that run on Silverlight, Windows Forms, WPF, Windows Phone and ASP.NET.
Real time Communication with Signalr (Android Client)Deepak Gupta
This document discusses real-time communication using SignalR. It begins with examples of real-time applications and techniques for implementing real-time functionality like polling, long polling, and web sockets. It then introduces SignalR as a library that provides real-time functionality in ASP.NET applications and supports cross-platform communication. Implementation details are covered for both the server-side Hub API in ASP.NET and client-side usage in JavaScript and Android apps. Common use cases for SignalR are also listed.
The document discusses the AJAX Toolkit Framework (ATF), an open-source Eclipse plugin that provides tools for developing AJAX applications. It includes components like a JavaScript editor, debugger, embedded browser, DOM inspection tools, and a personality builder for customizing the framework for specific AJAX toolkits. The ATF aims to facilitate AJAX development and allow tooling to be added for various AJAX runtimes.
This document provides an overview of topics that will be covered at a Microsoft Dev Camp in 2015. The topics include introductions to ASP.NET, Visual Studio web tools, ASP.NET Web API, building real-time web applications with SignalR, and Azure services. Sessions will cover web front-end development, ASP.NET updates, consuming and building Web APIs, and real-world scenarios for scaling, updating, and deploying applications on Azure.
Similar to How to generate a rest application - DevFest Vienna 2016 (20)
Monitoring and Managing Anomaly Detection on OpenShift.pdfTosin Akinosho
Monitoring and Managing Anomaly Detection on OpenShift
Overview
Dive into the world of anomaly detection on edge devices with our comprehensive hands-on tutorial. This SlideShare presentation will guide you through the entire process, from data collection and model training to edge deployment and real-time monitoring. Perfect for those looking to implement robust anomaly detection systems on resource-constrained IoT/edge devices.
Key Topics Covered
1. Introduction to Anomaly Detection
- Understand the fundamentals of anomaly detection and its importance in identifying unusual behavior or failures in systems.
2. Understanding Edge (IoT)
- Learn about edge computing and IoT, and how they enable real-time data processing and decision-making at the source.
3. What is ArgoCD?
- Discover ArgoCD, a declarative, GitOps continuous delivery tool for Kubernetes, and its role in deploying applications on edge devices.
4. Deployment Using ArgoCD for Edge Devices
- Step-by-step guide on deploying anomaly detection models on edge devices using ArgoCD.
5. Introduction to Apache Kafka and S3
- Explore Apache Kafka for real-time data streaming and Amazon S3 for scalable storage solutions.
6. Viewing Kafka Messages in the Data Lake
- Learn how to view and analyze Kafka messages stored in a data lake for better insights.
7. What is Prometheus?
- Get to know Prometheus, an open-source monitoring and alerting toolkit, and its application in monitoring edge devices.
8. Monitoring Application Metrics with Prometheus
- Detailed instructions on setting up Prometheus to monitor the performance and health of your anomaly detection system.
9. What is Camel K?
- Introduction to Camel K, a lightweight integration framework built on Apache Camel, designed for Kubernetes.
10. Configuring Camel K Integrations for Data Pipelines
- Learn how to configure Camel K for seamless data pipeline integrations in your anomaly detection workflow.
11. What is a Jupyter Notebook?
- Overview of Jupyter Notebooks, an open-source web application for creating and sharing documents with live code, equations, visualizations, and narrative text.
12. Jupyter Notebooks with Code Examples
- Hands-on examples and code snippets in Jupyter Notebooks to help you implement and test anomaly detection models.
Main news related to the CCS TSI 2023 (2023/1695)Jakub Marek
An English 🇬🇧 translation of a presentation to the speech I gave about the main changes brought by CCS TSI 2023 at the biggest Czech conference on Communications and signalling systems on Railways, which was held in Clarion Hotel Olomouc from 7th to 9th November 2023 (konferenceszt.cz). Attended by around 500 participants and 200 on-line followers.
The original Czech 🇨🇿 version of the presentation can be found here: https://www.slideshare.net/slideshow/hlavni-novinky-souvisejici-s-ccs-tsi-2023-2023-1695/269688092 .
The videorecording (in Czech) from the presentation is available here: https://youtu.be/WzjJWm4IyPk?si=SImb06tuXGb30BEH .
Taking AI to the Next Level in Manufacturing.pdfssuserfac0301
Read Taking AI to the Next Level in Manufacturing to gain insights on AI adoption in the manufacturing industry, such as:
1. How quickly AI is being implemented in manufacturing.
2. Which barriers stand in the way of AI adoption.
3. How data quality and governance form the backbone of AI.
4. Organizational processes and structures that may inhibit effective AI adoption.
6. Ideas and approaches to help build your organization's AI strategy.
Driving Business Innovation: Latest Generative AI Advancements & Success StorySafe Software
Are you ready to revolutionize how you handle data? Join us for a webinar where we’ll bring you up to speed with the latest advancements in Generative AI technology and discover how leveraging FME with tools from giants like Google Gemini, Amazon, and Microsoft OpenAI can supercharge your workflow efficiency.
During the hour, we’ll take you through:
Guest Speaker Segment with Hannah Barrington: Dive into the world of dynamic real estate marketing with Hannah, the Marketing Manager at Workspace Group. Hear firsthand how their team generates engaging descriptions for thousands of office units by integrating diverse data sources—from PDF floorplans to web pages—using FME transformers, like OpenAIVisionConnector and AnthropicVisionConnector. This use case will show you how GenAI can streamline content creation for marketing across the board.
Ollama Use Case: Learn how Scenario Specialist Dmitri Bagh has utilized Ollama within FME to input data, create custom models, and enhance security protocols. This segment will include demos to illustrate the full capabilities of FME in AI-driven processes.
Custom AI Models: Discover how to leverage FME to build personalized AI models using your data. Whether it’s populating a model with local data for added security or integrating public AI tools, find out how FME facilitates a versatile and secure approach to AI.
We’ll wrap up with a live Q&A session where you can engage with our experts on your specific use cases, and learn more about optimizing your data workflows with AI.
This webinar is ideal for professionals seeking to harness the power of AI within their data management systems while ensuring high levels of customization and security. Whether you're a novice or an expert, gain actionable insights and strategies to elevate your data processes. Join us to see how FME and AI can revolutionize how you work with data!
How to Interpret Trends in the Kalyan Rajdhani Mix Chart.pdfChart Kalyan
A Mix Chart displays historical data of numbers in a graphical or tabular form. The Kalyan Rajdhani Mix Chart specifically shows the results of a sequence of numbers over different periods.
TrustArc Webinar - 2024 Global Privacy SurveyTrustArc
How does your privacy program stack up against your peers? What challenges are privacy teams tackling and prioritizing in 2024?
In the fifth annual Global Privacy Benchmarks Survey, we asked over 1,800 global privacy professionals and business executives to share their perspectives on the current state of privacy inside and outside of their organizations. This year’s report focused on emerging areas of importance for privacy and compliance professionals, including considerations and implications of Artificial Intelligence (AI) technologies, building brand trust, and different approaches for achieving higher privacy competence scores.
See how organizational priorities and strategic approaches to data security and privacy are evolving around the globe.
This webinar will review:
- The top 10 privacy insights from the fifth annual Global Privacy Benchmarks Survey
- The top challenges for privacy leaders, practitioners, and organizations in 2024
- Key themes to consider in developing and maintaining your privacy program
This presentation provides valuable insights into effective cost-saving techniques on AWS. Learn how to optimize your AWS resources by rightsizing, increasing elasticity, picking the right storage class, and choosing the best pricing model. Additionally, discover essential governance mechanisms to ensure continuous cost efficiency. Whether you are new to AWS or an experienced user, this presentation provides clear and practical tips to help you reduce your cloud costs and get the most out of your budget.
Programming Foundation Models with DSPy - Meetup SlidesZilliz
Prompting language models is hard, while programming language models is easy. In this talk, I will discuss the state-of-the-art framework DSPy for programming foundation models with its powerful optimizers and runtime constraint system.
Fueling AI with Great Data with Airbyte WebinarZilliz
This talk will focus on how to collect data from a variety of sources, leveraging this data for RAG and other GenAI use cases, and finally charting your course to productionalization.
Digital Marketing Trends in 2024 | Guide for Staying AheadWask
https://www.wask.co/ebooks/digital-marketing-trends-in-2024
Feeling lost in the digital marketing whirlwind of 2024? Technology is changing, consumer habits are evolving, and staying ahead of the curve feels like a never-ending pursuit. This e-book is your compass. Dive into actionable insights to handle the complexities of modern marketing. From hyper-personalization to the power of user-generated content, learn how to build long-term relationships with your audience and unlock the secrets to success in the ever-shifting digital landscape.
Building Production Ready Search Pipelines with Spark and MilvusZilliz
Spark is the widely used ETL tool for processing, indexing and ingesting data to serving stack for search. Milvus is the production-ready open-source vector database. In this talk we will show how to use Spark to process unstructured data to extract vector representations, and push the vectors to Milvus vector database for search serving.
Best 20 SEO Techniques To Improve Website Visibility In SERPPixlogix Infotech
Boost your website's visibility with proven SEO techniques! Our latest blog dives into essential strategies to enhance your online presence, increase traffic, and rank higher on search engines. From keyword optimization to quality content creation, learn how to make your site stand out in the crowded digital landscape. Discover actionable tips and expert insights to elevate your SEO game.
In the rapidly evolving landscape of technologies, XML continues to play a vital role in structuring, storing, and transporting data across diverse systems. The recent advancements in artificial intelligence (AI) present new methodologies for enhancing XML development workflows, introducing efficiency, automation, and intelligent capabilities. This presentation will outline the scope and perspective of utilizing AI in XML development. The potential benefits and the possible pitfalls will be highlighted, providing a balanced view of the subject.
We will explore the capabilities of AI in understanding XML markup languages and autonomously creating structured XML content. Additionally, we will examine the capacity of AI to enrich plain text with appropriate XML markup. Practical examples and methodological guidelines will be provided to elucidate how AI can be effectively prompted to interpret and generate accurate XML markup.
Further emphasis will be placed on the role of AI in developing XSLT, or schemas such as XSD and Schematron. We will address the techniques and strategies adopted to create prompts for generating code, explaining code, or refactoring the code, and the results achieved.
The discussion will extend to how AI can be used to transform XML content. In particular, the focus will be on the use of AI XPath extension functions in XSLT, Schematron, Schematron Quick Fixes, or for XML content refactoring.
The presentation aims to deliver a comprehensive overview of AI usage in XML development, providing attendees with the necessary knowledge to make informed decisions. Whether you’re at the early stages of adopting AI or considering integrating it in advanced XML development, this presentation will cover all levels of expertise.
By highlighting the potential advantages and challenges of integrating AI with XML development tools and languages, the presentation seeks to inspire thoughtful conversation around the future of XML development. We’ll not only delve into the technical aspects of AI-powered XML development but also discuss practical implications and possible future directions.
Ivanti’s Patch Tuesday breakdown goes beyond patching your applications and brings you the intelligence and guidance needed to prioritize where to focus your attention first. Catch early analysis on our Ivanti blog, then join industry expert Chris Goettl for the Patch Tuesday Webinar Event. There we’ll do a deep dive into each of the bulletins and give guidance on the risks associated with the newly-identified vulnerabilities.
Ocean lotus Threat actors project by John Sitima 2024 (1).pptxSitimaJohn
Ocean Lotus cyber threat actors represent a sophisticated, persistent, and politically motivated group that poses a significant risk to organizations and individuals in the Southeast Asian region. Their continuous evolution and adaptability underscore the need for robust cybersecurity measures and international cooperation to identify and mitigate the threats posed by such advanced persistent threat groups.
Nordic Marketo Engage User Group_June 13_ 2024.pptx
How to generate a rest application - DevFest Vienna 2016
1. HOW TO GENERATE A REST
APPLICATION
@johannes_fiala - DevFestVienna 2016
2. Agenda
Generate based on contract
Extend using code first
Freeze the contract
Use the REST API
Generate client code (Java/Javascript)
Access with a browser using a UI
View/Share as HTML/PDF
Customize the code generator
6. About me…
Spring REST / Swagger-Springfox
Added BeanValidation support
Swagger-Codegen
Created Javascript client
Add BeanValidation support for Java
Improved CXF server (generate complete server)
Created CXF client
Swagger2Markup
Added BeanValidation support
7. Contract
WADL (XML-based)
By w3c, Last update 2009
Swagger (Json/Yaml-based)
By Linux foundation
Version 1.0 – 2011 (Wordnik)
Version 1.2 - 2014
Version 2.0 – 2015 / transferred to Linux
foundation / Open-API initiative
Next version 3.0
Others: Blueprint, RAML, …
8. Open API / Swagger
A language-agnostic interface to REST APIs
allows to discover and understand the
capabilities of a service
Supported Formats: JSON/YAML
https://github.com/OAI/OpenAPI-Specification
9. Contract editors
Swagger Editor
by SmartBear
Eclipse SwagEdit
By RepreZenAPI Studio
CommercialTools:
Restlet Studio
RepreZenAPI Studio
11. Swagger-Editor
By SmartBear
Javascript application
Run locally using npm
Edit Json /Yaml format
Generate server
Generate client
Import using URL / copy/paste
Save as Json/Yaml
https://github.com/swagger-api/swagger-editor
12. Generate the server stub
Swagger-Codegen
by SmartBear (Apache License)
Version 2.2.0
Java program
Mustache templating
Generates server + client code
40+ Supported languages: Java, C#, Javascript,
Dart, Groovy, JaxRS, NodeJS, Objective-C, Perl,
PHP, Python, Ruby, Scala, …
https://github.com/swagger-api/swagger-codegen
13. Generate the server stub
Swagger-Codegen
Supported server stubs for Java:
Java JAX RS
2.0 spec
Jersey
CXF
Resteasy
Spring MVC
Spring Boot
14. CXF server stub
Features
Scheduled for version 2.2.2
Generates Interface/Implementation/Models
Generate a complete web application
Context.xml / ApplicationContext.xml
Web.xml
Jboss: jboss-web.xml
Spring Boot support
Run as Spring-BootApplication
Run using Spring Integrationtests using random
ports
17. Demo
Create hello world service
Generate CXF server stub (with Spring
support enabled)
Run using Spring Boot
Run Junit-Tests
Deploy to application server (Jboss EAP 7)
26. Freeze your API: contract
Use the updated contract
Generate interfaces/models
Prevent accidential changes of the API
Integrate in build job (Maven / Gradle)
https://github.com/swagger-api/swagger-
codegen/tree/master/modules/swagger-codegen-maven-plugin
28. Demo
Extend hello world service
(+ BeanValidation)
Access updated specs
Swagger spec
WADL
Freeze the contract
29. Use your API
Generate client stubs
Swagger-Codegen
Access your API using a browser
Swagger-UI
Generate HTML/PDF documentation
Swagger2Markup
31. Why generate client code?
No more manual api calls
Ensure consistency of your client code with
the API!
Makes code completion possible!
Allows developers to read description for
your operations and models in the IDE
You get compilation errors if the API breaks
with newer versions!
32. Swagger-UI
By SmartBear
Access your API with a browser
Javascript application
Can access the generated Swagger spec – always
consistent with your code
Integration options:
Copy into your webapp
load asWeb-Jar
https://github.com/swagger-api/swagger-ui
34. Swagger2Markup
By Robert Winkler (github)
Render your API in HTML/PDFs
Uses Markdown/Asciidoctor files
Completely customizable
Integration options:
Run as Program/Unittest
Maven
https://github.com/Swagger2Markup/swagger2markup
37. Customize the generator
Generator implemented in Java (one class for
each language)
Mustache-files
api.mustache
apiServiceImpl.mustache
pojo.mustache
api_test.mustache
…
38. Customize the generator
Use –t flag for your own templates
Customize only the templates you need
Examples:
Add Maven profile for deployment
Add logger declaration
Customize generated unit tests
…
39. Customize the generator
Customize Codegen Languages
Extend Language class
Add it to io.swagger.codegen.CodegenConfig
swagger-codegensrcmainresourcesMETA-
INFservicesio.swagger.codegen.CodegenConfig
Copy language templates
41. WADL?
From WADL to Swagger
Use wadl2java to generate server stub
BeanValidation: krasa-jaxb-tools
Activate CXF3 SwaggerFeature
Use generated Swagger-file
Will include BeanValidation annotations for
models
42. CXF Caveats
Impl: return null = no response in browser
No JaxRS annotations in Impl. Class
No @Consumes/@Produces Json will
fallback to default XML
Jettison on classpath will overrule all other
providers!
43. Wrapup
Generate based on contract
Swagger-Codegen server stubs
Extend using code first
CXF 3 Swagger Feature
Freeze using contract
Swagger-Codegen build integration (mvn/gradle/cmd)
Use your application
Generate client code (Swagger-Codegen)
Use in browser (Swagger-UI)
View/Share as HTML/PDF (Swagger2Markup)
Customize the code generator