[jboss-jira] [JBoss JIRA] (AS7-1562) Ability to add custom java url protocol handler

David Lloyd (JIRA) jira-events at lists.jboss.org
Thu Feb 9 12:28:51 EST 2012


     [ https://issues.jboss.org/browse/AS7-1562?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

David Lloyd closed AS7-1562.
----------------------------

    Resolution: Rejected


This wasn't really a bug, more of a forum question.
                
> Ability to add custom java url protocol handler
> -----------------------------------------------
>
>                 Key: AS7-1562
>                 URL: https://issues.jboss.org/browse/AS7-1562
>             Project: Application Server 7
>          Issue Type: Feature Request
>          Components: Server
>         Environment: JBoss EAP 5.1
>            Reporter: Brad Maxwell
>              Labels: URLStreamHandlerFactory, custom, handler, java, url
>
> Looking in the source code for org.jboss.system.server.ServerImpl [1]
> - this class is setting the URLStreamHandlerFactory and also calling preload and specifying the java.protocol.hanlder.pkgs. 
> URL.setURLStreamHandlerFactory(new URLStreamHandlerFactory());
>   
> // Preload JBoss URL handlers
> URLStreamHandlerFactory.preload()
> ...
> System.setProperty("java.protocol.handler.pkgs", handlerPkgs);
> So it looks like there isn't a way to change the URLStreamHandlerFactory that is used and the instance of URLStreamHandlerFactory created is not accessible to add new protocols.
> Is there anything I'm missing, it looks like this should be a feature, I've found a few posts on the net mentioning other app servers allow you to specify the Factory class to use.
> The exception is:
> java.net.MalformedURLException: unknown protocol: classpath
> [1] http://anonsvn.jboss.org/repos/jbossas/tags/JBPAPP_4_3_0_GA_CP08/system/src/main/org/jboss/system/server/ServerImpl.java
> [2] http://anonsvn.jboss.org/repos/common/common-core/tags/jboss-common-core-2.0.4.GA/src/main/java/org/jboss/net/protocol/URLStreamHandlerFactory.java
> [3] http://community.jboss.org/message/288238?tstart=0

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the jboss-jira mailing list