Skip to Content

How to connect a local java application to HANA as a Service

Dear all,
I need to develop a Java application, connectinig to HANA service runnning on Cloud Foundry in SCP.
The JDBC connection string that I see in VCAP_SERVICES contains the port 443 and therefore a JDBC connection that is expecting the 3xx1y pattern cannot take place.
I was trying to setup chisel but am not getting as far as I need and am not sure is stilil needed.
Please advice.

Add a comment
10|10000 characters needed characters exceeded

Related questions

2 Answers

  • Posted on Jul 08 at 11:29 AM

    Hi Luca,

    With HANA as a service running in Cloud Foundry indeed it's listening on port 443 where you'd expect a HTTPS server, but don't let that throw you. Just use the host:port as provided in VCAP_SERVICES and you'll be able to connect from your java app as well as external tools.

    Do keep in mind that HANA as a service requires an encrypted connection or it will drop connection attempts.

    You can test the connection from your local machine by installing the HANA client libraries for your workstation platform and use the command-line tool.

    hdbsql -n some-very-long-hostname.hana.prod-us10.hanacloud.ondemand.com:443 -e -ssltrustcert -u vcap_creds_user -p vcap_creds_password

    Hope this helps.

    -Andrew

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Jul 09 at 01:39 PM

    thankyou ! Indeed it works very smoothly and chisel is not even needed.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.