You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cxf.apache.org by "Bozhidar Bozhanov (JIRA)" <ji...@apache.org> on 2009/10/18 15:54:31 UTC

[jira] Commented: (CXF-2478) Incorrectly removing a parameter from the Message

    [ https://issues.apache.org/jira/browse/CXF-2478?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12767067#action_12767067 ] 

Bozhidar Bozhanov commented on CXF-2478:
----------------------------------------

I commented out all removal and the exception is "wrong number of arguments" This means that the last argument, which has a value of null is to be removed, instead the one with index 0.

I now have an idea - can this be because:
1. The null argument is for something cxf-internal usage
2. It is added when the Wrapper object is constructed (in DocLiteralInInterceptor)
3. As the wrapper parameter has index or 0, the null parameter becomes index 1.
4. But when the wrapped object is 'exploded', the index of the null param should be updated, but instead stays 1. 

> Incorrectly removing a parameter from the Message
> -------------------------------------------------
>
>                 Key: CXF-2478
>                 URL: https://issues.apache.org/jira/browse/CXF-2478
>             Project: CXF
>          Issue Type: Bug
>          Components: Core, JAX-WS Runtime, Service Model, Soap Binding
>    Affects Versions: 2.2.3, 2.1.7, 2.2.4
>         Environment: Tomcat 6.0.18, Windows Server 2003. CXF 2.2.4.
>            Reporter: Bozhidar Bozhanov
>            Priority: Critical
>
> I've been having the following issue for a whole day already, and I'm debugging it: http://www.coderanch.com/t/466933/Web-Services/java/CXF-fails-serve-WebService
> I've got further ahead:
> in WrapperClassInInterceptor there is this code:
> (line 135 onwards)
> newParams = new MessageContentsList(helper.getWrapperParts(wrappedObject));
>                 List<Integer> removes = null;
>                 int count = 0;
>                 for (MessagePartInfo part : messageInfo.getMessageParts()) {
>                     if (Boolean.TRUE.equals(part.getProperty("messagepart.isheader"))) {
>                         MessagePartInfo mpi = wrappedMessageInfo.getMessagePart(part
>                                 .getName());
>                         if (lst.hasValue(mpi)) {
>                             newParams.put(part, lst.get(mpi));
>                         } else if (mpi.getTypeClass() == null) {
>                             if (removes == null) {
>                                 removes = new ArrayList();
>                             }
>                             removes.add(Integer.valueOf(mpi.getIndex()));
>                         }
>                     } else {
>                         ++count;
>                     }
>                 }
> The parameters in "newParams" before the removes are removed are the correct params + one null at the end.
> Then index "1" is removed. BUT the param at Index 1 is correct. So perhaps the index is wrongly calculated. I don't have any more time to dig further into the generation of the index, so I'm just patching my version by commenting-out the removal part. I hope you can give me an update no this. Thanks

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.