System.out.println("Via Remote Interface");
Context jndiContext = getInitialContext();
//Object ref = jndiContext.lookup("java:eu/planets_project/tb/TestWizzard/local");
TesterRemote dao_r = (TesterRemote) PortableRemoteObject.narrow(jndiContext.lookup("TestWizzard/remote"), TesterRemote.class);
TestBean test_1 = new TestBean();
test_1.setId(1);
test_1.setName("Andrew1");
System.out.println("Before storing ID1");
dao_r.createTestEntry(test_1);
System.out.println("Successfully stored ID1");
TestBean test_2 = new TestBean();
test_2.setId(2);
test_2.setName("Andrew2");
System.out.println("Before storing ID2");
dao_r.createTestEntry(test_2);
System.out.println("Successfully stored ID2");
System.out.println("Before finding ID1");
TestBean test_find1 = dao_r.findTestEntry(1);
System.out.println("found ID "+test_find1.getId());
System.out.println("found Name "+test_find1.getName());
System.out.println("Before finding ID2");
TestBean test_find2 = dao_r.findTestEntry(2);
System.out.println("found ID "+test_find2.getId());
System.out.println("found Name "+test_find2.getName());
/*System.out.println("Via Local Interface");
TesterLocal dao_l = (TesterLocal) jndiContext.lookup("TestWizzard/local");
jndiContext.lookup("TestWizzard/local");