Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jetty-users] Differences in resource loading between Jetty 9.2 and 9.4

The ServletContext resource loading hasn't changed in a way that makes it out of spec.
Resource loading from a ServletContext is still dependent on the WebAppClassloader for the specific WebAppContext, that hasn't changed.

The biggest change kinda related was probably the update to DefaultServlet / ResourceService where we made performance updates for byte-range support of large files (think 4GB+).
Then there was also an update to DefaultServlet and ResourceService to support java virtual filesystems behaviors.

The description you have given is really insufficient to explain anything.
Can you mock up a simple example project to demonstrate what you are describing?

Joakim Erdfelt / joakim@xxxxxxxxxxx


On Wed, Dec 18, 2019 at 9:54 AM James Sanderson <James.Sanderson@xxxxxxxxxx> wrote:

 

We’re in the process of updating our app to move from jetty 9.2 to 9.4 and are having some weird things happen with resource loading.

 

We’ve got a couple of web apps that are auto deployed; but we’re finding that one seems to be affecting the other when it comes to loading resources using ServletContext.getResourceAsStream()

 

We have two apps A and B deployed under /A and /B, they have a common jar files (about 50mb) which we add into the base jetty class loader rather than having it in each of the web apps; parts of this jar will do resource loading using classes which have singletons – yes I know its horrid but its been working ok for 15 years… (I know they need reworking… but its not practical now)

 

What we seem to be finding is that depending on the speed of system we get the apps instantiating in different orders – and as a consequence one app could do a getResourceAsStream on the context from the other app because the class was loaded by the other app first – hopefully that makes sense.

 

Have their been any changes in the class loading / resource loading mechanism between jetty 9.2 and 9.4 ?

 

Cheers

james

 



Zellis is the trading name for Zellis Holdings Ltd and its associated companies “Zellis”.

The contents of this email are confidential to Zellis and are solely for the use of the intended recipient. If you received this email in error, please inform the sender immediately and delete the email from your system. Unless Zellis have given you express permission to do so, please do not disclose, distribute or copy the contents of this email.

Unless this email expressly states that it is a contractual offer or acceptance, it is not sent with the intention of creating a legal relationship and does not constitute an offer or acceptance which could give rise to a contract.

Any views expressed in this email are those of the individual sender unless the email specifically states them to be the views of Zellis.

Zellis Holdings Ltd - registered in England and Wales - Company No: 10975623 - Registered Office: Peoplebuilding 2, Peoplebuilding Estate, Maylands Avenue, Hemel Hempstead, Hertfordshire, HP2 4NW, UK.
_______________________________________________
jetty-users mailing list
jetty-users@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://www.eclipse.org/mailman/listinfo/jetty-users

Back to the top