You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cxf.apache.org by "Iman Rahmatizadeh (JIRA)" <ji...@apache.org> on 2008/08/09 06:52:44 UTC

[jira] Created: (CXF-1740) IndexOutOfBoundsException in MessageContentsList

IndexOutOfBoundsException in MessageContentsList 
-------------------------------------------------

                 Key: CXF-1740
                 URL: https://issues.apache.org/jira/browse/CXF-1740
             Project: CXF
          Issue Type: Bug
    Affects Versions: 2.1.1
            Reporter: Iman Rahmatizadeh
         Attachments: testcase.zip

In HolderInInterceptor, this part of code

            for (MessagePartInfo part : parts) {
                if (part.getIndex() != 0 && part.getTypeClass() != null) {
                    Holder holder = (Holder)outHolders.get(part.getIndex() - 1);
                    holder.value = inObjects.get(part);
                    inObjects.put(part, holder);
                }
            }

the code calls outHolders.get(part.getIndex() - 1), but when calling inObjects.get(part) on the next line it goes to this method in MessageContentsList :
    public Object get(MessagePartInfo key) {
        Object o = super.get(key.getIndex());
        return o == REMOVED_MARKER ? null : o;
    }

where it calls super.get(key.getIndex()),so when the index is 8 in a list of size 8, I get this exception. (note the -1 at first, and nothing in the latter method, although both are of type list)
Previously when I configured the bus & client in java I hadn't this problem, but now I'm doing it through Spring xml files and I guess I've left something out.

Attached is a testcase with the working and not working scenario. The library files and versions used are in the build.xml file 


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


[jira] Commented: (CXF-1740) IndexOutOfBoundsException in MessageContentsList

Posted by "Daniel Kulp (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CXF-1740?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12621465#action_12621465 ] 

Daniel Kulp commented on CXF-1740:
----------------------------------


Yea....   Looking at the spec, this will NEVER work in "code first" cases.    In rpc/lit, the namespace of the wrapper element is from the <soap:body namespace="..."/> tag.   However, NOWHERE in the generated code is that namespace saved.   I even checked the spec on that.   :-(

Thus, I would suggest changing the spring config for the "doesn't work" case to use the wsdl.   Specify a wsdlLocation attribute as well as the serviceName and endpointName for the service/port from the wsdl.

That said, there definitely is a code generation problem as well that I'm working on.   It just won't fix your issue.  :-(

> IndexOutOfBoundsException in MessageContentsList 
> -------------------------------------------------
>
>                 Key: CXF-1740
>                 URL: https://issues.apache.org/jira/browse/CXF-1740
>             Project: CXF
>          Issue Type: Bug
>    Affects Versions: 2.1.1
>            Reporter: Iman Rahmatizadeh
>         Attachments: testcase.zip
>
>
> In HolderInInterceptor, this part of code
>             for (MessagePartInfo part : parts) {
>                 if (part.getIndex() != 0 && part.getTypeClass() != null) {
>                     Holder holder = (Holder)outHolders.get(part.getIndex() - 1);
>                     holder.value = inObjects.get(part);
>                     inObjects.put(part, holder);
>                 }
>             }
> the code calls outHolders.get(part.getIndex() - 1), but when calling inObjects.get(part) on the next line it goes to this method in MessageContentsList :
>     public Object get(MessagePartInfo key) {
>         Object o = super.get(key.getIndex());
>         return o == REMOVED_MARKER ? null : o;
>     }
> where it calls super.get(key.getIndex()),so when the index is 8 in a list of size 8, I get this exception. (note the -1 at first, and nothing in the latter method, although both are of type list)
> Previously when I configured the bus & client in java I hadn't this problem, but now I'm doing it through Spring xml files and I guess I've left something out.
> Attached is a testcase with the working and not working scenario. The library files and versions used are in the build.xml file 

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


[jira] Updated: (CXF-1740) IndexOutOfBoundsException in MessageContentsList

Posted by "Iman Rahmatizadeh (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CXF-1740?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Iman Rahmatizadeh updated CXF-1740:
-----------------------------------

    Attachment: testcase.zip

> IndexOutOfBoundsException in MessageContentsList 
> -------------------------------------------------
>
>                 Key: CXF-1740
>                 URL: https://issues.apache.org/jira/browse/CXF-1740
>             Project: CXF
>          Issue Type: Bug
>    Affects Versions: 2.1.1
>            Reporter: Iman Rahmatizadeh
>         Attachments: testcase.zip
>
>
> In HolderInInterceptor, this part of code
>             for (MessagePartInfo part : parts) {
>                 if (part.getIndex() != 0 && part.getTypeClass() != null) {
>                     Holder holder = (Holder)outHolders.get(part.getIndex() - 1);
>                     holder.value = inObjects.get(part);
>                     inObjects.put(part, holder);
>                 }
>             }
> the code calls outHolders.get(part.getIndex() - 1), but when calling inObjects.get(part) on the next line it goes to this method in MessageContentsList :
>     public Object get(MessagePartInfo key) {
>         Object o = super.get(key.getIndex());
>         return o == REMOVED_MARKER ? null : o;
>     }
> where it calls super.get(key.getIndex()),so when the index is 8 in a list of size 8, I get this exception. (note the -1 at first, and nothing in the latter method, although both are of type list)
> Previously when I configured the bus & client in java I hadn't this problem, but now I'm doing it through Spring xml files and I guess I've left something out.
> Attached is a testcase with the working and not working scenario. The library files and versions used are in the build.xml file 

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


[jira] Commented: (CXF-1740) IndexOutOfBoundsException in MessageContentsList

Posted by "Daniel Kulp (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CXF-1740?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12621147#action_12621147 ] 

Daniel Kulp commented on CXF-1740:
----------------------------------

Haven't run it yet, but it looks like a code generation problem.

In the "working" case, it's using the wsdl.   In the non-working case, it's not.

It looks like the @SOAPBinding annotation is not getting the style=RPC thing set so it's attempting a doc/lit thing which is definitely kind of mixed up, I think.   Will dig in more on monday.



> IndexOutOfBoundsException in MessageContentsList 
> -------------------------------------------------
>
>                 Key: CXF-1740
>                 URL: https://issues.apache.org/jira/browse/CXF-1740
>             Project: CXF
>          Issue Type: Bug
>    Affects Versions: 2.1.1
>            Reporter: Iman Rahmatizadeh
>         Attachments: testcase.zip
>
>
> In HolderInInterceptor, this part of code
>             for (MessagePartInfo part : parts) {
>                 if (part.getIndex() != 0 && part.getTypeClass() != null) {
>                     Holder holder = (Holder)outHolders.get(part.getIndex() - 1);
>                     holder.value = inObjects.get(part);
>                     inObjects.put(part, holder);
>                 }
>             }
> the code calls outHolders.get(part.getIndex() - 1), but when calling inObjects.get(part) on the next line it goes to this method in MessageContentsList :
>     public Object get(MessagePartInfo key) {
>         Object o = super.get(key.getIndex());
>         return o == REMOVED_MARKER ? null : o;
>     }
> where it calls super.get(key.getIndex()),so when the index is 8 in a list of size 8, I get this exception. (note the -1 at first, and nothing in the latter method, although both are of type list)
> Previously when I configured the bus & client in java I hadn't this problem, but now I'm doing it through Spring xml files and I guess I've left something out.
> Attached is a testcase with the working and not working scenario. The library files and versions used are in the build.xml file 

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


[jira] Resolved: (CXF-1740) IndexOutOfBoundsException in MessageContentsList

Posted by "Daniel Kulp (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CXF-1740?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Daniel Kulp resolved CXF-1740.
------------------------------

       Resolution: Won't Fix
    Fix Version/s: Invalid
         Assignee: Daniel Kulp


Not something that we can fix.   Spec doesn't provide a way to fix it.   There is a workaround though (use the wsdl)

> IndexOutOfBoundsException in MessageContentsList 
> -------------------------------------------------
>
>                 Key: CXF-1740
>                 URL: https://issues.apache.org/jira/browse/CXF-1740
>             Project: CXF
>          Issue Type: Bug
>    Affects Versions: 2.1.1
>            Reporter: Iman Rahmatizadeh
>            Assignee: Daniel Kulp
>             Fix For: Invalid
>
>         Attachments: testcase.zip
>
>
> In HolderInInterceptor, this part of code
>             for (MessagePartInfo part : parts) {
>                 if (part.getIndex() != 0 && part.getTypeClass() != null) {
>                     Holder holder = (Holder)outHolders.get(part.getIndex() - 1);
>                     holder.value = inObjects.get(part);
>                     inObjects.put(part, holder);
>                 }
>             }
> the code calls outHolders.get(part.getIndex() - 1), but when calling inObjects.get(part) on the next line it goes to this method in MessageContentsList :
>     public Object get(MessagePartInfo key) {
>         Object o = super.get(key.getIndex());
>         return o == REMOVED_MARKER ? null : o;
>     }
> where it calls super.get(key.getIndex()),so when the index is 8 in a list of size 8, I get this exception. (note the -1 at first, and nothing in the latter method, although both are of type list)
> Previously when I configured the bus & client in java I hadn't this problem, but now I'm doing it through Spring xml files and I guess I've left something out.
> Attached is a testcase with the working and not working scenario. The library files and versions used are in the build.xml file 

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