Drools Spring Integration 1. Introduction In this quick tutorial, we’re going to integrate Drools with Spring. If you’re just getting started with Drools, check out this intro article. 2. Maven Dependencies Let’s start by adding the following dependencies to our pom.xml file: <dependency> <groupId>org.drools</groupId> <artifactId>drools-core</artifactId> <version>7.0.0.Final</version> </dependency> <dependency> <groupId>org.kie</groupId> <artifactId>kie-spring</artifactId>… Continue Reading drools-spring-integration

Spring Properties File Outside jar 1. Overview Property files are a common method that we can use to store project-specific information. Ideally, we should keep it external to the packaging to be able to make changes to the configuration as and when required. In this quick tutorial, we’ll look into… Continue Reading spring-properties-file-outside-jar

Jackson JSON Views 1. Overview In this tutorial, we’ll go over how to use Jackson JSON Views to serialize/deserialize objects, customize the views and finally – how to start integrating with Spring. 2. Serialize Using JSON Views First – let’s go through a simple example – serialize an object with… Continue Reading jackson-json-view-annotation

A Quick Example of Spring Websockets’ @SendToUser Annotation 1. Overview In this quick tutorial, we’re going to illustrate how to send a message to a specific session or particular user using Spring WebSockets. For an introduction to the above module, please refer to this article. 2. WebSocket Configuration First of… Continue Reading spring-websockets-sendtouser

BeanNameAware and BeanFactoryAware Interfaces in Spring Spring 1. Overview In this quick tutorial, we’re going to focus on the BeanNameAware and BeanFactoryAware interfaces, in the Spring Framework. We’ll describe each interface separately with the pros and cons of their usage. 2. Aware Interface Both BeanNameAware and BeanFactoryAware belong to the org.springframework.beans.factory.Aware root marker interface. This uses setter injection… Continue Reading spring-bean-name-factory-aware