Everything is detected several times in my web app

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

Everything is detected several times in my web app

jason zhang
I have a web application(http://data.flexdms.com/demo.war) which is fine under tomcat. I am trying to enable it under jetty. 
I downloaded the latest jetty(jetty-distribution-9.2.10.v20150310)


Jetty complains that 

 Multiple servlets map to path: /rs/*: com.flexdms.flexims.jpa.rs.RSApplication,com.flexdms.flexims.jpa.rs.RSApplication

You can see that all the classes mapped to /rs/* are the same class. I actually have this mapping in a web-fragment.xml. I use quickstart feature to debug why this is. It turns out jetty finds everything several times. 


I attached the generated quickstart-web.xml. You can see everything including jar file, servlet mapping, listener, filter mapping is repeated several times in the quickstart-web.xml. This may be the problem. 

Any suggestion?

--
-jiesheng

_______________________________________________
jetty-users mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/jetty-users

quickstart-web.xml (63K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Everything is detected several times in my web app

Jan Bartel-3
Jason,

Please post how you are deploying and configuring your webapp in jetty
- include any context xml files or other jetty xml config files you
have altered.

Jan

On 26 April 2015 at 15:13, jason zhang <[hidden email]> wrote:

> I have a web application(http://data.flexdms.com/demo.war) which is fine
> under tomcat. I am trying to enable it under jetty.
> I downloaded the latest jetty(jetty-distribution-9.2.10.v20150310)
>
>
> Jetty complains that
>
>  Multiple servlets map to path: /rs/*:
> com.flexdms.flexims.jpa.rs.RSApplication,com.flexdms.flexims.jpa.rs.RSApplication
>
> You can see that all the classes mapped to /rs/* are the same class. I
> actually have this mapping in a web-fragment.xml. I use quickstart feature
> to debug why this is. It turns out jetty finds everything several times.
>
>
> I attached the generated quickstart-web.xml. You can see everything
> including jar file, servlet mapping, listener, filter mapping is repeated
> several times in the quickstart-web.xml. This may be the problem.
>
> Any suggestion?
>
> --
> -jiesheng
>
> _______________________________________________
> jetty-users mailing list
> [hidden email]
> To change your delivery options, retrieve your password, or unsubscribe from
> this list, visit
> https://dev.eclipse.org/mailman/listinfo/jetty-users



--
Jan Bartel <[hidden email]>
www.webtide.com
'Expert Jetty/CometD developer,production,operations advice'
_______________________________________________
jetty-users mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/jetty-users
Reply | Threaded
Open this post in threaded view
|

Re: Everything is detected several times in my web app

Jan Bartel-3
And also post the log output with
-Dorg.eclipse.jetty.webapp.LEVEL=DEBUG
-Dorg.eclipse.jetty.annotations.LEVEL=DEBUG enabled as well please.

Jan

On 26 April 2015 at 16:38, Jan Bartel <[hidden email]> wrote:

> Jason,
>
> Please post how you are deploying and configuring your webapp in jetty
> - include any context xml files or other jetty xml config files you
> have altered.
>
> Jan
>
> On 26 April 2015 at 15:13, jason zhang <[hidden email]> wrote:
>> I have a web application(http://data.flexdms.com/demo.war) which is fine
>> under tomcat. I am trying to enable it under jetty.
>> I downloaded the latest jetty(jetty-distribution-9.2.10.v20150310)
>>
>>
>> Jetty complains that
>>
>>  Multiple servlets map to path: /rs/*:
>> com.flexdms.flexims.jpa.rs.RSApplication,com.flexdms.flexims.jpa.rs.RSApplication
>>
>> You can see that all the classes mapped to /rs/* are the same class. I
>> actually have this mapping in a web-fragment.xml. I use quickstart feature
>> to debug why this is. It turns out jetty finds everything several times.
>>
>>
>> I attached the generated quickstart-web.xml. You can see everything
>> including jar file, servlet mapping, listener, filter mapping is repeated
>> several times in the quickstart-web.xml. This may be the problem.
>>
>> Any suggestion?
>>
>> --
>> -jiesheng
>>
>> _______________________________________________
>> jetty-users mailing list
>> [hidden email]
>> To change your delivery options, retrieve your password, or unsubscribe from
>> this list, visit
>> https://dev.eclipse.org/mailman/listinfo/jetty-users
>
>
>
> --
> Jan Bartel <[hidden email]>
> www.webtide.com
> 'Expert Jetty/CometD developer,production,operations advice'



--
Jan Bartel <[hidden email]>
www.webtide.com
'Expert Jetty/CometD developer,production,operations advice'
_______________________________________________
jetty-users mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/jetty-users
Reply | Threaded
Open this post in threaded view
|

Re: Everything is detected several times in my web app

jason zhang
Hi Jan
I have jetty-env.xml and jetty-web.xml  under WEB-INF in the war file.  The purpose of these  two files are to integrate with WELD and  set up datasource. I follow the document in weld to integrate WELD with jetty instead of using weld module. 


The produced war is here: http://data.flexdms.com/demo1.war

The log file is too big to paste here: I uploaded it here: http://data.flexdms.com/jetty.log

Thanks


On Sat, Apr 25, 2015 at 11:52 PM, Jan Bartel <[hidden email]> wrote:
And also post the log output with
-Dorg.eclipse.jetty.webapp.LEVEL=DEBUG
-Dorg.eclipse.jetty.annotations.LEVEL=DEBUG enabled as well please.

Jan

On 26 April 2015 at 16:38, Jan Bartel <[hidden email]> wrote:
> Jason,
>
> Please post how you are deploying and configuring your webapp in jetty
> - include any context xml files or other jetty xml config files you
> have altered.
>
> Jan
>
> On 26 April 2015 at 15:13, jason zhang <[hidden email]> wrote:
>> I have a web application(http://data.flexdms.com/demo.war) which is fine
>> under tomcat. I am trying to enable it under jetty.
>> I downloaded the latest jetty(jetty-distribution-9.2.10.v20150310)
>>
>>
>> Jetty complains that
>>
>>  Multiple servlets map to path: /rs/*:
>> com.flexdms.flexims.jpa.rs.RSApplication,com.flexdms.flexims.jpa.rs.RSApplication
>>
>> You can see that all the classes mapped to /rs/* are the same class. I
>> actually have this mapping in a web-fragment.xml. I use quickstart feature
>> to debug why this is. It turns out jetty finds everything several times.
>>
>>
>> I attached the generated quickstart-web.xml. You can see everything
>> including jar file, servlet mapping, listener, filter mapping is repeated
>> several times in the quickstart-web.xml. This may be the problem.
>>
>> Any suggestion?
>>
>> --
>> -jiesheng
>>
>> _______________________________________________
>> jetty-users mailing list
>> [hidden email]
>> To change your delivery options, retrieve your password, or unsubscribe from
>> this list, visit
>> https://dev.eclipse.org/mailman/listinfo/jetty-users
>
>
>
> --
> Jan Bartel <[hidden email]>
> www.webtide.com
> 'Expert Jetty/CometD developer,production,operations advice'



--
Jan Bartel <[hidden email]>
www.webtide.com
'Expert Jetty/CometD developer,production,operations advice'
_______________________________________________
jetty-users mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/jetty-users



--
-jiesheng

_______________________________________________
jetty-users mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/jetty-users
Reply | Threaded
Open this post in threaded view
|

Re: Everything is detected several times in my web app

jason zhang
This seems to be weld integration issue.
My war file will contain

The war file manage weld integraiton itself.

If I use weld-2.1.2.Finla, I got the  :Multiple servlets map to path: /rs/*: com.flexdms.flexims.jpa.rs.RSApplication,com.flexdms.flexims.jpa.rs.RSApplication"
If I use weld-2.2.5.Final, I don't have this problem.


But I got this problem: java.lang.ClassNotFoundException: org.eclipse.jetty.servlet.ServletContextHandler$Decorator

I don't have the java.lang.ClassNotFoundException: org.eclipse.jetty.servlet.ServletContextHandler$Decorator if I use external context.xml or cdi module.

So 
<Set name="serverClasses">

        <Array type="java.lang.String">

            <Item>-org.eclipse.jetty.servlet.ServletContextHandler.Decorator</Item>

        </Array>

    </Set>

behaves different when i external context.xml and internal web.xml

Is this expected behavior?

thanks


On Sun, Apr 26, 2015 at 8:42 PM, jason zhang <[hidden email]> wrote:
Hi Jan
I have jetty-env.xml and jetty-web.xml  under WEB-INF in the war file.  The purpose of these  two files are to integrate with WELD and  set up datasource. I follow the document in weld to integrate WELD with jetty instead of using weld module. 


The produced war is here: http://data.flexdms.com/demo1.war

The log file is too big to paste here: I uploaded it here: http://data.flexdms.com/jetty.log

Thanks


On Sat, Apr 25, 2015 at 11:52 PM, Jan Bartel <[hidden email]> wrote:
And also post the log output with
-Dorg.eclipse.jetty.webapp.LEVEL=DEBUG
-Dorg.eclipse.jetty.annotations.LEVEL=DEBUG enabled as well please.

Jan

On 26 April 2015 at 16:38, Jan Bartel <[hidden email]> wrote:
> Jason,
>
> Please post how you are deploying and configuring your webapp in jetty
> - include any context xml files or other jetty xml config files you
> have altered.
>
> Jan
>
> On 26 April 2015 at 15:13, jason zhang <[hidden email]> wrote:
>> I have a web application(http://data.flexdms.com/demo.war) which is fine
>> under tomcat. I am trying to enable it under jetty.
>> I downloaded the latest jetty(jetty-distribution-9.2.10.v20150310)
>>
>>
>> Jetty complains that
>>
>>  Multiple servlets map to path: /rs/*:
>> com.flexdms.flexims.jpa.rs.RSApplication,com.flexdms.flexims.jpa.rs.RSApplication
>>
>> You can see that all the classes mapped to /rs/* are the same class. I
>> actually have this mapping in a web-fragment.xml. I use quickstart feature
>> to debug why this is. It turns out jetty finds everything several times.
>>
>>
>> I attached the generated quickstart-web.xml. You can see everything
>> including jar file, servlet mapping, listener, filter mapping is repeated
>> several times in the quickstart-web.xml. This may be the problem.
>>
>> Any suggestion?
>>
>> --
>> -jiesheng
>>
>> _______________________________________________
>> jetty-users mailing list
>> [hidden email]
>> To change your delivery options, retrieve your password, or unsubscribe from
>> this list, visit
>> https://dev.eclipse.org/mailman/listinfo/jetty-users
>
>
>
> --
> Jan Bartel <[hidden email]>
> www.webtide.com
> 'Expert Jetty/CometD developer,production,operations advice'



--
Jan Bartel <[hidden email]>
www.webtide.com
'Expert Jetty/CometD developer,production,operations advice'
_______________________________________________
jetty-users mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/jetty-users



--
-jiesheng



--
-jiesheng

_______________________________________________
jetty-users mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/jetty-users
Reply | Threaded
Open this post in threaded view
|

Re: Everything is detected several times in my web app

jason zhang
I deployed the application using cdi module. 
Using  context.xml for weld outside of war  works, too.

On Mon, Apr 27, 2015 at 9:47 PM, jason zhang <[hidden email]> wrote:
This seems to be weld integration issue.
My war file will contain

The war file manage weld integraiton itself.

If I use weld-2.1.2.Finla, I got the  :Multiple servlets map to path: /rs/*: com.flexdms.flexims.jpa.rs.RSApplication,com.flexdms.flexims.jpa.rs.RSApplication"
If I use weld-2.2.5.Final, I don't have this problem.


But I got this problem: java.lang.ClassNotFoundException: org.eclipse.jetty.servlet.ServletContextHandler$Decorator

I don't have the java.lang.ClassNotFoundException: org.eclipse.jetty.servlet.ServletContextHandler$Decorator if I use external context.xml or cdi module.

So 
<Set name="serverClasses">

        <Array type="java.lang.String">

            <Item>-org.eclipse.jetty.servlet.ServletContextHandler.Decorator</Item>

        </Array>

    </Set>

behaves different when i external context.xml and internal web.xml

Is this expected behavior?

thanks


On Sun, Apr 26, 2015 at 8:42 PM, jason zhang <[hidden email]> wrote:
Hi Jan
I have jetty-env.xml and jetty-web.xml  under WEB-INF in the war file.  The purpose of these  two files are to integrate with WELD and  set up datasource. I follow the document in weld to integrate WELD with jetty instead of using weld module. 


The produced war is here: http://data.flexdms.com/demo1.war

The log file is too big to paste here: I uploaded it here: http://data.flexdms.com/jetty.log

Thanks


On Sat, Apr 25, 2015 at 11:52 PM, Jan Bartel <[hidden email]> wrote:
And also post the log output with
-Dorg.eclipse.jetty.webapp.LEVEL=DEBUG
-Dorg.eclipse.jetty.annotations.LEVEL=DEBUG enabled as well please.

Jan

On 26 April 2015 at 16:38, Jan Bartel <[hidden email]> wrote:
> Jason,
>
> Please post how you are deploying and configuring your webapp in jetty
> - include any context xml files or other jetty xml config files you
> have altered.
>
> Jan
>
> On 26 April 2015 at 15:13, jason zhang <[hidden email]> wrote:
>> I have a web application(http://data.flexdms.com/demo.war) which is fine
>> under tomcat. I am trying to enable it under jetty.
>> I downloaded the latest jetty(jetty-distribution-9.2.10.v20150310)
>>
>>
>> Jetty complains that
>>
>>  Multiple servlets map to path: /rs/*:
>> com.flexdms.flexims.jpa.rs.RSApplication,com.flexdms.flexims.jpa.rs.RSApplication
>>
>> You can see that all the classes mapped to /rs/* are the same class. I
>> actually have this mapping in a web-fragment.xml. I use quickstart feature
>> to debug why this is. It turns out jetty finds everything several times.
>>
>>
>> I attached the generated quickstart-web.xml. You can see everything
>> including jar file, servlet mapping, listener, filter mapping is repeated
>> several times in the quickstart-web.xml. This may be the problem.
>>
>> Any suggestion?
>>
>> --
>> -jiesheng
>>
>> _______________________________________________
>> jetty-users mailing list
>> [hidden email]
>> To change your delivery options, retrieve your password, or unsubscribe from
>> this list, visit
>> https://dev.eclipse.org/mailman/listinfo/jetty-users
>
>
>
> --
> Jan Bartel <[hidden email]>
> www.webtide.com
> 'Expert Jetty/CometD developer,production,operations advice'



--
Jan Bartel <[hidden email]>
www.webtide.com
'Expert Jetty/CometD developer,production,operations advice'
_______________________________________________
jetty-users mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/jetty-users



--
-jiesheng



--
-jiesheng



--
-jiesheng

_______________________________________________
jetty-users mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/jetty-users