}
public static TargetModuleID getTargetModuleID(IServer server, IModule module) throws TargetModuleIdNotFoundException {
String configId = ModuleArtifactMapper.getInstance().resolve(server, module);
if(configId == null) {
throw new TargetModuleIdNotFoundException("Could not do a local TargetModuleID lookup for module " + module.getName());
}
IGeronimoServer gs = (IGeronimoServer) server.getAdapter(IGeronimoServer.class);
return gs.getVersionHandler().createTargetModuleId(configId);
}