Skip to Main Content

ORDS, SODA & JSON in the Database

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

ORDS 18.3 on Tomcat 8.5: always chunked response from RESTful services?

RSa-DevMar 7 2019 — edited Mar 8 2019

My setup is APEX 18.2 + ORDS 18.3.0.

I tried to use APEX_WEB_SERVICE.make_rest_request on Oracle-provided sample of RESTful service, HR:

Here is my request:

GET http://127.0.0.1:8080/ords/{workspace}/hr/employees/7369 HTTP/1.1
Content-Length: 2
Connection: Close
Host: 127.0.0.1:8080

Response from ORDS in standalone mode is JSON string good for parsing by APEX_JSON.parse:

HTTP/1.1 200 OK

Connection: close

Date: Thu, 07 Mar 2019 07:10:13 GMT

Content-Type: application/json

ETag: "R4HKU3GUa8tAcm3DixE9lWoauhYpGJRGPMhvQIWDihlVUvRMnumFegkZ18F8m/gaeFxoR4hfmF9UeGfiuTOa7A=="

{"empno":7369,"ename":"SMITH","job":"CLERK","mgr":7902,"hiredate":"1980-12-16T21:00:00Z","sal":800,"comm":null,"deptno":20}

Responce from ORDS deployed on Tomcat 8.5 always have "Transfer-Encoding: chunked", even for tiny size of response bodies:

HTTP/1.1 200

ETag: "R4HKU3GUa8tAcm3DixE9lWoauhYpGJRGPMhvQIWDihlVUvRMnumFegkZ18F8m/gaeFxoR4hfmF9UeGfiuTOa7A=="

Content-Type: application/json

Transfer-Encoding: chunked

Date: Thu, 07 Mar 2019 06:31:44 GMT

7b
{"empno":7369,"ename":"SMITH","job":"CLERK","mgr":7902,"hiredate":"1980-12-16T21:00:00Z","sal":800,"comm":null,"deptno":20}
0

Tomcat works in default config - as installed. According Tomcat docs it should not use Chunked Encoding for small HTTP messages.

Maybe this is an ORDS issue?

Comments
Post Details
Added on Mar 7 2019
3 comments
579 views