It sounds like a bug. Could you create a JIRA and attach a test-case? Colm.
On Tue, Mar 6, 2018 at 8:58 AM, Markus Schulz <[email protected]> wrote: > hello, > > i have implemented a provider based jax-ws service (wsdl first approach) > like: > > @ServiceMode(value = Service.Mode.PAYLOAD) > @WebServiceProvider(wsdlLocation = "KompositService_2.6.1.1.1.wsdl",...) > @MTOM(enabled = true) > public class MyService implements Provider<Source> { > > And my "invoke" method looks similar to: > > Source invoke(Source source) { > MyRequest req = jaxbContext.createUnmarshaller().unmarshal(source, ..) > MyResponse resp = .... > return JAXBSource(jaxbContext.createMarshaller(), resp); > } > > But now i want to attach binary data not inline but with mtom/xop. > > After adding the the @MTOM annotation i got multipart response, but only > with single part. The binary data is still inline. > > (Content-Type: multipart/related; type="application/xop+xml",...) > > I can't find something in the docs for this topic, therefore i did some > try and error... > > I've tried to add an AttachmentMarshaller to my JAXB-Marshaller: > > marshaller.setAttachmentMarshaller(new JAXBAttachmentMarshaller(new > ArrayList<>(), null)); > > After this i got no inline data anymore but the correct > <xop:Include href="cid:...> reference. > > But still only one part was written to the multipart response. No > further binary-attachment added. > > Whats wrong here? > How do i get my attachments written to the multipart response? > > -- > regards > msc > -- Colm O hEigeartaigh Talend Community Coder http://coders.talend.com
