Skip to content

flaviodonze/emf-rest-server-client

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

45 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Sample EMF REST server-client application

A sample server client application which sends and receives EMF (Eclipse Modeling Framework) objects using JAX-RS. The server is a Spring Boot application which publishes Apache CXF remote services. The client demonstrates a very simple application which communicates with the server using Rest Client for MicroProfile.

The EMF objects are serialized to JSON using https://github.com/flaviodonze/emfjson-jackson.

Example

Example of building a service proxy and receiving a simple EMF object "Code".

URI apiUri = new URI("http://localhost:8080/services/");
RestClientBuilder client = RestClientBuilder.newBuilder().register(CommunicationUtil.getProvider()).baseUri(apiUri);
NotificationDefinitionService service = client.build(NotificationDefinitionService.class);
Code code = service.getCode();

Running

Server Launch: rest-server/src/main/java/com/softmodeler/server/ServerApplication.java

Client Launch: rest-client/src/main/java/com/softmodeler/client/ClientApplication.java

About

Sample EMF REST server-client application

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages