In a nonmanaged environment where the default connection manager is used, the application can set the LogWriter property on the class to define where trace messages are sent.
ECIManagedConnectionFactory MCF = new ECIManagedConnectionFactory();
MCF.setLogWriter(myLogWriter);
ECIConnectionFactory cf = MCF.createConnectionFactory();
objOutStream.write(cf);
ECIConnectionFactory cf2 = (ECIConnectionFactory) objInStream.read();
DefaultConnectionManager.setLogWriter(myLogWriter);