Hi,
I have a hana xsjs script that that fails in connecting to a IoT service running in the same account on the HCP.
var dest = $.net.http.readDestination("Demo_Iot.Services", "IoT");
var req = new $.web.WebRequest($.net.http.POST,"/com.sap.iotservices.mms/v1/api/http/push/xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx");
output = output + req.path + "<br>";
var client = new $.net.http.Client();
client.request(req, dest);
var response = client.getResponse();
output = output + response.body;
The IoT.xshttpsdest file contains:
host = "iotmmsxxxxxxxx.us1.hana.ondemand.com";
port = 443;
description = "IOT Push Service";
pathPrefix = "";
authType = none;
useProxy = false;
proxyHost = "";
proxyPort = 0;
timeout = 0;
on calling client.request(req, dest);
we get the following error :
HttpClient.request: request failed: unable to establish connection to iotmmsxxxxxxxx.us1.hana.ondemand.com:443 - IPcon: connection to host failed!
Does someone know what I am missing ?
Thanks.
Andre