90919293949596979899100101
try { InitialContext ic = new InitialContext(); ManagementHome home = (ManagementHome)ic.lookup("ejb/Management"); Management bean = home.create(); bean.killAS(); } catch(Exception e) { // OK, I expect exceptions following a VM kill }
93949596979899100101102103104105106
try { InitialContext ic = new InitialContext(); ManagementHome home = (ManagementHome)ic.lookup("ejb/Management"); Management bean = home.create(); try { bean.killAS(); } catch(Exception e) { // OK, I expect exceptions following a VM kill }