Another way to handle the connection is to create a servlet that the client can communicate with using http. The servlet uses the "normal" EJB calls towards the EJB.
This has the advantage of working well through firewalls and the protocol can be farily simple. The disadvantage is that you have to define the low level parts of the protocol too. With SOAP you only have to define the application part.