Amazon S3 sync script

aws s3 sync

Here is a step by step guide on how to backup your data to amazon S3. At end of this tutorial you will be able to create a bash script to sync your data to amazon S3. Create a S3 bucket Log in to your AWS account and go to S3. Create a new bucket […]


H2 database example using hibernate and Spring Boot

h2 database

Here is a H2 database example using Hibernate and Spring Boot. This example shows you how to create, read, update and delete a record in H2 database.


Spring task scheduler (cron job) example


Spring framework has built in support for scheduled tasks. Here are some examples of spring cron jobs using both annotations and xml configurations.


How to send an email in a bash script

bash email

You can send an email in a bash script using mutt command. Here is how you can send an email with an attachment to multiple recipients using a linux shell script.


Hibernate4 + spring4 + maven example

hibernate example directory structure

Here is an example using hibernate4, spring4 and maven. Learn how to do simple create, read, update and delete operations using hibernate.


log4j2 xml configuration example

log4j2 example

Here are some sample log4j2 xml configurations. This includes full source code created with maven.


Run multiple mysql servers on single machine


Here is how to run multiple mysql instances on the same machine. This will be helpful when you need to run different mysql version on same computer or have separate mysql servers for each system. Here I assume you have already installed one instance of mysql. Following steps are for installing another instance of mysql […]


How to replace a text using bash sed command

bash find and replace

Here is how you can replace a text in a file using bash script. You can use the sed command as below to replace the text.


SQL joins diagram

sql joins diagram

Here is a diagram of sql joins for better understanding how they work. This visual representation contains following joins, Inner Join, Left Join, Right Join, Outer Join, Left Join excluding Inner Join, Right Join excluding Inner Join, Outer Join excluding Inner Join.


How to create a local maven dependency

maven diagram

There are situations where you want to add your own .jar library as maven dependency. Also there are third party libraries which are not available in the central maven repository. In a situation like that you can add that .jar file in your local repository and use as a maven dependency. Here is how to […]



Subscribe to our email feed and never miss a post

Join Us