cancel
Showing results for 
Search instead for 
Did you mean: 

FACING AN ISSUE WHILE CONSUMING ABAP ODATA USING JAVA

0 Kudos

com.sap.nw.gateway.odata.client.connectivity.impl.DefaultRestClient send

SEVERE: Connection reset

java.net.SocketException: Connection reset

  at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)

  at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)

  at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)

  at java.lang.reflect.Constructor.newInstance(Constructor.java:526)

  at sun.net.www.protocol.http.HttpURLConnection$6.run(HttpURLConnection.java:1676)

  at sun.net.www.protocol.http.HttpURLConnection$6.run(HttpURLConnection.java:1674)

  at java.security.AccessController.doPrivileged(Native Method)

  at sun.net.www.protocol.http.HttpURLConnection.getChainedException(HttpURLConnection.java:1672)

  at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1245)

  at java.net.HttpURLConnection.getResponseCode(HttpURLConnection.java:468)

  at com.sap.nw.gateway.odata.client.connectivity.impl.DefaultRestClient.send(DefaultRestClient.java:381)

  at com.sap.nw.gateway.odata.client.connectivity.impl.RestClientBase.execute(RestClientBase.java:34)

  at oData.DownloadPage.readExample(DownloadPage.java:124)

  at oData.DownloadPage.main(DownloadPage.java:53)

Caused by: java.net.SocketException: Connection reset

  at java.net.SocketInputStream.read(SocketInputStream.java:196)

  at java.net.SocketInputStream.read(SocketInputStream.java:122)

  at java.io.BufferedInputStream.fill(BufferedInputStream.java:235)

  at java.io.BufferedInputStream.read1(BufferedInputStream.java:275)

  at java.io.BufferedInputStream.read(BufferedInputStream.java:334)

  at sun.net.www.http.HttpClient.parseHTTPHeader(HttpClient.java:689)

  at sun.net.www.http.HttpClient.parseHTTP(HttpClient.java:633)

  at sun.net.www.http.HttpClient.parseHTTP(HttpClient.java:660)

  at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1324)

  at com.sap.nw.gateway.odata.client.connectivity.impl.DefaultRestClient.send(DefaultRestClient.java:333)

  ... 3 more

Accepted Solutions (1)

Accepted Solutions (1)

vijay_kumar49
Active Contributor
0 Kudos
0 Kudos

I checked it but i cannot relate with my project .I just need to access an ABAP OData Url using my my Credentials in java Code. Is there any Abstract Code.

Answers (0)