You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cxf.apache.org by "Daniel Kulp (JIRA)" <ji...@apache.org> on 2011/02/03 18:37:29 UTC

[jira] Resolved: (CXF-3305) Request payload as StaxSource: first event is -1

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

Daniel Kulp resolved CXF-3305.
------------------------------

       Resolution: Fixed
    Fix Version/s: 2.3.3
         Assignee: Daniel Kulp

> Request payload as StaxSource: first event is -1
> ------------------------------------------------
>
>                 Key: CXF-3305
>                 URL: https://issues.apache.org/jira/browse/CXF-3305
>             Project: CXF
>          Issue Type: Bug
>          Components: Core
>    Affects Versions: 2.3.1, 2.3.2
>         Environment: Windows
>            Reporter: Andrei Shakirin
>            Assignee: Daniel Kulp
>             Fix For: 2.3.3
>
>         Attachments: HelloWorldService.zip
>
>
> Use case: provider is implements Provider<Source> interface and uses PAYLOAD mode. By request, I get a StaxSource which wrappers the Stax reader.
> If I go through Stax reader the first event type is -1.
> That disturbs, for example, to directly convert stream reader to event reader :
> XMLEventReader reader = inputFactory.createXMLEventReader()
> Exception: 
> Caused by: java.lang.IllegalStateException: Unrecognized event type -1. at com.ctc.wstx.evt.DefaultEventAllocator.allocate(DefaultEventAllocator.java:259))
> As far as I skip first event, code above works.
> Are there any special reasons to put event (-1) on top of reader?

-- 
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira