on 03-19-2014 3:31 PM
Hi community,
i started to use the XS Engine today and i'm getting an error when trying to send a request to a external webservice:
"
Found the following errors:
===========================
Error: HttpClient.request: request failed. The following error occured: unable to establish connection to http://gt-systems.de:80 - internal error code: resolving DNS host name failed (line 8 position 0 in /webservice/test.xsjs)
"
For testing, i wrote a very simple script on my webserver that just returns you the value of the parameter "val".
http://gt-systems.de/test.php?val=thisisatest
First i thought the error could be caused by the cloudshare server, but when i try it on terminal with wget it works perfect:
hanacloud:/tmp/test # wget http://gt-systems.de/test.php?val=thisisatest
--2014-03-19 08:08:04-- http://gt-systems.de/test.php?val=thisisatest
Resolving gt-systems.de... 109.73.52.91
Connecting to gt-systems.de|109.73.52.91|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 11 [text/html]
Saving to: `test.php?val=thisisatest'
100%[======================================>] 11 --.-K/s in 0s
2014-03-19 08:08:05 (1.40 MB/s) - `test.php?val=thisisatest' saved [11/11]
So i think there is some trouble with HANA.
At least my httpdest:
host = "http://gt-systems.de";
port = 80;
description = "test case";
useSSL = false;
pathPrefix = "/test.php";
authType = none;
useProxy = false;
proxyHost = "";
proxyPort = 0;
timeout = 0;
and xsjs:
$.response.contentType = "text/plain";
var dest = $.net.http.readDestination("webservice", "test");
var client = new $.net.http.Client();
var req = new $.web.WebRequest($.net.http.GET, "?val=bla");
client.request(req, dest);
var response = client.getResponse();
$.response.setBody(response);
So what i'm doing wrong? Thanks a lot for your help.
Please give the proxy details, it shoud work.
useProxy = true;
proxyHost = "xxx.xxxx.sap.corp";
proxyPort = xxxx;
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Adam,
Try appending the Instance number to your port in XS properties.
Right click on HANA node -> Properties -> XS properties: hostname:80<instancenumber>
Regards
Raj
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
i checked with 8000, changed the port on HANA server to 80 and also tried with ip address, but still the DNS name cannot be resolved.
Is there maybe kind of a restriction in the SAP User rights or something? I mean the server is running on 80 and accepting incoming and outgoing connections as far as i tested in the terminal.
Adam,
Can you put server ip instead of server name(gt-systems.de) in your url address and check ?
Regards,
Kulwinder
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Adam,
It seems there is issue with port no,please check http port you can find details video at
http://www.saphana.com/docs/DOC-4284
Best Regards,
Atul
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
90 | |
10 | |
10 | |
10 | |
7 | |
7 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.