DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=34959>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=34959

           Summary: Overloaded operations throw "wrong number of parameters"
                    exception
           Product: Commons
           Version: 1.1 Final
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: blocker
          Priority: P1
         Component: Modeler
        AssignedTo: commons-dev@jakarta.apache.org
        ReportedBy: [EMAIL PROTECTED]
                CC: [EMAIL PROTECTED]


If a model MBean has an overloaded operation (an operation with two or more
signatures), only one of them can be successfully invoked at runtime. Invoking
others will throw "Wrong number of parameters" exception.

Here's what I've found out about the causing of the problem:

Class org.apache.commons.modeler.BaseModelMBean internally stores and caches
operations in a hashmap. The key to the hashmap is the operation name.
Therefore, if an operation has multiple signatures, only one of them (the first
one loaded) is stored in the hashmap. Invoking the same method with a different
signature will cause "wrong number of parameters" exception.

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to