[ 
https://issues.apache.org/jira/browse/FEDIZ-161?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Colm O hEigeartaigh closed FEDIZ-161.
-------------------------------------

> FederationConfigImpl.init() calls loadConfig(File) which fails for war files 
> with special characters in its name
> ----------------------------------------------------------------------------------------------------------------
>
>                 Key: FEDIZ-161
>                 URL: https://issues.apache.org/jira/browse/FEDIZ-161
>             Project: CXF-Fediz
>          Issue Type: Bug
>          Components: Plugin
>    Affects Versions: 1.2.2
>            Reporter: Marc Calello
>            Assignee: Colm O hEigeartaigh
>             Fix For: 1.2.3, 1.3.1
>
>
> If the fediz_config.xml file resides within a war file with special 
> characters in its name, like the hash (#) character, used in Tomcat's war 
> naming convention, (e.g., example-app##1.0.1.war), the following exception is 
> thrown at startup:
> java.io.FileNotFoundException: The system cannot find the file specified
>       at 
> com.sun.xml.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal0(UnmarshallerImpl.java:221)
>       at 
> com.sun.xml.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal(UnmarshallerImpl.java:190)
>       at 
> javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:157)
>       at 
> javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:162)
>       at 
> javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:171)
>       at 
> javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:189)
>       at 
> org.apache.cxf.fediz.core.config.FedizConfigurator.loadConfig(FedizConfigurator.java:43)
>       at 
> org.apache.cxf.fediz.spring.FederationConfigImpl.init(FederationConfigImpl.java:65)
> This is related to a known issue with the JAXB UnmarshallerImpl:
> https://community.oracle.com/thread/1626574?start=0&tstart=0
> This could be resolved by changing the following line in the loadConfig(File) 
> method to implement the suggestion from the Oracle thread above from:
> rootConfig = (FedizConfig) getJaxbContext().createUnmarshaller().unmarshal(f);
> to:
> rootConfig = (FedizConfig) 
> getJaxbContext().createUnmarshaller().unmarshal(new FileInputStream(f));



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to