Since JAX-RS 1 and moreover with JAX-RS 2 developpers create JAX-RS providers.
The most common ones are to (de)serialize the request/response payloads but you can do much more now like switching the input stream, updating the output stream, filtering the request/response etc…
Going further in this API you’ll realize you can filter input/output on server side and client side (for instance you can write a ClientRequestFilter and a ContainerRequestFilter). Generally client and server API are close but adapted to the “side” where the provider is working.
However can we ensure we didn’t mess things configuring a client provider on a server?
Until 1.x releases to configure the server.xml related to tomee maven plugin (embedded or not) you needed to configure either its direct location through “serverXml” parameter or a “conf” folder containing a server.xml. This is working fine but it was often forcing you to create a folder containing the server.xml only.
Note: if you are not used to tomee maven plugins, you can configure almost all the container through properties in the pom.
To avoid it both plugins now got a new variable to let you provide your server.xml inline!
JBatch is a nice API proposing some auto-monitoring. As all operations, the entry point is the JobOperator and from an executionId you can get several information like status, metrics, start/end time etc about the job and its steps.
But is it possible to auto monitor a batch?
When writing a WebSocket endpoint the first thing you do is to create the endpoint (connection point) then you have to define the protocol to use. Because of what is modern IT world it is quite common to use JSon as payload format for WebSocket messages. Of course you can use any JSon mapper you want or JSON-P directly but you can actually go a bit further and that is what does Johnzon in its coming 0.8-incubating release.
Speaking on the CDI list about CDI 2.0 standalone container API Jozef Hartinger sent an answer which is quite obvious when you know it but which can change your life if you don’t: how CDI 1.1 introduced @Startup without the need of EJBs.
Recently on OpenWebBeans mailing list a nice discussion was started by Karl Kildén about its usage of CDI Instance.
This API is nice and useful but it is not as trivial as it can look. Let’s dig a bit into it.
On friday I did with Jean-Louis Monteiro the Lorraine JUG. I presented Apache JCS which is a nice Java Caching solution implementing now JCache specification.
Slides are available here: http://rmannibucau.github.io/2015/LorraineJUG/#/.
And few code samples/examples can be found here (this is a maven project you can open in your IDE): https://github.com/rmannibucau/rmannibucau.github.com/tree/master/2015/LorraineJUG/demo.
Don’t hesitate to get in touch the Apache JCS community if you want more information (use Apache Commons mailing list – firstname.lastname@example.org – and just specify [JCS] in the subject), we’ll be very happy to help you!