private AppModule getAppModule(InputSource ejbJarSrc, InputSource openEjbJarSrc) throws ConversionException {
AppModule appModule = new AppModule(classLoader, "ModuleToConvert"); //$NON-NLS-1$
try {
EjbJar ejbJar = (EjbJar) JaxbJavaee.unmarshal(EjbJar.class, ejbJarSrc.getByteStream());
EjbModule ejbModule = new EjbModule(ejbJar, new OpenejbJar());
ejbModule.setClassLoader(classLoader);
appModule.getEjbModules().add(ejbModule);
if (openEjbJarSrc != null) {
InitEjbDeployments initEjbDeployments = new InitEjbDeployments();
initEjbDeployments.deploy(ejbModule);
JAXBElement<?> element = (JAXBElement<?>) JaxbOpenejbJar2.unmarshal(OpenejbJarType.class, openEjbJarSrc.getByteStream());
OpenejbJarType openejbJarType = (OpenejbJarType) element.getValue();
ejbModule.getAltDDs().put("openejb-jar.xml", openejbJarType); //$NON-NLS-1$
CmpJpaConversion cmpJpaConversion = new CmpJpaConversion();
cmpJpaConversion.deploy(appModule);
OpenEjb2Conversion openEjb2Conversion = new OpenEjb2Conversion();