It is important that the client isn't closed when using the jndi provided client as it is a singleton and is reused.