How To Set Tomcat JVM Heap Size in Eclipse?

eclipse1

If JVM head size for Tomcat is not enough, you would get the error java.lang.OutOfMemoryError. If you are using eclipse, it is easy to increase the available heap size by using the server configurations. Look at the below steps to configure the VM arguments passed to JVM for running the tomcat server. 1. Open Server […]

How To Resolve “Resource Is Out Of Sync With The Filesystem” Error in Eclipse?

eclipse1

The error in eclipse IDE Resource Is Out Of Sync With The File system happens many time when the resource is out of sync and may be updated by some other sources. We need refresh each time by default to load that files. There is settings in eclipse to permanently fix this problem. Look at […]

Update Eclipse Project Facets Using Settings File

eclipse1

In some cases you will not be able to change the eclipse project facets through dialog boxes. It would happen many times when you want to downgrade your versions of facets used by your eclipse project. For example, If your current project configuration is Dynamic Web Module 3.0, if you try to downgrade to 2.5, […]

FreeMarker Template + Servlet Integration Example

freemarker-thumbnail

This is my second tutorial about FreeMarker template engine. In my previous tutorial I have explained about how to create stand alone freemarker template. This tutorial explains how to integrate freemarker template to a servlet. 1. Setup FreeMarker Environemnt It is very simple to setup the freemarker environment by downloading the JAR distribution from its […]

How To Write Custom Tag in JSP?

java-jee

1. Introduction to JSP Custom Tag A custom tag is a user define JSP element. It is very useful in JSP programming for the programmers to write their own custom components for their projects. These custom tags can be re-used in many places without modification of code. In the latest trend of web development, very […]

FreeMarker Template Hello World Example

freemarker-thumbnail

1. Introduction to FreeMarker FreeMarker is a Java based template engine which can be used as stand-alone or servlet bases Java programs. You write a FreeMarker template in a plain text file with the place holders like ${id}. This file is saved with .ftl extension. Not only the simple text, we can also use the […]

How To Use Switch Statement (th:switch) In Thymeleaf Template?

thymeleaf

In my previous articles I have explained about the hello world example and the expression language. This tutorial explains how to use the switch statements inside Thymeleaf template. Thymeleaf provides th:switch attribute for using switch functionality. This feature is extension of my previous example on iteration in thymeleaf template. 1. Set Up Thymeleaf Application To […]

How To Use th:each For Iteration In Thymeleaf Template?

thymeleaf

In my previous articles I have explained about the hello world example and the expression language. This tutorial explains how to iterate the list of values from an object. For Iteration In Thymeleaf Template, it┬áprovides th:each attribue for using inside a table element to iterate over the list of objects and display the list. This […]

How To Set Attributes in Thymeleaf Template using th:attr?

thymeleaf

In my previous articles I have explained about the hello world example and the expression language. This tutorial explains how to set the attribute to the template at the time of processing. This feature is very useful for creating the templates. Thymeleaf provides very easy syntax for just adding the attributes dynamically from the properties […]

Get URL Content using Java

java

This example shows how to download a URL content to your local machine. If you look at the below example, it simply takes an URL as the input and get the content and save it to the local system. File Upload and Download Using Java