## 1 Jinterface Release Notes

This document describes the changes made to the Jinterface application.

### 1.1 Jinterface 1.4.1

#### 1.1.1 Fixed Bugs and Malfunctions

- Jinterface has been fixed to use the loopback interface when connecting to the Erlang Port Mapper Daemon - epmd. This facilitates firewall configuration and saves resources.
  Own Id: OTP-7103
- Jinterface now refuses to connect to another node that does not agree on the other node's name. This has been a problem in that a connection was set up, but not used on a following send, which caused a second erroneous connection attemt to fail since the other (Erlang) node rejects a connection due to name disagreement.
  Problem reported and dissected by Alexander Lamb
  Own Id: OTP-7330

### 1.2 Jinterface 1.4

#### 1.2.1 Improvements and New Features

- Jinterface has been updated to handle compressed terms, bitstring, new (IEEE) floats and bignums. This has caused a few incompatibilities.
  com.ericsson.otp.erlang.OtpOutputStream now extends java.io.ByteArrayOutputStream, previously java.lang.Object, and hence the method size() now return the number of bytes in the stream as dictated by the new parent class and not the buffer length as before. The new method length() returns what the old size() did return. The method count() is deprecated as it returns the same as the new size().
  com.ericsson.otp.erlang.OtpErlangLong now can handle larger values than 64-bit. Previously when larger than 64-bit integers were sent to a Jinterface node, it caused an com.ericsson.otp.erlang.OtpDecodeException. Now the integer is accepted, but the return value of longValue() is silently truncated, as opposed to the return value of intValue() that now and previously raises an com.ericsson.otp.erlang.OtpRangeException for unrepresentable values. The new methods isLong() and isULong() can be used to determine if the value fits in a long.
  *** POTENTIAL INCOMPATIBILITY ***
  Own Id: OTP-6809

### 1.3 Jinterface 1.3

#### 1.3.1 Fixed Bugs and Malfunctions

- OtpMbox.receive() and OtpMbox.receive(long timeout) can now throw OtpErlangDecodeException if the received message can not be decoded. null is now only returned from OtpMbox.receive(long timeout) if a timeout occurs. OtpMbox.receive() will never return null.
  *** POTENTIAL INCOMPATIBILITY ***
  Own Id: OTP-3932 Aux Id: seq5196
- Strings longer than 65535 bytes were encoded wrong by jinterface.
  Own Id: OTP-4883 Aux Id: OTP-4865
- Misc bugfixes:
  - A node pinging itself does no longer cause the java program to hang.
  - OtpMbox.close() uses exit reason 'normal' (atom) instead of "normal" (string).
  - Added OtpNode.closeMbox(OtpMbox mbox, OtpErlangObject reason).
  - Added OtpMbox.exit(OtpErlangObject reason) and OtpMbox.exit(String reason).
  - Added OtpMbox.exit(OtpErlangPid to, OtpErlangObject reason).
  - OtpMbox.exit(OtpErlangPid to, String reason) is now equivalent to OtpMbox.exit(to, new OtpErlangAtom(reason)).
  - Exit signals from an Erlang node can now contain any erlang term as reason, not only atoms.
  Own Id: OTP-5088
- For java versions 1.3.1 or later, localStatus was not sent to registered status handler when OtpNode.close() was called. This is now corrected.
  Own Id: OTP-5169

#### 1.3.2 Improvements and New Features

- Process identifiers and port identifiers have been made more unique. Previously 18 bits were used as id in the internal representation of process and port identifiers. Now 28 bits are used.
  The maximum limit on the number of concurrently existing processes due to the representation of pids has been increased to 268435456 processes. The same is true for ports. This limit will at least on a 32-bit architecture be impossible to reach due to memory shortage.
  NOTE: By default, the ERTS, and the erl_interface, ei, and jinterface libraries are now only guaranteed to be compatible with other Erlang/OTP components from the same release. It is possible to set each component in compatibility mode of an earlier release, though. See the documentation for respective component on how to set it in compatibility mode.
  *** POTENTIAL INCOMPATIBILITY ***
  Own Id: OTP-4968 Aux Id: OTP-4196

### 1.4 Jinterface 1.2.1.2

#### 1.4.1 Fixed Bugs and Malfunctions

- Output of Java long was truncated to 32 bits. IDL long long and unsigned long long could not be used in a struct for the Java backend. All unsigned integer types for the Java backend had broken marshalling for large values. These bugs has now been fixed.
  Own Id: OTP-4763 Aux Id: seq8024

jinterface 1.4.1
Copyright © 1991-2008 Ericsson AB