InitialContext ctx = new InitialContext(); ExampleTimer timer = (ExampleTimer) ctx.lookup("ExampleTimerBean/remote"); timer.scheduleTimer(5000);