// This is an entity bean (lifespan: persistent)
beanServantRegistry = poaRegistry.getValue().getRegistryWithPersistentPOAPerServant();
final EntityBeanComponent entityBeanComponent = (EntityBeanComponent) component;
final Class pkClass = entityBeanComponent.getPrimaryKeyClass();
ejbMetaData = new EJBMetaDataImplIIOP(entityBeanComponent.getRemoteClass(), entityBeanComponent.getHomeClass(), pkClass, false, false, homeHandle);
} else {
// This is a session bean (lifespan: transient)
beanServantRegistry = poaRegistry.getValue().getRegistryWithTransientPOAPerServant();
if (component instanceof StatelessSessionComponent) {
// Stateless session bean
ejbMetaData = new EJBMetaDataImplIIOP(remoteView.getValue().getViewClass(), homeView.getValue().getViewClass(), null, true, true, homeHandle);
} else {
// Stateful session bean
ejbMetaData = new EJBMetaDataImplIIOP(remoteView.getValue().getViewClass(), homeView.getValue().getViewClass(), null, true, false, homeHandle);
}
}
homeServant.setEjbMetaData(ejbMetaData);
// If there is an interface repository, then get the beanInterfaceDef from the IR