none
Different Function behavior on Kestrel vs IIS 10.0 RRS feed

  • Question

  • I have Java functions originally created / deployed on east US and east US 2 servers. In http responses, the server was always Kestrel.

    I have now deployed some functions in west central US to use 2.0.11888 Runtime. The functions run.

    HOWEVER, the server is now IIS 10.0, and is behaving different when an HTTP Error Code is returned.

    On Kestrel, if I use request.createResponse(HTTP_ERROR_CODE, response) [where response is a Java HashMap], in Postman I see the HTTP error code, AND I see a JSON representation of the contents of "response". That is the behavior I expect and want.

    On IIS 10.0, using exactly the same Java code in functions, Postman does NOT get the JSON representation of the "response" - it gets the HTTP Error Code, and a simple canned text message describing the error. I have not tried all error codes, but 500, 404, and 410 do NOT yield the JSON I expect (and more importantly, the users of the function MUST get).

    For HTTP_OK and HTTP_ACCEPTED, the JSON is returned.

    What is going on with the servers? In production I do expect to start in east US, but I need clarity on this for deployment to other regions.

    Thanks

    EDIT: Referenced Functions are Http triggered.

    "request" above is an HttpRequestMessage<HashMap<String, Object>>

    Functions return HttpResponseMessage<HashMap<String, Object>>


    • Edited by -jack- Tuesday, June 26, 2018 6:32 PM Clarify Function Signature
    Tuesday, June 26, 2018 6:01 PM

Answers

  • Hi Jack,

    This is a known issue with the latest build. Please see announcement for details and workaround.

    thanks,
    David

    • Proposed as answer by David Ebbo Thursday, June 28, 2018 9:23 PM
    • Marked as answer by -jack- Friday, June 29, 2018 12:27 PM
    Thursday, June 28, 2018 9:23 PM