This maven2 archetype contains a little sample web application with this Frameworks:
- Spring 3.0.0.RELEASE Framework
- Servlet-API 2.5
- JSF 2.0 (mojarra 2.0.2)
- IceFaces 2.0
- ploinFaces 1.6
- ploinMailFactory 1.3.1
- Hibernate 3.3.2.GA
- TestNG 5.8
- Log4J 1.2.15
- HSQLDB 1.8.0.7
The configuration is xml-driven. It is deployed on the PLOIN Repository-Serve
http://www.ploin-m2.de/nexus/content/groups/public/
you can create a project from the archetype with the following command:
mvn archetype:generate -DarchetypeGroupId=org.ploin.archetype -DarchetypeArtifactId=tempSpringIceHibernate -DarchetypeVersion=1.4 -DarchetypeRepository=http://www.ploin-m2.de/nexus/content/groups/public/ -DgroupId=org.ploin -DartifactId=demoSpringIceHibernate
The created project is a very simple web-application with a login mask and three xhtml-sites. I have tested the app on a tomcat 6.0.20 and Java 1.6 on Mac OS X Snow Leopard.
You can login with the username “admin” and the password “admin”.
After the creation the app is running with the HypersoniceSQL DBMS. But it is very easy to switch to MySQL or Oracle. I put the drivers for MySQL and Oracle as a comment in the pom.xml. So you just need to comment int the right lines in the pom.xml.
2011-06-18 20:56:07,461 ERROR org.springframework.web.context.ContextLoader.initWebApplicationContext:220 – Context initialization failed
org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘org.springframework.dao.annotation.PersistenceExceptionTranslationPostProcessor#0’ defined in class path resource [applicationContext.xml]: Initialization of bean failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘sessionFactory’ defined in class path resource [applicationContext.xml]: Invocation of init method failed; nested exception is java.lang.IncompatibleClassChangeError: Implementing class
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:527)
20:56:03 java.util.jar.Attributes read
ADVERTENCIA: Duplicate name in Manifest: Class-Path.
Ensure that the manifest does not have duplicate entries, and
that blank lines separate individual sections in both your
manifest and in the META-INF/MANIFEST.MF entry in the jar file.
0 [main] INFO util.PropertyMessageResources – Initializing, config=’org.apache.struts.util.LocalStrings’, returnNull=true
2 [main] INFO util.PropertyMessageResources – Initializing, config=’org.apache.struts.action.ActionResources’, returnNull=true
169 [main] INFO util.PropertyMessageResources – Initializing, config=’resources.application’, returnNull=true
198 [main] INFO cfg.Environment – Hibernate 2.0.3
I assume you got this Exception by starting the App.
Usually this kind of Exceptions occurs if your Eclipse-Tomcat configuration is broken.
I assume you tried to run the project with Eclipse & Tomcat. Could you please make the war file with maven in the command line, without eclipse. And than copy the war into a new tomcat instance. If this is running, than it is a eclipse configuration problem on your machine.
Hi Sir, can I download sample of this web app. or send us a link for the tutorial for the integration of these frameworks. thank you sir. =)
Well. this is a Maven2 Archetype. You just have to install Maven2 or Maven3 and execute the command above. That will download the application with the source code.
Hi, I download the project but I have problems because i didn’t get utils package org.ploin.utils.service.ISecureService. Can you help me I use Apache Maven 3.0.3 (r1075438; 2011-02-28 11:31:09-0600) and execute
mvn archetype:generate -DarchetypeGroupId=org.ploin.archetype -DarchetypeArtifactId=tempSpringIceHibernate -DarchetypeVersion=1.4 -DarchetypeRepository=http://www.ploin-m2.de/nexus/content/groups/public/ -DgroupId=org.ploin -DartifactId=demoSpringIceHibernate
Again me I changed a little bit the pom.xm file (2 lines) and the last problem it seems to disappeared:
org.ploin.web
ploinFaces
2.2.1 !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!change
compile
com.ibm.icu
icu4j
javax.servlet
servlet-api
javax.el
el-api
org.ploin.utils
ploinUtils
1.6.9!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!change
compile
But now when I deploy my war i get this error: ice faces 2.0.ALPHA
lib/icefaces-comps-compat-2.0.ALPHA.jar!/] para ficheros TLD
java.util.zip.ZipException: error in opening zip file
at java.util.zip.ZipFile.open(Native Method)
Do you know what other ice-faces version works with this example?. Thanks a lot!
I only tested it with IceFaces 2.0. And it worked for me.
But it seems that you have some alpha verison in your mvn repo.