-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Thusitha,

On 3/18/15 11:34 PM, Thusitha Thilina Dayaratne wrote:
> Hi Chris,
> 
> Thanks a lot for the quick response. Please find inline answers.
> 
> On 3/18/15 5:39 AM, Thusitha Thilina Dayaratne wrote:
>>> I'm in the process of migrating embedded tomcat 7.0.59
>>> application to Tomcat 8.0.20. Tomcat is been bundle as a OSGI
>>> bundle. First I get a NullPointerException when trying to
>>> access the server home page. I fixed that manually setting an
>>> empty TldCache instance in the context as follows
>>> 
>>> [snip]
>>> 
>>> 
>>> Now it is not throwing the NPE. but instead of that I'm
>>> getting following exception
>>> 
>>> org.apache.jasper.JasperException: The absolute uri: 
>>> http://tiles.apache.org/tags-tiles cannot be resolved in
>>> either web.xml or the jar files deployed with this application
>>> at
>>> 
> org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:55)
>
> 
>> I
>>> 
>> looks like you are missing the Tiles JAR. Is it located in your 
>> WEB-INF/lib directory?
> These jar files are located in a folder called plugins. We are
> reading them from our JarScanner
> 
>>> I'm also using a extended JarScanner as follows
> 
>>> 
>>> public class CarbonTomcatJarScanner extends
>>> StandardJarScanner{
> 
>> Without trying to read and understand all this code, can you
>> explain why you are using your own JarScanner instead of
>> Tomcat's? Perhaps there is a way to do this where you don't need
>> to write your own JarScanner.
> 
> According the servlet 3.0 spec, tldScanner classes are picked up 
> during web-app load phase from the classPath using SPI mechanism.
> Normal sequence is to scan; - WEB-INF/lib - parent URL classPath 
> However with the BundleClassLoader being the parent classLoader of 
> Tomcat web-app classLoder, it fails to pick up TLD scanner
> references reside in plugins directory. That is why we have used a
> our own JarScanner
> 
>>> It seems that this is relate to JarScanner. Can someone tell
>>> me what I have done wrong here? Or a way to fix this? Is this
>>> occur because I set TldCache manually?
> 
>> I'm curious as to why the TldCache isn't being set up correctly
>> in the first place. In your other recent thread ("NPE in 
>> JspCompilationContext.getTldResourcePath"), there were a couple
>> of questions from the community that it doesn't look like you
>> have answered. Perhaps answering those might help you solve both
>> problems at once.
> 
> I'm not so quite sure about that. I manually set the TldCache and
> manually added the JasperInitializer to the StandardContext to get
> rid of the NPE I will try to answer the an answered questions in
> other thread.

Well, just because you aren't getting an NPE any longer doesn't mean
that you actually solved the root of the problem. The root of the
problem is that your TLDs aren't being loaded. You just ended up
putting a band-aid on the cache, which is still empty.

- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1
Comment: GPGTools - http://gpgtools.org

iQIcBAEBCAAGBQJVCxIkAAoJEBzwKT+lPKRYHkAP/jFYoFQLJXZZ9sf/+UBo9jEx
oDXHloweXQ7T1V8aVu2ksH9mgzPtofSbYTwjeiQimQsAkUW0rFAcBPCrgsnzrrN6
xJss6aFMLC3aac1+linQaWaeSj4WX3lhbe1lghP0yqN18UxsoTuzUg6JqgQ5fs9w
7bAixbQko9GREJbPuT93IvpEcKx6hKwVre2m8VdkDsaNgELHDSqNykcoGLDOobdX
RKG+tggg1bsOnJ/aDcN75faOwKE7dNtLysi/d4UpgMYRzMcxVo8CT1u2ttTbFeBe
iiBYtdPZ1Fcosa8bLKj71LVFQ79+Id13kY0bxXczBM+SL88N5KEOI0fCqd94ysQq
OIY3Ppr2CTNLHl7zZskSTYtqCUe6TeaP6n+YW3VsxKfjlukJRjnVMjwrWQqqPs5n
SxmDRG7iF1YNXltHntK8pslgjQy69oGCsJiqMt3fhRmsF1Nnm/F/JR1oDYVWSJ3y
AKDa+0+pUqFuJRb4KGXAfi6Q6AXEp613LOX1P8psOg3DbE68CCrXXpuoFU9AGkma
XKr8aLf6MKtvj/aeoK/rTRlCVAPXztzfH4iHQq7zSQbJoSv0xORznszgoEXScYsj
Cs/ufky+hb/DEBVb1hhPLIYUMCMx0xuBn7RD7X7OVzyoS1Onv+zu06hfeAK1MVO/
83f4J5mbTh+myhiHwkXA
=i+Iu
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to