I found several examples in Java of how to write to a TCP server socket, but I found none of them that show how to do it with PeopleCode calling Java. Here's an example that I put together, which works great, so long as you have a server that is listening for your connection. If you don't have a server, I'll show you how to use the Linux "nc" command to create one.