|
[ jetty-Bugs-1033803 ] ThreadPool calls Class.getPackage throwing an NPE: msg#00064java.jetty.general
Bugs item #1033803, was opened at 2004-09-24 14:35 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=107322&aid=1033803&group_id=7322 Category: None Group: None Status: Open Resolution: None Priority: 5 Submitted By: Ben Walding (ben_walding) Assigned to: Nobody/Anonymous (nobody) Summary: ThreadPool calls Class.getPackage throwing an NPE Initial Comment: It looks like the changes made to the ThreadPool about a month ago have some issues with any classloader that doesn't define a Package object for the class (eg. getPackage() returns null). Reading the API definition for getPackage() tends to indicate that it is valid for the Class to return null for getPackage() however this break the new ThreadPool. See following for change in question: http://cvs.sourceforge.net/viewcvs.py/jetty/Jetty/src/org/mortbay/util/ThreadPool.java?r1=1.36&r2=1.37 API definition: /** * Gets the package for this class. The class loader of this class is used * to find the package. If the class was loaded by the bootstrap class * loader the set of packages loaded from CLASSPATH is searched to find the * package of the class. Null is returned if no package object was created * by the class loader of this class. * * <p> Packages have attributes for versions and specifications only if the * information was defined in the manifests that accompany the classes, and * if the class loader created the package instance with the attributes * from the manifest. * * @return the package of the class, or null if no package * information is available from the archive or codebase. */ public Package getPackage() Our usecase? We use classworlds (classworlds.codehaus.org) to launch our jetty server and application from a single jar. At present classworlds doesn't return a Package object (CLASSWORLDS-1 issue in jira.codehaus.org) - although it will one day. This isn't urgent as I'll just revert back to 5.0.RC2 for the time being. It'll be a while before classworlds and maven are all patched up to define a Package, and in my opinion, Jetty should work without getPackage() defined irregardless. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=107322&aid=1033803&group_id=7322 ------------------------------------------------------- This SF.Net email is sponsored by: YOU BE THE JUDGE. Be one of 170 Project Admins to receive an Apple iPod Mini FREE for your judgement on who ports your project to Linux PPC the best. Sponsored by IBM. Deadline: Sept. 24. Go here: http://sf.net/ppc_contest.php
|
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | [ jetty-Bugs-1033766 ] Request and reponse object are not same after dispatch, SourceForge.net |
|---|---|
| Next by Date: | [ jetty-Bugs-1033753 ] j.s.i.query_string should just be that from the URI, SourceForge.net |
| Previous by Thread: | [ jetty-Bugs-1033766 ] Request and reponse object are not same after dispatch, SourceForge.net |
| Next by Thread: | [ jetty-Bugs-1033803 ] ThreadPool calls Class.getPackage throwing an NPE, SourceForge.net |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |