Adding remote api support for java
added comments
addressed comments
Merge pull request #1638 from AppScale/remote-api-for-java

Adding remote api support for java