Skip to content

RWS/embedded-rest-server

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

27 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Build Status Maven  Central

Embedded RESTful Server

This modules provides a minimal service provider interface (SPI) using ServiceLoader to launch an instance of embedded Jetty with potentially a number of Jersey JAX-RS applications and generic Jetty context handlers.

Service Interfaces

You can provide as many as implementations of the following interfaces in the class path to be loaded via Java ServiceLoader:

Provided Implementations

By default, the following implementations are activated provided with the conditions:

  • A context handler to serve at /docs if the environment values either contain existing ${application.name}.root/docs or ${application.name}.docs.root.

Usage

The module provides a standard Java main class that can be used as:

$ java OPTIONS com.fredhopper.server.Bootstrap

or alternatively, if embedded-rest-server.jar is used:

$ java -jar embedded-rest-server.jar

or alternatively, use EmbeddedServer API in your code.

Note that the Maven dependencies such as e.g. Jetty and Jersey, must be explicitly be declared in your POM files. This module only exposes them in provided scope to allow downstream dependencies to use their own versions.

Contributing

Please refer to here.

License

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

   http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

Complete License

About

Bootstrap for an embedded RESTful server with Jetty and Jersey

Resources

License

Stars

Watchers

Forks

Packages

No packages published