server = null;
}
public static void publish(String destination, Serializable object, String contentType) throws Exception
{
BindingRegistry reg = server.getRegistry();
Destination dest = (Destination) reg.lookup(destination);
ConnectionFactory factory = (ConnectionFactory) reg.lookup("ConnectionFactory");
Connection conn = factory.createConnection();
Session session = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
try
{