if (command!=null) {
try {
log.debug("looking up local command service");
Context initial = new InitialContext();
Context environment = (Context) initial.lookup("java:comp/env");
LocalCommandServiceHome localCommandServiceHome = (LocalCommandServiceHome) environment.lookup("ejb/LocalCommandServiceBean");
LocalCommandService localCommandService = localCommandServiceHome.create();
try {
// TODO add support for sending back the result
// not a priority because i don't see much use cases for that.
// let me know on the dev forums if you think otherwise.
log.debug("executing command with local command service");