This discussion is archived
1 Reply Latest reply: Nov 15, 2012 10:34 AM by Colm Divilly RSS

Listener 2 RESTful service output is JSON format only???

969593 Newbie
Currently Being Moderated
I have created a Restful service: htmlPage details are as follows:
Template -->
Template: htmlPage
Priority: 0
Entity Tag: None

Resource Handler -->
Method: GET
Source Type: Media Resource
Requires Secure Access: NO

Source:
select 'text/html',
'<html>
<head>
<title>Test Page</title>
</head>
<body>
<div>
<h1>Hello World</h1>
</div>
</body>
</html>' from dual


All I want to do is open a HTML page as I did with the listener 1.1 however the test treats the output as JSON file i.e.

{"items":[{"'text/html'":"text/html","'<html><head><title>testpage</title></head><body><div><h1>helloworld</h1></div></body></html>'":"<html>\r\n<head>\r\n<title>Test Page</title>\r\n</head>\r\n<body>\r\n<div>\r\n<h1>Hello World</h1>\r\n</div>\r\n</body>\r\n</html>"}]}


Is this a bug or can someone shine some light on this behaviour as it worked with Listener 1.1.


Further to this:
Current config is standalone mode and the periodically get a "Error Application with the alias "workspace name" does not exist" error which is resolved with a logging into the listener with sql developer and uploading the config once more. Something tells me this is a bug.

Edited by: 966590 on Oct 19, 2012 12:44 PM

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points