REST Webservice Basic Authentication

Table of Contents Introduction HTTP Methods Prerequisites Project Setup Deployment Descriptor REST Resource Test Class Testing Basic Authentication in REST Service Source Code Introduction In this tutorial I am going to show you how you can authenticate the REST webservice using sending credential information in Cookie. The most important concept in REST is resources, which are identified by global IDs…

Spring @PostConstruct and @PreDestroy Example

In this tutorial I will show you how we can use @PostConstruct and @PreDestroy annotation in Spring framework. @PostConstruct and @PreDestroy annotations are generally considered best practices for receiving life cycle callbacks in a modern Spring application. Using these annotations means that our beans are not coupled to Spring specific interfaces. Sometimes we need to load some data or perform…

Select Single and Multiple Records using Spring JdbcTemplate

Record Selection Using Spring JdbcTemplate This tutorial will show you how you can select or fetch data from a database using Spring JdbcTemplate. I am going to use Spring Boot framework to select single record, multiple records and only single field or column value from the database. simplifies the use of JDBC and helps to avoid common errors. It executes…

Single and Multiple Records Insert using Spring JdbcTemplate

Records Insertion Using Spring Jdbc Template This tutorial will show you how you can insert an object or multiple objects into a database using Spring JdbcTemplate. So you are going to see how to insert single record and multiple records into database table. I am going to use PreparedStatement and BatchPreparedStatementSetter for inserting multiple records. Sometimes you need to insert…

How to create Executable jar using Maven

Introduction Here I am going to show you how to create executable jar using maven build tool. Sometimes you need to create executable jar file from a standalone application using maven because you want to put the executable jar file anywhere and just want to run the file to do some operations from command line.

Codeigniter, AJAX Voting/Rating System

Introduction In this post we will see how to create voting or rating system using Codeigniter, MySQL and AJAX. We post tutorials, articles or blogs either to our own blog site or as a user to other sites. Sometimes we need to let user rate on our tutorials or articles or blogs so that we know how much that blog…

Remove Values From A Row Or Remove A Row From Excel File Using Apache POI In Java

Introduction In this tutorial I am going to show you how to remove value from a row or remove a row completely from the excel file using apache poi library. The Apache POI is used with Java APIs for manipulating various file formats based upon the Office Open XML standards (OOXML) and Microsoft’s OLE 2 Compound Document format (OLE2). You…

Font in excel file using Apache POI in Java

I am going to show you here how to work with font in excel file. With this example I will show you how to create different fonts for text and put it in an excel file using Apache POI in Java language. The Apache POI is to create and maintain Java APIs for manipulating various file formats based upon the…

Border and Color in excel file using Apache POI in Java

Introduction In this example I will show you how to create border around a cell and put color on a particular cell like background color, foreground color using Apache POI in Java language. The Apache POI is to create and maintain Java APIs for manipulating various file formats based upon the Office Open XML standards (OOXML) and Microsoft’s OLE 2…

Text Alignment In Excel File Using Apache POI In Java

I this example I will show you how to align text in an excel file using Apache POI in Java language. The text can be aligned left, right, center, justify using apache poi library. The Apache POI is to create and maintain Java APIs for manipulating various file formats based upon the Office Open XML standards (OOXML) and Microsoft’s OLE…