This project has retired. For details please refer to its Attic page.
Restlet Support
Polygene™
Introduction
Tutorials
Javadoc
Samples
Core
Libraries
Extensions
Tools
Glossary 

Restlet Support

code

docs

tests

The Restlet Support Library has support to expose CRUD operations directly as well as regular Rest resources.

Table 37. Artifact

Group IDArtifact IDVersion

org.apache.polygene.libraries

org.apache.polygene.library.restlet

3.0.0


This library leverages restlet.org which has a very neat way to map resources to URIs, and flexible ways to be served the requests. This library defines all the plumbing needed to set up Restlet, map resources to URIs, convert Polygene ValueComposites to resource representations (such as JSON) and create a fully HATEOAS environment, with single bookmarkable URI.

To set up the Restlet Connectivity Module, it is recommended to use the provided Assembler for it;

Resource Binding

REST defines that all URLs are resources and that a known, small set of operations can be done on those resources.

CRUD Repository

This library provides a CrudRepository which simplifies accessing entities directly from the Rest module. This is implemented by using the Resource Binding above.

It also requires that one or more Crud Modules are defined. These are typically either in the domain layer directly, or in the layer above (some call that the service layer). There is a RestletCrudModuleAssembler that helps set up such module. Typical setup is like this;