Jump to content

Question about packaging images and reports


kurt_cobain

Recommended Posts

Hi, I have a question about packaging reports and images. I currently have a folder called reports that I do this with in a servlet:

 

InputStream reportDesign = getServlet().getServletContext().getResourceAsStream("/reports/report.jasper");

JasperRunManager.runReportToPdfStream(reportDesign, response.getOutputStream(), parameters, conn);

 

When I do an ant build, there is a hierarchy in the WEB-INF/classes folder called reports, and that's where I copy the reports. I also have an images folder.

 

Shouldn't that work? It works in my development environment but not via ant on an application server, I get a null pointer exception trying to open the file (as if it can't find it).

 

Thanks

Link to comment
Share on other sites

  • Replies 0
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

Popular Days

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...