problem publishing classic Rest service

Posted by Robert Cohen on 19-Jul-2018 08:45

I have created a classic REST service "MyDataObject" attached to the sports database and set it to Create a Data Object service

there is Appserver class - Customer.cls as generated by creating a Business Entity as a CRUD operation against the Customer table

I used the example "KendoUIGridCRUD.html" and added it to the static directory then modified it to point to the rest service - changed the "dataSource" to ensure the jsdo is "Customer" and also modified the serviceURI and the catalogURIs

serviceURI = "localhost:8980/.../"

// catalogURIs: "localhost:8980/.../MyDataObjectService.json"
catalogURIs: "localhost:8980/.../MyDataObjectService.json"

When I tyr to publish the service the "MyDataObjectService" directory is created in C:\OpenEdge\WRK\tomcat_wrkdir directory but it has no contents

Anny suggestions on what the issue could be

Thanks Robert

Posted by Robert Cohen on 20-Jul-2018 08:39

Sanjeev,

Thanks for this information - i did have the Service URL wrong - missing the "Service" at the end of the name "MyDataObject" - changed to "MyDataObjectService"

I did find a directory under <DLC>\servers\tomcat\webapps\MyDataObjectService but there is only a WEB-INF directory and below that and "adapters" directory and then a "logs" directory with and empty "MyDataObjectService.log" file.

I thought it would deploy to C:\Openedge/Wrk/tomcat_wrkdir\MyDataObjectService" directory

I do see files under <DLC>\servers\tomcat\pdsoe\MyDataObjectService\ including a static directory with my modified html file in it

I can run http://localhost:8980/MyDataObjectService/static/MyDataObjectService.json and see the json file but when I try the  http://localhost:8980/MyDataObjectService/static/Client.html (from the example I was using) I just get a blank page and when I run  http://localhost:8980/MyDataObjectService/static/ClientKendoUIGridCRUD.html  i get an Error - "Error while executing addCatalog() but all of this is better than what I had yesterday

Now to figure out the new issue but it looks like it published this time to some degree - I did not hink it would be under the pdsoe directory under tomcat.

Thanks Robert

Posted by Sanjeva Manchala on 20-Jul-2018 00:40

Hi Ruben,
 
There are two points to be noted here:
  1. When publishing to classic severs, each service is deployed as a separate WebApp. So the Service URL and Catalog URL will be like:
    1. Service URI: http://localhost:8980/<ServiceName>/ (in your case http://localhost:8980/MyDataObjectService)
    2. Catalog URI: http://localhost:8980/<ServiceName>/static/<SerivceName>.json (in your case localhost:8980/.../MyDataObjectService.json)
  2. For Classic servers, the deployed apps will be under the following location:
    1. <DLC>\servers\tomcat\pdsoe (if deployed from PDSOE)
    2. <DLC>\servers\tomcat\webapps (if deployed from other places)

 

Hope this helps,
Sanjeev

All Replies

Posted by Sanjeva Manchala on 20-Jul-2018 00:40

Hi Ruben,
 
There are two points to be noted here:
  1. When publishing to classic severs, each service is deployed as a separate WebApp. So the Service URL and Catalog URL will be like:
    1. Service URI: http://localhost:8980/<ServiceName>/ (in your case http://localhost:8980/MyDataObjectService)
    2. Catalog URI: http://localhost:8980/<ServiceName>/static/<SerivceName>.json (in your case localhost:8980/.../MyDataObjectService.json)
  2. For Classic servers, the deployed apps will be under the following location:
    1. <DLC>\servers\tomcat\pdsoe (if deployed from PDSOE)
    2. <DLC>\servers\tomcat\webapps (if deployed from other places)

 

Hope this helps,
Sanjeev

Posted by Robert Cohen on 20-Jul-2018 08:39

Sanjeev,

Thanks for this information - i did have the Service URL wrong - missing the "Service" at the end of the name "MyDataObject" - changed to "MyDataObjectService"

I did find a directory under <DLC>\servers\tomcat\webapps\MyDataObjectService but there is only a WEB-INF directory and below that and "adapters" directory and then a "logs" directory with and empty "MyDataObjectService.log" file.

I thought it would deploy to C:\Openedge/Wrk/tomcat_wrkdir\MyDataObjectService" directory

I do see files under <DLC>\servers\tomcat\pdsoe\MyDataObjectService\ including a static directory with my modified html file in it

I can run http://localhost:8980/MyDataObjectService/static/MyDataObjectService.json and see the json file but when I try the  http://localhost:8980/MyDataObjectService/static/Client.html (from the example I was using) I just get a blank page and when I run  http://localhost:8980/MyDataObjectService/static/ClientKendoUIGridCRUD.html  i get an Error - "Error while executing addCatalog() but all of this is better than what I had yesterday

Now to figure out the new issue but it looks like it published this time to some degree - I did not hink it would be under the pdsoe directory under tomcat.

Thanks Robert

Posted by Robert Cohen on 20-Jul-2018 08:42

Sanjeev,

checked the catalogURI entry and was missing the service when fixed the  localhost:8980/.../ClientKendoUIGridCRUD.html worked

Thanks

Posted by Sanjeva Manchala on 21-Jul-2018 12:04

Hi Robert,
 
I’m glad that it worked. If it solves your problem, mark the question as answered, so that it can be useful for someone next time when they face the same problem.
 
Thanks,
Sanjeev
 

Posted by Robert Cohen on 23-Jul-2018 07:42

Thanks Sanjeev
 
I will flag / mark the response
 
ROBERT COHEN
Manager of IT and Logistics
DYNACAST LTD
 
P:  +1 705.748-9522 Ext 2454
 
710 Neal Drive
Peterborough, ON K9J 6X7
CANADA
 

Posted by Siliot Mawire on 24-Jul-2018 00:18

How can I get page numbering because everytime I direct output to a named stream I do not get the page number?


This thread is closed