On Fri, May 21, 2010 at 3:14 PM, Gregor Kiddie
<[email protected]> wrote:
> Ok, forget about this one, it missing the sca namespace.
>
>
>
> However I copied it from Tuscany In Action, so I’m blaming Simon anyway ;)
>
>
>
> Gk.
>
>
>
> From: Gregor Kiddie [mailto:[email protected]]
> Sent: 21 May 2010 14:10
> To: [email protected]
> Subject: Stream Closed when parsing definitions.xml
>
>
>
> I ran into this while adding in a policy for authorisation to a binding.ws
>
> Everything was running fine until adding the requires into the composite,
> and the definitions.xml to satisfy it.
>
> Version 1.6
>
>
>
> Definitions.xml
>
> <?xml version="1.0" encoding="UTF-8"?>
>
> <definitions xmlns="http://www.osoa.org/xmlns/sca/1.0";
>
>                    xmlns:tuscany="http://tuscany.apache.org/xmlns/sca/1.0";
>
>                    targetNamespace="com.mycompany.myproduct.policy" >
>
>
>
>       <policySet name="MyCompanyPolicySet" provides="authentication"
> appliesTo="sca:binding.ws">
>
>             <tuscany:basicAuthentication>
>
>                   <tuscany:userName>someusername</tuscany:userName>
>
>                   <tuscany:password>some-password</tuscany:password>
>
>             </tuscany:basicAuthentication>
>
>       </policySet>
>
> </definitions>
>
>
>
> The exception is
>
>
>
> Caused by: java.io.IOException: Stream closed
>
>                 at java.io.BufferedInputStream.getBufIfOpen(Unknown Source)
>
>                 at java.io.BufferedInputStream.fill(Unknown Source)
>
>                 at java.io.BufferedInputStream.read(Unknown Source)
>
>                 at
> com.sun.org.apache.xerces.internal.impl.XMLEntityManager$RewindableInputStream.read(Unknown
> Source)
>
>                 at
> com.sun.org.apache.xerces.internal.impl.XMLEntityManager.setupCurrentEntity(Unknown
> Source)
>
>
>
> Take out the file (or rename it ) and comment out the requires in the
> composite makes it work again.
>
>
>
> Does the policy stuff require a different XML parser?
>
>
>
> Gk.

Thanks Gregor;-) I'll fix the text.

Simon

-- 
Apache Tuscany committer: tuscany.apache.org
Co-author of a book about Tuscany and SCA: tuscanyinaction.com

Reply via email to