How to deploy BIRT report on Tomcat? - tomcat7

I have tomcat 7.0.40 and have installed birt-runtime-4_3_0 by copying the WebViewerExample folder in the webapps folder of Tomcat. I have renamed the WebViewerExample as birt.
I have copied the Report.rptdesign in the root folder birt and copied the java eventhandler jars in the scriptlib folder of birt. I also have copied the sqljdbc4.jar in birt/WEB-INF/lib.
When I try to run the report on the local tomcat server with the url:
http://localhost:8080/birt/frameset?__report=Report.rptdesign
all I get is the 'processing, please wait' progress bar running infinitely and do not get to see the report.
What mistake am I making? Please help.
P.S. The report is working perfectly in Eclipse environment.

This may happen because of 'out of memory error'
Try to edit catalina.bat file under your Tomcat \bin
set CATALINA_OPTS=-Xms512 -Xms512m -XX:MaxPermSize=256
Hope it will help

Download org.apache.commons.logging-1.1.1.jar file from apache website
and paste the jar file to C:\xampp\tomcat\webapps\BIRT\WEB-INF\lib folder
and Working Fine For Me

Related

Running Spring application outside of an IDE (preferably OS shell)

https://www.pegaxchange.com/2018/01/24/java-web-project-with-spring-framework/ has instructions for creating a Java Web Project with Spring, without Maven. I am able to get it working in an Eclipse environment. It works as expected by doing “Run As” --> “Run on Server”.
When I kill Eclipse I get the Status 404 error (“The origin server did not find a current representation for the target resource or is not willing to disclose that one exists.”). I have verified that the Tomcat Server is running from the XAMPP Control Panel.
How do I launch the application from an OS shell (Windows & Linux) so that I don't see the 404 error?
Its been a long time I haven't used java web projects without maven but if my memory serves me right, you should first export your project as .war file. Then deploy it to tomcat.
In eclipse right click your project select export and then select WAR file.
Copy your WAR file into webapps directory which is located in tomcat installation directory.
Rename the WAR file as you like if you want to serve you web app with a specific context name something like http://localhost:8080/myapp. If you do want to serve as root without a context name just rename it as "ROOT".
Run tomcat by command line <your-tomcat-installation-dir>\bin\startup.sh or it will be a .bat file for windows so you should end your command with .bat.
Or if you can start and stop by XAMPP panel this should do the same as well.
Also you can see this article for details on how to deploy a war file to tomcat.
I hope this helps. Cheers!

Manual Vaadin Project Deploy on Raspbian

For a project I want to do a performance comparison of different web-frameworks on a raspberry pi. Thats why I want to do only a manual deploy to mess around with it a bit.
I created a Vaadin project using maven and exported it as application.war file. I downloaded the tomcat-7 server and unzipped it. After that I gave the .sh files in the folder executable permission. Then I copied .war file in the webapps folder of tomcat. Finally I started tomcat by running sh startup.sh.
But when I try to open the page on my dev machine under ip:8080/application I only receive a timeout.
Did I miss something?

java.io.FileNotFoundException: Source 'D:\JBoss\EAP-7.0.0\bin\content\eArsiv.war\WEB-INF\lib\lept4j-1.2.3.jar\win32-x86-64' does not exist

I was developing an application with Spring Boot and using tess4j for OCR process.
It was jar packaging and working well.
I just changed packaging to war and deployed to jBoss EAP7.Now i am getting "Source 'D:\JBoss\EAP-7.0.0\bin\content\eArsiv.war\WEB-INF\lib\lept4j-1.2.3.jar\win32-x86-64' does not exist" error and TessAPI cant be initialized.
Normally there is no folder as content under bin folder but anyway i have created subfolders under bin folder but still no chance.
How can i handle this case?
Many thanks in advance!
Cheers,
Murat

jboss-as-maven-plugin: which directory does command "jboss-as:deploy" deploy an .ear to?

I am running jboss 7.1, maven 3, and a java ee6 application that generates an .ear
I am doing a mvn clean package jboss:as-deployand Jboss-as-maven-plugin 1.5 does its thing--I can view my app using http://localhost:8080...
just fine, but I want to know where the actual .ear is being put.
It is not in my jboss7.../standalone/deployments folder. So where is it? My app is obviously running in jboss 7.1 just fine, but I can't find the .ear file. I know that there is an .ear in Eclipse's 'target' directory, but that wasn't produced by jboss-as-maven-plugin is it? I hope you can understand my confusion--don't all .ear files need to be in the deployments directory? I also do see my .ear file inside my hidden .m2/repository directory, but does this have any interaction with jboss-as-maven-plugin? Maybe there is some hidden sym-linking between my Eclipse project's 'target' directory and the jboss7.1 standalone/deployment directory?
p.s. I am used to using a hard-deploy option with the other plugin jboss-maven that requires you to say jboss:hard-deploy which just copies the .ear to your deployments folder. Then jboss would pick up the new .ear and redeploy automatically. I get the sense that jboss-as-maven-plugin is the preferred plugin so that's why I am bothering.
The jboss-as-maven-plugin uses the deployment API so it doesn't copy the file to the deployments directory for the scanner to pick it up. It deploys just as if you deployed it from the web console or via CLI. The files should be located somewhere in the $JBOSS_HOME/standalone/data/ directory.
You're welcome to open an issue, for a discussion around it at least. I'm not sure how I feel about adding a goal for it, but here isn't the place to discuss that :)

TOMCAT 7 not deploying war

I have developed a Dynamic Java Project with Eclipse which involves web services(RESTful). After completion I tried to run my project Tomcat 7 runtime of Eclipse IDE, it works fine. I am able to access all my web services.
But, when I created a WAR file out of my project by right-clicking on project and exporting it to WAR file and placed .war file in Tomcat 7's webapps folder. Started the tomcat by running startup.bat, it throws below exceptions and I am not able t access any web service:
I have placed all the required jar files in lib folder of Tomcat.
Exception fixing docBase for context [/Books] (Books is my war file name)
Failed to create work directory [{CATALINA_HOME}\work\Catalina\localhost\Books]
Failed to create destination directory to copy resources.
Could anyone please let me know what I am missing??
Thanks in advance.
Regards,
Piyush
The failed to create "work directory" error can occur if the work folder does not exist in the tomcat7 folder.
Also this error can be caused by tomcat not having sufficient permissions to read, write and execute in the tomcat7 directory.
The issue is because, tomcat is not finding your web.xml location in the classpath.
Do below steps:
Right click on web project-->Properties-->Deployment Assembly--> Add your classpath to web.xml(src/main/webapp) in my case.

Resources