Uploaded image for project: 'Apache Flex'
  1. Apache Flex
  2. FLEX-23128

RPC does not support method overloading by name

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • Adobe Flex SDK 3.4 (Release)
    • None
    • RPC: General
    • None
    • Affected OS(s): All OS Platforms
      Affected OS(s): All OS Platforms
      Language Found: English

    Description

      Steps to reproduce:
      1 - Create a WebService or a RemoteObject that maps a service with method overloading, with different argument types and/or count
      2 - Try to call one version of overloaded method
      3 - If you are lucky enough, you'll hit the right one, if not, you'll get an error of incorrect arguments array (missing args, for instance)

      Example, with Confluence Wiki SOAP API:

      There are 2 versions of getPage, defined in this order:
      getPage(token:String, spaceKey:String, pageTitle:String) : RemotePage
      getPage(token:String, pageId:int) : RemotePage

      Try to call the getPage(token,id) method, and you will hit the other one, and you'll get an exception for invalid arguments

      The problem will be exactly the same with RemoteObjects, and the cause is that there is nothing to manage arguments internally, and the getOperation method
      or RPC services does not take arguments list into account.

      Workaround (if any):

      There is one workaround; not cool, which is to monkey-patch all mx.rpc.WSDL package classes, and to add an automatic numerotation on operation names to avoid collisions in the internal operations tables of these classes.
      It tried it, it works, but I don't like it

      Attachments

        Activity

          People

            Unassigned Unassigned
            adobejira Adobe JIRA
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated: