3

I have deployed a standard war file as an osgi bundle into equinox using bnd to create a war bundle. Whilst it deploys ok and I can run the app, I cannot see any images or css files. I have deployed catalina-start as an osgi bundle and am using spring-web-extender as the bridge. The image/css files are located at the root of the war file

root
|_images
|_css
|_META-INF
|_WEB-INF

I have seen others deploy images and css files in fragment bundles, but I would have thought this should just work.

Any help appreciated.

skaffman
  • 398,947
  • 96
  • 818
  • 769
Barry
  • 81
  • 1
  • 5
  • More information please. What is the error message (if any)? How do you reference the static resources from your Java code? – Neil Bartlett Oct 19 '10 at 20:37
  • Hi, i just get 404 error when the jsp tries load css, images etc. I works fine though if I deploy using Jetty bundle. – Barry Oct 22 '10 at 13:35

1 Answers1

2

As alternative, you can try Eclipse Jetty Web engine 7.x [1] that was redesigned to support OSGi Web Application Bundles (OSGi Enterprise 4.2:128). I use Jetty and do not have any problems with WAR static resources (images, scripts etc.)

[1] - http://eclipse.org/jetty/

Regards, Dmytro

Dmytro Pishchukhin
  • 2,369
  • 1
  • 14
  • 19
  • Hi, I have since switched to using a jetty 6.x bundle and static resources now resolve fine, thanks. – Barry Oct 22 '10 at 13:36