Hibernate Object States – Transient, Persistent and Detached

In this tutorial I will discuss what are the states of objects (transient persistent and detached objects) in Hibernate framework. You might be knowing that Hibernate is an ORM (Object Relational Mapping), which is an automated persistent of objects in a Java application to the tables in a relational database. Hibernate defines and supports three different object states: transient, persistent and detached.

Continue

Spring Security Remember Me – Persistent Token Approach

This tutorial will show you how to remember your credentials for a specific time period for auto-login without providing any login credentials into the login form. Remember-me or persistent-login authentication refers to web sites being able to remember the identity of a principal between sessions. This is typically accomplished by sending a cookie to the browser, with the cookie being detected during future sessions and causing automated login to take place. Spring Security provides the necessary hooks for these operations to take place, and has two concrete remember-me implementations. One…

Continue