OSGI logo

OSGi: the gateway into micro-services architecture

The terms “modularity” and “microservices architecture” pop up quite often these days in context of building scalable, reliable distributed systems. Java platform itself is known to be weak with regards to modularity (Java 9 is going to address that by delivering project Jigsaw), giving a chance to frameworks like OSGi and JBoss Modules to emerge.

When I first heard about OSGi back in 2007, I was truly excited about all those advantages Java applications might benefit of by being built on top of it. But very quickly the frustration took place instead of excitement: no tooling support, very limited set of compatible libraries and frameworks, quite unstable and hard to troubleshoot runtime. Clearly, it was not ready to be used by average Java developer and as such, I had to put it on the shelf. With years, OSGi has matured a lot and gained a widespread community support. Continue reading

The anatomy of connection pooling

Introduction

All projects I’ve been working on have used database connection pooling and that’s for very good reasons. Sometimes we might forget why we are employing one design pattern or a particular technology, so it’s worth stepping back and reason on it. Every technology or technological decision has both upsides and downsides, and if you can’t see any drawback you need to wonder what you are missing. Continue reading

AngularJS

AngularJS Tutorial: Getting Started with AngularJS

AngularJS is a popular JavaScript framework for building Single Page Applications (SPAs). AngularJS provides the following features which makes developing web apps easy:

  1. Two way data binding
  2. Dependency Injection
  3. Custom HTML Directives
  4. Easy integration with REST webservices using $http, $resource, Restangular etc
  5. Support for Testing and many more…

Continue reading

Easy Batch - logo

First batch job on Podcastpedia.org with EasyBatch

Remember the first batch job for Podcastpedia.org, presented in Spring Batch Tutorial with Spring Boot and Java Configuration… There, I would read submitted podcasts from a .csv file to add them to the Podcastpedia.org directory (database). Well today I will present how I automated the creation of this kind of input file, with the help of Easy Batch. Why EasyBatch? Because, after seeing my initial post, I was contacted by its founder, Mahmoud Ben Hassine, to have a look at Easy Batch and give it a try. I did, and I am happy about that. Read on to find out why… Continue reading

Find the bug

jQuery ui autocomplete not working in Spring 4.1

You may recall from my post Autocomplete search box with jQuery and Spring MVC, that I use jQuery ui autocomplete to dynamically search for keywords on Podcastpedia.org. I am now in the process of migrating the source base for Podcastpedia.org to Spring 4. I decided to go with the latest version 4.1.0.RELEASE and everything worked pretty smoothly until I got to test the auto-complete functionality presented in the post mentioned before. Continue reading

Java EE compatible

How to build and clear a reference data cache with singleton EJBs and MBeans

In one of my projects I had a requirement to load reference data from several sources in a Java EE 6 WebLogic environment, with EclipseLink as ORM framework. Since I couldn’t find an annotation in the Java EE world comparable to the sweet @Cacheable from Spring YET, I had to write my “own” caching solution. Although reference data barely changes over time, one extra requirement was to be able to clear the cache from exterior. So here it goes… Continue reading