public void parseWebDD(JndiConsumer annotatedWebAppDD, GerWebAppType webApp) { if (annotatedWebAppDD instanceof WebApp) { WebApp webAppDD = (WebApp) annotatedWebAppDD; List<MessageDestination> messageDestinations = webAppDD.getMessageDestination(); for (MessageDestination messageDestination: messageDestinations) { String messageDestinationName = messageDestination.getMessageDestinationName(); GerMessageDestinationType gerMessageDestination = webApp.addNewMessageDestination(); messageDestination.setMessageDestinationName(messageDestinationName); // messageDestination.setAdminObjectLink(messageDestinationName); } } }
for (MessageDestination destination : webModule.getWebApp().getMessageDestination()) { destinationResolver.add(moduleId, destination.getMessageDestinationName(), destination);
for (final MessageDestination destination : webModule.getWebApp().getMessageDestination()) { destinationResolver.add(appModule.getModuleUri(), destination.getMessageDestinationName(), destination);
@Override public void preProcessWebXmlElement(WebApp webApp, MergeContext context) throws DeploymentException { for (MessageDestination messageDestination : webApp.getMessageDestination()) { context.setAttribute(createMessageDestinationConfiguredInWebXMLKey(messageDestination.getMessageDestinationName()), Boolean.TRUE); } }
for (final MessageDestination destination : webModule.getWebApp().getMessageDestination()) { destinationResolver.add(appModule.getModuleUri(), destination.getMessageDestinationName(), destination);
@Override public void merge(WebFragment webFragment, WebApp webApp, MergeContext mergeContext) throws DeploymentException { for (MessageDestination messageDestination : webApp.getMessageDestination()) { String messageDestinationName = messageDestination.getMessageDestinationName(); if (mergeContext.containsAttribute(createMessageDestinationConfiguredInWebXMLKey(messageDestination.getMessageDestinationName()))) { continue; } if (mergeContext.containsAttribute(createMessageDestinationConfiguredInWebFragmentXMLKey(messageDestinationName))) { MergeItem mergeItem = (MergeItem) mergeContext.getAttribute(createMessageDestinationConfiguredInWebFragmentXMLKey(messageDestinationName)); throw new DeploymentException(WebDeploymentMessageUtils.createDuplicateJNDIRefMessage("message-destination", messageDestinationName, mergeItem.getBelongedURL(), mergeContext.getCurrentJarUrl())); } else { webApp.getMessageDestination().add(messageDestination); mergeContext.setAttribute(createMessageDestinationConfiguredInWebFragmentXMLKey(messageDestinationName), new MergeItem(messageDestination, mergeContext.getCurrentJarUrl(), ElementSource.WEB_FRAGMENT)); } } }