Uploaded image for project: 'OASIS Open Data Protocol (OData) TC'
  1. OASIS Open Data Protocol (OData) TC
  2. ODATA-440

Specify response for function or action that returns a single null value

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: V4.0_CSD01
    • Fix Version/s: V4.0_CSD02
    • Component/s: Protocol
    • Labels:
      None
    • Environment:

      [Applied]

      Description

      With ODATA-412 we decided that a null value has no "stand-alone" representation and instead requests to resource that has the null value return 404 Not Found.

      We did not consider actions and functions that return a single value.

      For functions it would be somewhat surprising if they would return 404 No Content if the result for a value combination is null. Especially if the function is composable and composing another function that takes this null value and produces a result from it would respond with 200 OK:

      GET ~/Foo(1) --> 404 Not Found
      GET ~/Foo(1)/Bar(2) --> 200 OK

      Also we already define that actions that do not declare a return type respond with 204 OK, and having "sometimes no result" work differently from "always no result" seems odd.

        Attachments

          Activity

            People

            • Assignee:
              handl Ralf Handl
              Reporter:
              handl Ralf Handl
            • Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: