You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@aries.apache.org by Charles Moulliard <cm...@gmail.com> on 2011/01/21 11:42:41 UTC

Aries Blog Sample JPA - EBA on Apache Karaf

Hi,

I have been able to deploy successfully on Karaf the Aries Blog Sample
JPA eba archive but I see that the images/ or style/blog.css directory
present in the bundle are not accessible from the browser.

For info, here is the MANIFEST generated :

Manifest-Version: 1.0
Implementation-Title: Apache Aries
Implementation-Version: 0.3-SNAPSHOT
Bundle-ClassPath: WEB-INF/classes
Built-By: charlesmoulliard
Tool: Bnd-1.15.0
Bundle-Name: Apache Aries blog sample web component
Created-By: Apache Maven Bundle Plugin
Web-ContextPath: /blog
Bundle-Vendor: The Apache Software Foundation
Build-Jdk: 1.6.0_22
Bundle-Version: 0.3.0.SNAPSHOT
Bnd-LastModified: 1295601008095
Bundle-ManifestVersion: 2
Bundle-License: http://www.apache.org/licenses/LICENSE-2.0.txt
Bundle-Description: Aries top-level parent pom
Bundle-DocURL: http://www.apache.org
Bundle-SymbolicName: org.apache.aries.samples.blog.web
Import-Package: javax.naming,javax.servlet;version="2.5",javax.servlet
 .http;version="2.5",org.apache.aries.samples.blog.api;version="[0.3,1
 )"

So my question is : How can PAX-WEB and/or JETTY have access to the
web resources located in the root of the bundle like images, styles,
... directories ?

Regards,

Charles Moulliard

Sr. Principal Solution Architect - FuseSource
Apache Committer

Blog : http://cmoulliard.blogspot.com
Twitter : http://twitter.com/cmoulliard
Linkedin : http://www.linkedin.com/in/charlesmoulliard
Skype: cmoulliard

Re: Aries Blog Sample JPA - EBA on Apache Karaf

Posted by Alasdair Nottingham <no...@apache.org>.
No, the static content does not need to be on the classpath to be served, well except where there are bugs in a web app container impl, which would make it not compliant with the spec.

Alasdair Nottingham

On 21 Jan 2011, at 10:49, "Nick Wilson" <ni...@card.co.uk> wrote:

> Should the Bundle-Classpath be ".,WEB-INF/classes"?
> 
> Nick
> 
> 
> -----Original Message-----
> From: Charles Moulliard [mailto:cmoulliard@gmail.com] 
> Sent: 21 January 2011 10:43
> To: user@aries.apache.org; user
> Subject: Aries Blog Sample JPA - EBA on Apache Karaf
> 
> Hi,
> 
> I have been able to deploy successfully on Karaf the Aries Blog Sample
> JPA eba archive but I see that the images/ or style/blog.css directory
> present in the bundle are not accessible from the browser.
> 
> For info, here is the MANIFEST generated :
> 
> Manifest-Version: 1.0
> Implementation-Title: Apache Aries
> Implementation-Version: 0.3-SNAPSHOT
> Bundle-ClassPath: WEB-INF/classes
> Built-By: charlesmoulliard
> Tool: Bnd-1.15.0
> Bundle-Name: Apache Aries blog sample web component
> Created-By: Apache Maven Bundle Plugin
> Web-ContextPath: /blog
> Bundle-Vendor: The Apache Software Foundation
> Build-Jdk: 1.6.0_22
> Bundle-Version: 0.3.0.SNAPSHOT
> Bnd-LastModified: 1295601008095
> Bundle-ManifestVersion: 2
> Bundle-License: http://www.apache.org/licenses/LICENSE-2.0.txt
> Bundle-Description: Aries top-level parent pom
> Bundle-DocURL: http://www.apache.org
> Bundle-SymbolicName: org.apache.aries.samples.blog.web
> Import-Package: javax.naming,javax.servlet;version="2.5",javax.servlet
> .http;version="2.5",org.apache.aries.samples.blog.api;version="[0.3,1
> )"
> 
> So my question is : How can PAX-WEB and/or JETTY have access to the
> web resources located in the root of the bundle like images, styles,
> ... directories ?
> 
> Regards,
> 
> Charles Moulliard
> 
> Sr. Principal Solution Architect - FuseSource
> Apache Committer
> 
> Blog : http://cmoulliard.blogspot.com
> Twitter : http://twitter.com/cmoulliard
> Linkedin : http://www.linkedin.com/in/charlesmoulliard
> Skype: cmoulliard

RE: Aries Blog Sample JPA - EBA on Apache Karaf

Posted by Nick Wilson <ni...@card.co.uk>.
Should the Bundle-Classpath be ".,WEB-INF/classes"?

Nick


-----Original Message-----
From: Charles Moulliard [mailto:cmoulliard@gmail.com] 
Sent: 21 January 2011 10:43
To: user@aries.apache.org; user
Subject: Aries Blog Sample JPA - EBA on Apache Karaf

Hi,

I have been able to deploy successfully on Karaf the Aries Blog Sample
JPA eba archive but I see that the images/ or style/blog.css directory
present in the bundle are not accessible from the browser.

For info, here is the MANIFEST generated :

Manifest-Version: 1.0
Implementation-Title: Apache Aries
Implementation-Version: 0.3-SNAPSHOT
Bundle-ClassPath: WEB-INF/classes
Built-By: charlesmoulliard
Tool: Bnd-1.15.0
Bundle-Name: Apache Aries blog sample web component
Created-By: Apache Maven Bundle Plugin
Web-ContextPath: /blog
Bundle-Vendor: The Apache Software Foundation
Build-Jdk: 1.6.0_22
Bundle-Version: 0.3.0.SNAPSHOT
Bnd-LastModified: 1295601008095
Bundle-ManifestVersion: 2
Bundle-License: http://www.apache.org/licenses/LICENSE-2.0.txt
Bundle-Description: Aries top-level parent pom
Bundle-DocURL: http://www.apache.org
Bundle-SymbolicName: org.apache.aries.samples.blog.web
Import-Package: javax.naming,javax.servlet;version="2.5",javax.servlet
 .http;version="2.5",org.apache.aries.samples.blog.api;version="[0.3,1
 )"

So my question is : How can PAX-WEB and/or JETTY have access to the
web resources located in the root of the bundle like images, styles,
... directories ?

Regards,

Charles Moulliard

Sr. Principal Solution Architect - FuseSource
Apache Committer

Blog : http://cmoulliard.blogspot.com
Twitter : http://twitter.com/cmoulliard
Linkedin : http://www.linkedin.com/in/charlesmoulliard
Skype: cmoulliard

Re: Aries Blog Sample JPA - EBA on Apache Karaf

Posted by Charles Moulliard <cm...@gmail.com>.
With PAX-WEB 1.0.0-SNAPSHOT, the problem is solved.

Regards,

Charles


On Fri, Jan 21, 2011 at 8:44 PM, Alasdair Nottingham <no...@apache.org> wrote:
> The blog assembly makes use of pax web 0.8.1 and I do see the web
> content being served without it being on the classpath. I can't seem
> to get hold of 0.8.2-SNAPSHOT to see if that works differently. Is
> there any chance of trying with 0.8.1 to see if you get the same
> behaviour? Or trying out the blog assembly on your machine in case I
> have a weird system?
>
> Thanks
> Alasdair
>
> On 21 January 2011 11:21, Charles Moulliard <cm...@gmail.com> wrote:
>> We use PAX WEB 0.8.2-SNAPSHOT
>>
>> [  83] [Active     ] [            ] [   60] OPS4J Pax Web - API (0.8.2.SNAPSHOT)
>> [  84] [Active     ] [            ] [   60] OPS4J Pax Web - Service
>> SPI (0.8.2.SNAPSHOT)
>> [  85] [Active     ] [            ] [   60] OPS4J Pax Web - Runtime
>> (0.8.2.SNAPSHOT)
>> [  86] [Active     ] [            ] [   60] OPS4J Pax Web - Jetty
>> (0.8.2.SNAPSHOT)
>> [  88] [Active     ] [            ] [   60] OPS4J Pax Web - Jsp
>> Support (0.8.2.SNAPSHOT)
>> [  89] [Active     ] [            ] [   60] OPS4J Pax Web - Extender -
>> WAR (0.8.2.SNAPSHOT)
>> [  90] [Active     ] [            ] [   60] OPS4J Pax Web - Extender -
>> Whiteboard (0.8.2.SNAPSHOT)
>> [  91] [Active     ] [            ] [   60] OPS4J Pax Web -
>> FileInstall Deployer (0.8.2.SNAPSHOT)
>>
>>
>>
>> On Fri, Jan 21, 2011 at 12:07 PM, Alasdair Nottingham <no...@apache.org> wrote:
>>> Hi, you need 0.81 of the pax-web project. That works for me.
>>>
>>> Alasdair Nottingham
>>>
>>> On 21 Jan 2011, at 10:42, Charles Moulliard <cm...@gmail.com> wrote:
>>>
>>>> Hi,
>>>>
>>>> I have been able to deploy successfully on Karaf the Aries Blog Sample
>>>> JPA eba archive but I see that the images/ or style/blog.css directory
>>>> present in the bundle are not accessible from the browser.
>>>>
>>>> For info, here is the MANIFEST generated :
>>>>
>>>> Manifest-Version: 1.0
>>>> Implementation-Title: Apache Aries
>>>> Implementation-Version: 0.3-SNAPSHOT
>>>> Bundle-ClassPath: WEB-INF/classes
>>>> Built-By: charlesmoulliard
>>>> Tool: Bnd-1.15.0
>>>> Bundle-Name: Apache Aries blog sample web component
>>>> Created-By: Apache Maven Bundle Plugin
>>>> Web-ContextPath: /blog
>>>> Bundle-Vendor: The Apache Software Foundation
>>>> Build-Jdk: 1.6.0_22
>>>> Bundle-Version: 0.3.0.SNAPSHOT
>>>> Bnd-LastModified: 1295601008095
>>>> Bundle-ManifestVersion: 2
>>>> Bundle-License: http://www.apache.org/licenses/LICENSE-2.0.txt
>>>> Bundle-Description: Aries top-level parent pom
>>>> Bundle-DocURL: http://www.apache.org
>>>> Bundle-SymbolicName: org.apache.aries.samples.blog.web
>>>> Import-Package: javax.naming,javax.servlet;version="2.5",javax.servlet
>>>> .http;version="2.5",org.apache.aries.samples.blog.api;version="[0.3,1
>>>> )"
>>>>
>>>> So my question is : How can PAX-WEB and/or JETTY have access to the
>>>> web resources located in the root of the bundle like images, styles,
>>>> ... directories ?
>>>>
>>>> Regards,
>>>>
>>>> Charles Moulliard
>>>>
>>>> Sr. Principal Solution Architect - FuseSource
>>>> Apache Committer
>>>>
>>>> Blog : http://cmoulliard.blogspot.com
>>>> Twitter : http://twitter.com/cmoulliard
>>>> Linkedin : http://www.linkedin.com/in/charlesmoulliard
>>>> Skype: cmoulliard
>>>
>>
>
>
>
> --
> Alasdair Nottingham
> not@apache.org
>

Re: Aries Blog Sample JPA - EBA on Apache Karaf

Posted by Alasdair Nottingham <no...@apache.org>.
The blog assembly makes use of pax web 0.8.1 and I do see the web
content being served without it being on the classpath. I can't seem
to get hold of 0.8.2-SNAPSHOT to see if that works differently. Is
there any chance of trying with 0.8.1 to see if you get the same
behaviour? Or trying out the blog assembly on your machine in case I
have a weird system?

Thanks
Alasdair

On 21 January 2011 11:21, Charles Moulliard <cm...@gmail.com> wrote:
> We use PAX WEB 0.8.2-SNAPSHOT
>
> [  83] [Active     ] [            ] [   60] OPS4J Pax Web - API (0.8.2.SNAPSHOT)
> [  84] [Active     ] [            ] [   60] OPS4J Pax Web - Service
> SPI (0.8.2.SNAPSHOT)
> [  85] [Active     ] [            ] [   60] OPS4J Pax Web - Runtime
> (0.8.2.SNAPSHOT)
> [  86] [Active     ] [            ] [   60] OPS4J Pax Web - Jetty
> (0.8.2.SNAPSHOT)
> [  88] [Active     ] [            ] [   60] OPS4J Pax Web - Jsp
> Support (0.8.2.SNAPSHOT)
> [  89] [Active     ] [            ] [   60] OPS4J Pax Web - Extender -
> WAR (0.8.2.SNAPSHOT)
> [  90] [Active     ] [            ] [   60] OPS4J Pax Web - Extender -
> Whiteboard (0.8.2.SNAPSHOT)
> [  91] [Active     ] [            ] [   60] OPS4J Pax Web -
> FileInstall Deployer (0.8.2.SNAPSHOT)
>
>
>
> On Fri, Jan 21, 2011 at 12:07 PM, Alasdair Nottingham <no...@apache.org> wrote:
>> Hi, you need 0.81 of the pax-web project. That works for me.
>>
>> Alasdair Nottingham
>>
>> On 21 Jan 2011, at 10:42, Charles Moulliard <cm...@gmail.com> wrote:
>>
>>> Hi,
>>>
>>> I have been able to deploy successfully on Karaf the Aries Blog Sample
>>> JPA eba archive but I see that the images/ or style/blog.css directory
>>> present in the bundle are not accessible from the browser.
>>>
>>> For info, here is the MANIFEST generated :
>>>
>>> Manifest-Version: 1.0
>>> Implementation-Title: Apache Aries
>>> Implementation-Version: 0.3-SNAPSHOT
>>> Bundle-ClassPath: WEB-INF/classes
>>> Built-By: charlesmoulliard
>>> Tool: Bnd-1.15.0
>>> Bundle-Name: Apache Aries blog sample web component
>>> Created-By: Apache Maven Bundle Plugin
>>> Web-ContextPath: /blog
>>> Bundle-Vendor: The Apache Software Foundation
>>> Build-Jdk: 1.6.0_22
>>> Bundle-Version: 0.3.0.SNAPSHOT
>>> Bnd-LastModified: 1295601008095
>>> Bundle-ManifestVersion: 2
>>> Bundle-License: http://www.apache.org/licenses/LICENSE-2.0.txt
>>> Bundle-Description: Aries top-level parent pom
>>> Bundle-DocURL: http://www.apache.org
>>> Bundle-SymbolicName: org.apache.aries.samples.blog.web
>>> Import-Package: javax.naming,javax.servlet;version="2.5",javax.servlet
>>> .http;version="2.5",org.apache.aries.samples.blog.api;version="[0.3,1
>>> )"
>>>
>>> So my question is : How can PAX-WEB and/or JETTY have access to the
>>> web resources located in the root of the bundle like images, styles,
>>> ... directories ?
>>>
>>> Regards,
>>>
>>> Charles Moulliard
>>>
>>> Sr. Principal Solution Architect - FuseSource
>>> Apache Committer
>>>
>>> Blog : http://cmoulliard.blogspot.com
>>> Twitter : http://twitter.com/cmoulliard
>>> Linkedin : http://www.linkedin.com/in/charlesmoulliard
>>> Skype: cmoulliard
>>
>



-- 
Alasdair Nottingham
not@apache.org

Re: Aries Blog Sample JPA - EBA on Apache Karaf

Posted by Charles Moulliard <cm...@gmail.com>.
We use PAX WEB 0.8.2-SNAPSHOT

[  83] [Active     ] [            ] [   60] OPS4J Pax Web - API (0.8.2.SNAPSHOT)
[  84] [Active     ] [            ] [   60] OPS4J Pax Web - Service
SPI (0.8.2.SNAPSHOT)
[  85] [Active     ] [            ] [   60] OPS4J Pax Web - Runtime
(0.8.2.SNAPSHOT)
[  86] [Active     ] [            ] [   60] OPS4J Pax Web - Jetty
(0.8.2.SNAPSHOT)
[  88] [Active     ] [            ] [   60] OPS4J Pax Web - Jsp
Support (0.8.2.SNAPSHOT)
[  89] [Active     ] [            ] [   60] OPS4J Pax Web - Extender -
WAR (0.8.2.SNAPSHOT)
[  90] [Active     ] [            ] [   60] OPS4J Pax Web - Extender -
Whiteboard (0.8.2.SNAPSHOT)
[  91] [Active     ] [            ] [   60] OPS4J Pax Web -
FileInstall Deployer (0.8.2.SNAPSHOT)



On Fri, Jan 21, 2011 at 12:07 PM, Alasdair Nottingham <no...@apache.org> wrote:
> Hi, you need 0.81 of the pax-web project. That works for me.
>
> Alasdair Nottingham
>
> On 21 Jan 2011, at 10:42, Charles Moulliard <cm...@gmail.com> wrote:
>
>> Hi,
>>
>> I have been able to deploy successfully on Karaf the Aries Blog Sample
>> JPA eba archive but I see that the images/ or style/blog.css directory
>> present in the bundle are not accessible from the browser.
>>
>> For info, here is the MANIFEST generated :
>>
>> Manifest-Version: 1.0
>> Implementation-Title: Apache Aries
>> Implementation-Version: 0.3-SNAPSHOT
>> Bundle-ClassPath: WEB-INF/classes
>> Built-By: charlesmoulliard
>> Tool: Bnd-1.15.0
>> Bundle-Name: Apache Aries blog sample web component
>> Created-By: Apache Maven Bundle Plugin
>> Web-ContextPath: /blog
>> Bundle-Vendor: The Apache Software Foundation
>> Build-Jdk: 1.6.0_22
>> Bundle-Version: 0.3.0.SNAPSHOT
>> Bnd-LastModified: 1295601008095
>> Bundle-ManifestVersion: 2
>> Bundle-License: http://www.apache.org/licenses/LICENSE-2.0.txt
>> Bundle-Description: Aries top-level parent pom
>> Bundle-DocURL: http://www.apache.org
>> Bundle-SymbolicName: org.apache.aries.samples.blog.web
>> Import-Package: javax.naming,javax.servlet;version="2.5",javax.servlet
>> .http;version="2.5",org.apache.aries.samples.blog.api;version="[0.3,1
>> )"
>>
>> So my question is : How can PAX-WEB and/or JETTY have access to the
>> web resources located in the root of the bundle like images, styles,
>> ... directories ?
>>
>> Regards,
>>
>> Charles Moulliard
>>
>> Sr. Principal Solution Architect - FuseSource
>> Apache Committer
>>
>> Blog : http://cmoulliard.blogspot.com
>> Twitter : http://twitter.com/cmoulliard
>> Linkedin : http://www.linkedin.com/in/charlesmoulliard
>> Skype: cmoulliard
>

Re: Aries Blog Sample JPA - EBA on Apache Karaf

Posted by Alasdair Nottingham <no...@apache.org>.
Hi, you need 0.81 of the pax-web project. That works for me.

Alasdair Nottingham

On 21 Jan 2011, at 10:42, Charles Moulliard <cm...@gmail.com> wrote:

> Hi,
> 
> I have been able to deploy successfully on Karaf the Aries Blog Sample
> JPA eba archive but I see that the images/ or style/blog.css directory
> present in the bundle are not accessible from the browser.
> 
> For info, here is the MANIFEST generated :
> 
> Manifest-Version: 1.0
> Implementation-Title: Apache Aries
> Implementation-Version: 0.3-SNAPSHOT
> Bundle-ClassPath: WEB-INF/classes
> Built-By: charlesmoulliard
> Tool: Bnd-1.15.0
> Bundle-Name: Apache Aries blog sample web component
> Created-By: Apache Maven Bundle Plugin
> Web-ContextPath: /blog
> Bundle-Vendor: The Apache Software Foundation
> Build-Jdk: 1.6.0_22
> Bundle-Version: 0.3.0.SNAPSHOT
> Bnd-LastModified: 1295601008095
> Bundle-ManifestVersion: 2
> Bundle-License: http://www.apache.org/licenses/LICENSE-2.0.txt
> Bundle-Description: Aries top-level parent pom
> Bundle-DocURL: http://www.apache.org
> Bundle-SymbolicName: org.apache.aries.samples.blog.web
> Import-Package: javax.naming,javax.servlet;version="2.5",javax.servlet
> .http;version="2.5",org.apache.aries.samples.blog.api;version="[0.3,1
> )"
> 
> So my question is : How can PAX-WEB and/or JETTY have access to the
> web resources located in the root of the bundle like images, styles,
> ... directories ?
> 
> Regards,
> 
> Charles Moulliard
> 
> Sr. Principal Solution Architect - FuseSource
> Apache Committer
> 
> Blog : http://cmoulliard.blogspot.com
> Twitter : http://twitter.com/cmoulliard
> Linkedin : http://www.linkedin.com/in/charlesmoulliard
> Skype: cmoulliard

Re: Aries Blog Sample JPA - EBA on Apache Karaf

Posted by Achim Nierbeck <bc...@googlemail.com>.
This usually done through the ResourceServlet contained within PAX-WEB.
I can take a look at it later today, or on the weekend :)

How can I reproduce this?

2011/1/21 Charles Moulliard <cm...@gmail.com>:
> Hi,
>
> I have been able to deploy successfully on Karaf the Aries Blog Sample
> JPA eba archive but I see that the images/ or style/blog.css directory
> present in the bundle are not accessible from the browser.
>
> For info, here is the MANIFEST generated :
>
> Manifest-Version: 1.0
> Implementation-Title: Apache Aries
> Implementation-Version: 0.3-SNAPSHOT
> Bundle-ClassPath: WEB-INF/classes
> Built-By: charlesmoulliard
> Tool: Bnd-1.15.0
> Bundle-Name: Apache Aries blog sample web component
> Created-By: Apache Maven Bundle Plugin
> Web-ContextPath: /blog
> Bundle-Vendor: The Apache Software Foundation
> Build-Jdk: 1.6.0_22
> Bundle-Version: 0.3.0.SNAPSHOT
> Bnd-LastModified: 1295601008095
> Bundle-ManifestVersion: 2
> Bundle-License: http://www.apache.org/licenses/LICENSE-2.0.txt
> Bundle-Description: Aries top-level parent pom
> Bundle-DocURL: http://www.apache.org
> Bundle-SymbolicName: org.apache.aries.samples.blog.web
> Import-Package: javax.naming,javax.servlet;version="2.5",javax.servlet
>  .http;version="2.5",org.apache.aries.samples.blog.api;version="[0.3,1
>  )"
>
> So my question is : How can PAX-WEB and/or JETTY have access to the
> web resources located in the root of the bundle like images, styles,
> ... directories ?
>
> Regards,
>
> Charles Moulliard
>
> Sr. Principal Solution Architect - FuseSource
> Apache Committer
>
> Blog : http://cmoulliard.blogspot.com
> Twitter : http://twitter.com/cmoulliard
> Linkedin : http://www.linkedin.com/in/charlesmoulliard
> Skype: cmoulliard
>