Service Virtualization

  • 1.  404 Error While Running REST Service in SOAP UI

    Posted Jun 06, 2017 02:21 AM

    Hi, I am getting error while running REST Put Method in SOAP UI. Kindly let me know how to resolve this issue. Iam also attaching screenshot and files that's used.

    Attachment(s)

    zip
    Modified PUT.zip   554 B 1 version


  • 2.  Re: 404 Error While Running REST Service in SOAP UI

    Posted Jun 06, 2017 03:18 AM

    Hello, 

    404 not round means requested endpoint URL was not found on the service you requested.. in your case localhost. In screenshot it shows "lo" missing in localhost:8001

     Also not sure if you have hosted this service in your local server ?

    Recheck and confirm if that work for you.

     

    Thanks,
    Rajesh k Singh



  • 3.  Re: 404 Error While Running REST Service in SOAP UI
    Best Answer

    Posted Jun 06, 2017 10:52 AM

    The 404 you are seeing in your attached screen shot is called a Service Image Not Found Response. You see this response message when the service is unable to match on the Operation and/or Arguments in the VSI. This message is an indicator that either the operation passed from SoapUI is not what the service is expecting or arguments in the operation do not match up to arguments on the incoming request for a matching Operation.

     

    I believe you have an error in your SoapUI setup.  In your graphic, you have /rest-example/control/users/save/ configured as both an endpoint and as a resource.

    To test this theory, start your VSM in ITR mode within the Workstation.

    Send your request from SoapUI to the service running in ITR mode.

    When the LISTEN step finishes, CLICK the Events tab and review the actual incoming request including Method, URI, Operation, and input body.  

    Here is an example when the resource and endpoint both contain the URI. Notice that the URI doubles up. Unless you have an operation with the URI repeated twice, your service will not select the correct answer.

     

    Try your request again after removing the URI from the endpoint OR leave it in the endpoint and remove it from the Resource.

    Run in ITR mode again and check the Events tab. Then, let the service finish to the Responder step.

    After correcting the URI, you output in SoapUI should look more like this...

    The attached VSM and VSI worked using the information you provided. I added the REST DPH to the VSM. OOTB the R/R Pair recorder only selected JSON 2.0. 

    Attachment(s)



  • 4.  Re: 404 Error While Running REST Service in SOAP UI

    Posted Jun 13, 2017 04:58 AM

    Thank you very much Joel.
    Its working fine.