[jboss-jira] [JBoss JIRA] (JBVFS-206) [GSS](7.1.z) URL.getContent() returns VirtualFile instead of ImageProducer
Tomas Hofman (JIRA)
issues at jboss.org
Wed Jul 18 04:53:00 EDT 2018
[ https://issues.jboss.org/browse/JBVFS-206?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13607338#comment-13607338 ]
Tomas Hofman commented on JBVFS-206:
------------------------------------
{{java.net.URLConnection#getContent()}} specifies that a content handler determined by the connection's contentType should be called to produce the content. {{VirtualFileURLConnection}} doesn't call any content handler and always returns {{VirtualFile}} instead. That leads to different object types being returned when called from a Wildfly deployment as opposed to clean java environment and possibly other application servers.
> [GSS](7.1.z) URL.getContent() returns VirtualFile instead of ImageProducer
> --------------------------------------------------------------------------
>
> Key: JBVFS-206
> URL: https://issues.jboss.org/browse/JBVFS-206
> Project: JBoss VFS
> Issue Type: Bug
> Affects Versions: 3.2.12.Final
> Environment: Windows XP
> Reporter: Tomas Hofman
> Assignee: Tomas Hofman
>
> URL.getContent() behaves differently within JBoss than it does in a normal JVM. In our case, when a jar is used in a normal JVM, URL.getContent() returns an ImageProducer. When the same jar is used from within JBoss, a VirtualFile is returned which then causes a ClassCastException.
> Note: This worked fine in JBoss 4.2.3.GA.
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
More information about the jboss-jira
mailing list