Win a copy of Learn Spring Security (video course) this week in the Spring forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Deployment stuck

 
Pankaj Shet
Ranch Hand
Posts: 293
Java Scala Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi friends,
I am facing this problem since last two weeks.
Please help me to solve this problem.

I am developing a simple database portlet in which I will perform CRUD Operations on database.'

The problem is that

The deployment of portlet hangs, that is when trying to deploy the portlet : the following happens.


11:13:03,194 INFO [AutoDeployDir:167] Processing Birthday-portlet-6.0.5.1.war
11:13:03,272 INFO [PortletAutoDeployListener:71] Copying portlets for D:\pankaj_files\liferay\MustForMums\liferay-portal-6.0.5\deploy\Birthday-portlet-6.0.5.1.war
Expanding: D:\pankaj_files\liferay\MustForMums\liferay-portal-6.0.5\deploy\Birthday-portlet-6.0.5.1.war into D:\pankaj_files\liferay\MustForMums\liferay-portal-6.0.5\tomcat-6.0.26\temp\20111024111303678
Copying 1 file to D:\pankaj_files\liferay\MustForMums\liferay-portal-6.0.5\tomcat-6.0.26\temp\20111024111303678\WEB-INF
Copying 1 file to D:\pankaj_files\liferay\MustForMums\liferay-portal-6.0.5\tomcat-6.0.26\temp\20111024111303678\WEB-INF\classes
Copying 1 file to D:\pankaj_files\liferay\MustForMums\liferay-portal-6.0.5\tomcat-6.0.26\temp\20111024111303678\WEB-INF\classes
Copying 1 file to D:\pankaj_files\liferay\MustForMums\liferay-portal-6.0.5\tomcat-6.0.26\temp\20111024111303678\META-INF
Warning: WEB-INF\classes\META-INF\base-spring.xml modified in the future.
Warning: WEB-INF\classes\META-INF\cluster-spring.xml modified in the future.
Warning: WEB-INF\classes\META-INF\dynamic-data-source-spring.xml modified in the future.
Warning: WEB-INF\classes\META-INF\hibernate-spring.xml modified in the future.
Warning: WEB-INF\classes\META-INF\infrastructure-spring.xml modified in the future.
Warning: WEB-INF\classes\META-INF\portlet-hbm.xml modified in the future.
Warning: WEB-INF\classes\META-INF\portlet-model-hints.xml modified in the future.
Warning: WEB-INF\classes\META-INF\portlet-orm.xml modified in the future.
Warning: WEB-INF\classes\META-INF\portlet-spring.xml modified in the future.
Warning: WEB-INF\classes\META-INF\shard-data-source-spring.xml modified in the future.
Warning: WEB-INF\classes\com\people\bregistration\model\impl\BirthdayImpl.class modified in the future.
Warning: WEB-INF\classes\com\people\bregistration\model\impl\BirthdayModelImpl.class modified in the future.
Warning: WEB-INF\classes\com\people\bregistration\service\base\BirthdayLocalServiceBaseImpl.class modified in the future.
Warning: WEB-INF\classes\com\people\bregistration\service\impl\BirthdayLocalServiceImpl.class modified in the future.
Warning: WEB-INF\classes\com\people\bregistration\service\persistence\BirthdayPersistenceImpl.class modified in the future.
Warning: WEB-INF\classes\com\people\controller\portlet\ActionUtil.class modified in the future.
Warning: WEB-INF\classes\com\people\controller\portlet\Birthday.class modified in the future.
Warning: WEB-INF\classes\content\Language.properties modified in the future.
Warning: WEB-INF\classes\service.properties modified in the future.
Warning: WEB-INF\lib\Birthday-portlet-service.jar modified in the future.
Warning: WEB-INF\liferay-plugin-package.properties modified in the future.
Warning: WEB-INF\sql\tables.sql modified in the future.
Warning: WEB-INF\src\com\people\controller\portlet\Birthday.java modified in the future.
Warning: WEB-INF\src\service.properties modified in the future.
Warning: WEB-INF\classes\com modified in the future.
Warning: WEB-INF\classes\com\people modified in the future.
Warning: WEB-INF\classes\com\people\bregistration modified in the future.
Warning: WEB-INF\classes\com\people\bregistration\model modified in the future.
Warning: WEB-INF\classes\com\people\bregistration\service\base modified in the future.
Warning: WEB-INF\classes\com\people\bregistration\service\impl modified in the future.
Warning: WEB-INF\classes\com\people\bregistration\service\persistence modified in the future.
Warning: WEB-INF\classes\com\people\controller modified in the future.
Copying 29 files to D:\pankaj_files\liferay\MustForMums\liferay-portal-6.0.5\tomcat-6.0.26\webapps\Birthday-portlet
Copying 1 file to D:\pankaj_files\liferay\MustForMums\liferay-portal-6.0.5\tomcat-6.0.26\webapps\Birthday-portlet
Deleting directory D:\pankaj_files\liferay\MustForMums\liferay-portal-6.0.5\tomcat-6.0.26\temp\20111024111303678
11:13:07,549 INFO [PortletAutoDeployListener:81] Portlets for D:\pankaj_files\liferay\MustForMums\liferay-portal-6.0.5\deploy\Birthday-portlet-6.0.5.1.war copied successfully. Deployment will start in a few seconds.
Oct 24, 2011 11:13:14 AM org.apache.catalina.startup.HostConfig checkResources
INFO: Reloading context [/Birthday-portlet]

and then nothing happens.


the portal is Liferay 6.0.5.


Thanks and Regards,
Pankaj Shet.
 
Shantanu Puranik
Ranch Hand
Posts: 67
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
During portlet development, hot deployment fails many times, on my machine too.
I simply delete the context folder (should be 'Birthday-portlet-6.0.5.1' or similar in your case) under webapps dir. and then redeploy. This works normally.
If getting error, stop tomcat and then delete the context folder.
Then, Copy war to deploy dir. and start tomcat OR first, start tomcat and then do hot deployment.
Hope this helps.
 
Pankaj Shet
Ranch Hand
Posts: 293
Java Scala Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Shantanu,

I too tried that several times, but still it did not work for me. Is there any reason for this to happen? I want to understand why does this happen. If we are able to find the reason behind this, we would probably be able to find out the solution for this.

I tried deleting entire portal folder and restting the same again freshly several times but not able to get any idea for the same.

It had happened many times before when working with normal web-application too but your solution was working in case of web-application.
I want to find the reason behind this.
I shall really appreciate if reason is found.

Thanks and Regards,
-Pankaj
 
Roland Thomas Lichti
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Pankaj,

Pankaj Shet wrote:
I want to find the reason behind this.
I shall really appreciate if reason is found.


since I'm having the same problem (one portlet installs without hassle, the other one is driving me mad): did you find a solution to the problem?

My logs look like that:


And then nothing more. If I give a servlet listener in web.xml that gets executed (I checked it via logging output).

Since the working portlet was the skeleton for the not-working one I'm really puzzled.

bye,
Roland
 
Amro Ali
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Make sure that there are no xml files in the deploy directory, and clear the deploy directory completely

delete the portlet folder from the web apps
delete the portlet registration from the table "portlet" and any reference in the "servicecomponent" table , and drop any tables related to your portlet
restart the server and wait for it to be fully started
run the build-service ant followed by the ant compile and war
deploy the war

if it still gives you problems, I suspect that there is something corrupted in one of you portlet files, I suggest recreating the project and copying code and redeploying.
 
Guy deLyonesse
Ranch Hand
Posts: 200
Eclipse IDE Java Ubuntu
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Try this.
 
Amro Ali
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Guy, didn't know someone has already written the steps i posted in a blog. always useful to have a link
 
Guy deLyonesse
Ranch Hand
Posts: 200
Eclipse IDE Java Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Actually your list is more thorough in going through and actually deleting data from the database. The steps in the blog resulted from times when re-deploying a portlet doesn't necessarily replace all of the files or, in the case that led to me writing that blog entry, I had removed some of the .jar files I was bundling into the portlet .war file but the old ones remained after a fresh hot deploy. That resulted in conflicts with the classes in the .jars.

That's why it's always better to completely remove a plugin before re-installing it.
 
Amro Ali
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Guy-

Thanks for the compliment- Your list is good and covers the main issue that usually occurs with deployment ( an incomplete deploy leaving an xml or war in the deploy directory).
I delete from the database just to make sure that a new deployment is valid and no problems would occur.


 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic