ECN-1156 "InetAddress.getLocalHost clarification" does not appear to be supported in RI Rel C.
Is this true? If so, why not?
I could find some description in mpeos_socketGetHostByName() as you explained.
* If name is identical to the local host name as returned by mpeos_socketGetHostName() ,
* the returned mpe_SocketHostEntry structure shall contain a single address only. That
* address must identify the OCAP1.0 return channel or DOCSIS interface.
But, it does not seem to implement to check if the given name equals to the return name by mpeos_socketGetHostName() or not.
In mpeos_socketGetHostByName(), it just call OS API to resolve the given name by hosts file or DNS query.
If I add some code to check and return the address of OCAP return channel in RI simulator, is it the value of "RI.Platform.IpAddr" ?
Message was edited by: suntec
Agreed -- our PC Platform does not really have a concept of a return channel IP at this time. I will file an internal issue to finish out the implementation so that the MPEOS calls will return the RI.Platform.IpAddr value. Thanks.
It is supported. See the API documentation for mpeos_socketGetHostByName() in $OCAPROOT/mpe/os/include/mpeos_socket.h. Your JVM must ensure that it calls this API properly when implementing InetAddress.getLocalHost().
If your JVM happens to be ported directly to your target platform rather than to MPE, then the JVM must acquire the OCAP or DOCSIS return channel IP through some proprietary communication with the platform.
I shall investigate further.
Your use of this web site or any of its content or software indicates your agreement to be bound by these Terms of Participation.
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. Oracle and Java are registered trademarks of Oracle and/or its affiliates. Other names may be trademarks of their respective owners.