Online Training Spring Hibernate Training in Delhi R Programming Training Course Big Data and Hadoop Training Java Training

Spring cglib2

The cglib2 framework is used by Spring to manipulate Java classes in run time.


Spring 3.2 MVC insert and retrieve blob from the database The hidden tag The errors tag net.roseindia.dao net.roseindia.service net.roseindia.model net.roseindia.controller Spring 3.2 MVC Hibernate Example Spring 3.2 MVC, Upload File in a specific folder Spring 3.2 MVC Form Handling The textarea tag The options tag The option tag The select tag The radiobuttons tag The radiobutton tag The checkboxes tag mvc:default-servlet-handler Static Resources Configuration View Controllers Configuration View resolvers Spring 3.2 MVC Hello World Example Content Negotiation Configuration Interceptors Configuration using Java or XML Customizing the MVC Java config or XML Namespace MVC Java Config or the MVC XML Namespace Servlet container initialization through code Support for ETag The checkbox tag Autogenerated logical view name through RequestToViewNameTranslator Modification in conventional ModelAndView ControllerClassNameHandlerMapping class for handling convention mapping The password tag The input tag The form tag Form Tag library configuration Customizing the Default Error Page @ExceptionHandler & @ResponseStatus annotation Multipart support for file upload in Spring MVC Themes and Theme resolvers in Spring MVC Locales in Spring MVC ContentNegotiatingViewResolver Redirecting and forwarding to views Chaining of Multiple view resolvers View Resolving through ViewResolver interface Requests Intercepting through a HandlerInterceptor Defining handler methods using @RequestMapping annotation Spring 3.2 Asynchronous Request Processing @RequestMapping annotation for mapping requests @Controller annotation for defining new controller

Spring cglib


In this section we will learn about Spring cglib library and understand the importance of it. You will also find the url to download cglib library

What is cglib?

The cglib is high performance library in Java. It is used to extend Java classes and implement interfaces in runtime. It is one the best quality code generation library available in Java. The latest version of cglib library can be downloaded from

The cglib library is free software and can be used for personal and commercial purposes.

Spring 3 framework uses cglib2 for manipulating the Java classes in runtime. The cglib library is not included in Spring 3.0 distribution. So, you have to manually download and include in your project.

On the cglib home page you will find the link to download.

If you don't include the cglib dependency in your Spring 3 project you might get the following error:

Jan 2, 2010 3:22:07 PM prepareRefresh

INFO: Refreshing org.springframework.context.annotation.AnnotationConfigApplicatio[email protected]:
startup date [Sat Jan 02 15:22:07 IST 2010]; root of context hierarchy

Exception in thread "main" java.lang.IllegalStateException: CGLIB is required to process @Configuration classes.
Either add CGLIB to the classpath or remove the following @Configuration bean definitions: [spring3HelloWorldConfig]

at org.springframework.context.annotation.ConfigurationClassPost

at org.springframework.context.annotation.ConfigurationClass




at org.springframework.context.annotation.Annotation

at net.roseindia.Spring3HelloWorldConfigTest.main(


Share on Google+Share on Google+

Spring cglib2

Posted on: January 2, 2010 If you enjoyed this post then why not add us on Google+? Add us to your Circles



Discuss: Spring cglib2  

Post your Comment

Your Name (*) :
Your Email :
Subject (*):
Your Comment (*):
  Reload Image
Hallah Amine
January 5, 2013
learning spring

No thing