In Flux, we have made improvements in recent versions to handle database or network failures and recover from such failures gracefully without needing to restart Flux. Sometimes, it would be nice to notify administrators about these failures and they can act upon them in case of an unscheduled outage. Flux is dependent on the database … Continue reading Handling Flux Database outages using BoneCP Connection Pool
Try-with-resources (originally known as Automatic Resource Management) is one of the Project Coin proposals that made its way into recent JDK 7 builds. Traditionally, developers had to manually terminate any resources (Files, Database connections, etc) they use in their applications and sometimes it was painful to keep track of those things and failing to do … Continue reading Introducing Try With Resources, can project Coin become crown jewel of Java 7?
JAXB is the defacto OXM binding framework for the Java platform which performs marshalling (serializing Java to XML) and unmarshalling (deserializing XML to Java) using the standard Java APIs. I must admit that JAXB is a smart addition to the Java Web services technologies stack. It reminds me of days where I used to write … Continue reading Hate JAXB annotations: MOXy and JAXBIntroductions comes to the rescue
It is quite possible many developers have run into this problem with Jersey, not really a problem, but limitations of a programming language. I remember from school days where C++ Templates had quite a few reference books and it always kept me away from using STL containers 🙂 In Java, we have Generics since 1.5 … Continue reading Handling Generified Collections in Jersey JAX-RS
I recently came across this interesting question on Job Scheduling in Java in the widely popular experts-exchange website. Unfortunately, you require subscription to see "expert" answers, unlike Stack Overflow. Here is my take on this FAQ: 1) Is it possible to use Sun's own java.util.TimerTask for my complex report scheduling? Timer facility has limited capabilities … Continue reading Job Scheduling in Java, why Flux?
JAX-RS runtime allows applications to supply entity providers which maps services between representations (via @Produces and @Consumes) and their Java types. The entity provider interfaces MessageBodyReader and MessageBodyWriter defines the contract that supports the conversion of a stream to a Java type and vice versa. Lets write a simple JAXRS provider for handling a SOAPMessage … Continue reading SOAP over RESTy Client
SSL enabled RESTful services are quite easier to develop and test using Jersey, Grizzly and RestTemplate. Jersey (resource development) Grizzly Web Server (resource configuration and deployment) Spring 3 RestTemplate backed by Commons HTTP Client (resource access) In a moment, you will notice how all these nicely fit the bill. Let us start with the POM … Continue reading Accessing RESTful services configured with SSL using RestTemplate