Axis2
  1. Axis2
  2. AXIS2-5247

REST functionality is broken in current trunk

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.6.1, 1.7.0
    • Fix Version/s: 1.6.2, 1.7.0
    • Component/s: kernel
    • Labels:
      None

      Description

      Axis2 REST functionality is not working as expected in current trunk. I tried a sample with a wsdl2 where I define whttp:location in HttpBinding to access the service operations in there. But im getting EPR not found for operation error in the response. For the attached sample i have defined the whttp:location for "getPrice" operation as whttp:location="price/

      {symbol}

      "

      Steps to reproduce:
      1. Deploy the attached service
      2. Access http://localhost:8080/axis2/services/StockQuoteService/getPrice?symbol=IBM, it will return a value
      3. Access http://localhost:8080/axis2/services/StockQuoteService/price/IBM, it will return an EPR not found error.

      1. AXIS2-5247.patch
        18 kB
        Kishanthan Thangarajah
      2. StockQuoteService.aar
        4 kB
        Kishanthan Thangarajah

        Activity

        Hide
        Kishanthan Thangarajah added a comment -

        After reading this [1] tutorial, I tried this sample on Axis2 1.4.1. The above works without any errors in there.

        Thanks,
        Kishanthan.

        [1] http://wso2.org/library/3726

        Show
        Kishanthan Thangarajah added a comment - After reading this [1] tutorial, I tried this sample on Axis2 1.4.1. The above works without any errors in there. Thanks, Kishanthan. [1] http://wso2.org/library/3726
        Hide
        Kishanthan Thangarajah added a comment -

        I'm adding fix for this. Basically what i did was i compared the current trunk with 1.4.1 and implemented the needed changes to trunk. Introduced a method "inferEndpoint" which was missing in current trunk. Based on this fix I also added a integration test case to test the REST functionality of Axis2.

        Show
        Kishanthan Thangarajah added a comment - I'm adding fix for this. Basically what i did was i compared the current trunk with 1.4.1 and implemented the needed changes to trunk. Introduced a method "inferEndpoint" which was missing in current trunk. Based on this fix I also added a integration test case to test the REST functionality of Axis2.
        Hide
        Sagara Gunathunga added a comment -

        Above feature is developed on 1.4 branch and shipped with 1.4.1 version but never merge to trunk. I will review your patch and apply.

        Show
        Sagara Gunathunga added a comment - Above feature is developed on 1.4 branch and shipped with 1.4.1 version but never merge to trunk. I will review your patch and apply.
        Hide
        Sagara Gunathunga added a comment -

        Patch available on r1291158.

        Show
        Sagara Gunathunga added a comment - Patch available on r1291158.
        Hide
        Hudson added a comment -

        Integrated in Axis2 #1269 (See https://builds.apache.org/job/Axis2/1269/)
        Applied patch for AXIS2-5247. (Revision 1291158)

        Result = ABORTED
        sagara :
        Files :

        • /axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/rest
        • /axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/rest/RESTfulServiceTest.java
        • /axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/rest/Stock.java
        • /axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/rest/StockService.java
        • /axis/axis2/java/core/trunk/modules/kernel/src/org/apache/axis2/description/WSDL2Constants.java
        • /axis/axis2/java/core/trunk/modules/kernel/src/org/apache/axis2/dispatchers/RequestURIBasedServiceDispatcher.java
        • /axis/axis2/java/core/trunk/modules/kernel/src/org/apache/axis2/namespace/Constants.java
        • /axis/axis2/java/core/trunk/modules/kernel/src/org/apache/axis2/wsdl/WSDLUtil.java
        Show
        Hudson added a comment - Integrated in Axis2 #1269 (See https://builds.apache.org/job/Axis2/1269/ ) Applied patch for AXIS2-5247 . (Revision 1291158) Result = ABORTED sagara : Files : /axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/rest /axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/rest/RESTfulServiceTest.java /axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/rest/Stock.java /axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/rest/StockService.java /axis/axis2/java/core/trunk/modules/kernel/src/org/apache/axis2/description/WSDL2Constants.java /axis/axis2/java/core/trunk/modules/kernel/src/org/apache/axis2/dispatchers/RequestURIBasedServiceDispatcher.java /axis/axis2/java/core/trunk/modules/kernel/src/org/apache/axis2/namespace/Constants.java /axis/axis2/java/core/trunk/modules/kernel/src/org/apache/axis2/wsdl/WSDLUtil.java

          People

          • Assignee:
            Kishanthan Thangarajah
            Reporter:
            Kishanthan Thangarajah
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development