Re: URL of a Service Instance


Rahul Gupta
 

Hi Dieu,

I figured that out and did the following:
1. Created an instance of caching server. As soon as the instance gets created, I extract the hostname and InetAddress of this instance and stores in credentials upon bind request. For example, the host and InetAddress returned is 10.254.0.58.
2. When an app is bound to the service, the credentials do show up in VCAP_SERVICES.
3. I then use the IP address returned in credentials on bind response, in the application to initiate a connection with the caching server. At this point, the app refuses to find any server running at that IP.

So 2 questions:
1. The IP address returned is a private IP. Can an application running on Cloud Foundry connect with a service instance through private IP address? If yes, then do I need to do something special to enable this communication through private IP?
2. How and where do I see the logs of caching server which was created by the broker in createServiceInstance?

Thanks,
Rahul

Join cf-dev@lists.cloudfoundry.org to automatically receive all group messages.