Use well-known Status enumeration 08/97108/1
authorRobert Varga <robert.varga@pantheon.tech>
Mon, 9 Aug 2021 13:08:01 +0000 (15:08 +0200)
committerRobert Varga <robert.varga@pantheon.tech>
Mon, 9 Aug 2021 13:08:01 +0000 (15:08 +0200)
commitfdf3ba286a9fd8312abf6e4e5547fe8004987d61
treef701c27a4f4c5387af665ffd68f43a1e50ab4adf
parent916a6a5cb7e3ac5148f9cf6bb1a24bf7298ea9f6
Use well-known Status enumeration

Response.status() can be used with an int, but that ends up walking all
Status.values() in an attempt to find the corresponding constant. While
we end up hitting the first element, use Status.OK explicitly to speed
things up a bit.

Change-Id: I7c72a88602c95ec4c7274369a9e5c613c3ce3b9b
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
restconf/restconf-nb-rfc8040/src/main/java/org/opendaylight/restconf/nb/rfc8040/rests/services/impl/RestconfDataServiceImpl.java