DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=6090>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=6090

Listener not instantiated in tld file

           Summary: Listener not instantiated in tld file
           Product: Tomcat 4
           Version: 4.0.1 Final
          Platform: PC
        OS/Version: Windows NT/2K
            Status: NEW
          Severity: Normal
          Priority: Other
         Component: Unknown
        AssignedTo: [EMAIL PROTECTED]
        ReportedBy: [EMAIL PROTECTED]


I have a tld file which is in WEB-INF (called messageboard.tld). This has a 
<listener> element

<listener>
    <listener-
class>com.develop.ejsp.listeners.IntializeDatabaseConnection</listener-class>
  </listener>

If I place this in the web.xml file then it is instantiated and works fine. In 
the tld file however it's not picked up.

According to the spec:

JSP.7.1.2.2 Event Listeners
A tag library may include classes that are event listeners (see the Servlet 2.3
specification). The listeners classes are listed in the tag library descriptor 
and the
JSP container automatically instantiates them and registers them. A container is
required to locate all TLD files (see Section JSP.7.3.1 ...)

JSP.7.3.1 Identifying Tag Library Descriptors
Tag library descriptor files have names that use the extension “.tld”, and the
extension indicates a tag library descriptor file. 
...
When deployed directly into a web application, the tag library
descriptor files must always be in the WEB-INF directory, or some subdirectory
of it.

My deployment seems OK, the tld is parsed OK. Is this a bug?

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to