You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@juddi.apache.org by al...@apache.org on 2013/05/11 02:27:35 UTC
svn commit: r1481240 [3/4] - in /juddi/branches/juddi-3.2.x: ./
juddi-client/ juddi-client/src/main/java/org/apache/juddi/v3/client/
juddi-client/src/main/java/org/apache/juddi/v3/client/config/
juddi-client/src/main/java/org/apache/juddi/v3/client/map...
Modified: juddi/branches/juddi-3.2.x/juddi-client/src/main/java/org/apache/juddi/v3/client/mapping/WSDL2UDDI.java
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-client/src/main/java/org/apache/juddi/v3/client/mapping/WSDL2UDDI.java?rev=1481240&r1=1481239&r2=1481240&view=diff
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-client/src/main/java/org/apache/juddi/v3/client/mapping/WSDL2UDDI.java (original)
+++ juddi/branches/juddi-3.2.x/juddi-client/src/main/java/org/apache/juddi/v3/client/mapping/WSDL2UDDI.java Sat May 11 00:27:33 2013
@@ -16,6 +16,7 @@
*/
package org.apache.juddi.v3.client.mapping;
+import java.net.MalformedURLException;
import java.net.URL;
import java.rmi.RemoteException;
import java.util.ArrayList;
@@ -32,6 +33,7 @@ import javax.wsdl.PortType;
import javax.wsdl.Service;
import javax.wsdl.WSDLException;
import javax.wsdl.extensions.http.HTTPBinding;
+import javax.wsdl.extensions.soap.SOAPAddress;
import javax.wsdl.extensions.soap.SOAPBinding;
import javax.xml.namespace.QName;
@@ -42,10 +44,13 @@ import org.apache.juddi.api_v3.AccessPoi
import org.apache.juddi.jaxb.PrintUDDI;
import org.apache.juddi.v3.client.config.Property;
import org.apache.juddi.v3.client.config.UDDIClerk;
+import org.apache.juddi.v3.client.config.UDDIKeyConvention;
import org.apache.juddi.v3.client.transport.TransportException;
import org.uddi.api_v3.AccessPoint;
import org.uddi.api_v3.BindingTemplate;
+import org.uddi.api_v3.BindingTemplates;
import org.uddi.api_v3.BusinessService;
+import org.uddi.api_v3.BusinessServices;
import org.uddi.api_v3.CategoryBag;
import org.uddi.api_v3.Description;
import org.uddi.api_v3.FindTModel;
@@ -75,11 +80,11 @@ import org.w3c.dom.Element;
* </ul>
*
* @author Kurt T Stam
- *
+ * @Since 3.1.5
*/
public class WSDL2UDDI {
- private Log log = LogFactory.getLog(this.getClass());
+ private static Log log = LogFactory.getLog(WSDL2UDDI.class);
private String keyDomainURI;
private String businessKey;
private String lang;
@@ -87,27 +92,85 @@ public class WSDL2UDDI {
private Properties properties = null;
private URLLocalizer urlLocalizer;
- public WSDL2UDDI(UDDIClerk clerk, URLLocalizer urlLocalizer, Properties properties) {
+ /**
+ * Required Properties are:
+ * businessName, for example: 'Apache'
+ * nodeName, for example: 'uddi.example.org_80'
+ * keyDomain, for example: juddi.apache.org
+ *
+ * Optional Properties are:
+ * lang: for example: 'nl'
+ *
+ * @param clerk - can be null if register/unregister methods are not used.
+ * @param urlLocalizer - A reference to an custom
+ * @param properties
+ * @throws ConfigurationException
+ */
+ public WSDL2UDDI(UDDIClerk clerk, URLLocalizer urlLocalizer, Properties properties) throws ConfigurationException {
super();
this.clerk = clerk;
this.urlLocalizer = urlLocalizer;
this.properties = properties;
+ if (clerk!=null) {
+ if (!properties.containsKey("keyDomain")) {
+ throw new ConfigurationException("Property keyDomain is a required property when using WSDL2UDDI.");
+ }
+ if (!properties.containsKey("businessKey") && !properties.containsKey("businessName")) {
+ throw new ConfigurationException("Either property businessKey, or businessName, is a required property when using WSDL2UDDI.");
+ }
+ if (!properties.containsKey("nodeName")) {
+ if (properties.containsKey("serverName") && properties.containsKey("serverPort")) {
+ String nodeName = properties.getProperty("serverName") + "_" + properties.getProperty("serverPort");
+ properties.setProperty("nodeName", nodeName);
+ } else {
+ throw new ConfigurationException("Property nodeName is not defined and is a required property when using WSDL2UDDI.");
+ }
+ }
+ }
+
//Obtaining values from the properties
this.keyDomainURI = "uddi:" + properties.getProperty("keyDomain") + ":";
- this.businessKey = Property.getBusinessKey(properties);
+ if (properties.contains(Property.BUSINESS_KEY)) {
+ this.businessKey = properties.getProperty(Property.BUSINESS_KEY);
+ } else {
+ //using the BusinessKey Template, and the businessName to construct the key
+ this.businessKey = UDDIKeyConvention.getBusinessKey(properties);
+ }
this.lang = properties.getProperty(Property.LANG,Property.DEFAULT_LANG);
}
+ public BusinessServices registerBusinessServices(Definition wsdlDefinition) throws RemoteException, ConfigurationException, TransportException, WSDLException {
+
+ BusinessServices businessServices = new BusinessServices();
+
+ for (Object serviceName : wsdlDefinition.getAllServices().keySet()) {
+ QName serviceQName = (QName) serviceName;
+ Service service = wsdlDefinition.getService(serviceQName);
+ BusinessService businessService = null;
+ //add service
+ URL serviceUrl = null;
+ if (service.getPorts()!=null && service.getPorts().size()>0) {
+ for (Object portName : service.getPorts().keySet()) {
+ businessService = registerBusinessService(serviceQName, (String) portName, serviceUrl, wsdlDefinition).getBusinessService();
+ }
+ }
+ if (businessService!=null) businessServices.getBusinessService().add(businessService);
+ }
+
+ return businessServices;
+
+ }
+
@SuppressWarnings("unchecked")
- public BindingTemplate register(QName serviceQName, String portName, URL serviceUrl, Definition wsdlDefinition) throws RemoteException, ConfigurationException, TransportException, WSDLException {
+ public ServiceRegistrationResponse registerBusinessService(QName serviceQName, String portName, URL serviceUrl, Definition wsdlDefinition) throws RemoteException, ConfigurationException, TransportException, WSDLException {
String genericWSDLURL = wsdlDefinition.getDocumentBaseURI(); //TODO maybe point to repository version
-
- String serviceKey = Property.getServiceKey(properties, serviceQName);
- BusinessService service = lookupService(serviceKey);
- if (service==null) {
+ ServiceRegistrationResponse response = new ServiceRegistrationResponse();
+ String serviceKey = UDDIKeyConvention.getServiceKey(properties, serviceQName.getLocalPart());
+ BusinessService businessService = lookupService(serviceKey);
+ if (businessService==null) {
List<TModel> tModels = new ArrayList<TModel>();
// Create the PortType tModels
Map<QName,PortType> portTypes = (Map<QName,PortType>) wsdlDefinition.getAllPortTypes();
@@ -120,23 +183,47 @@ public class WSDL2UDDI {
clerk.register(tModel);
}
// Service
- service = createBusinessService(serviceQName, wsdlDefinition);
+ businessService = createBusinessService(serviceQName, wsdlDefinition);
// Register this Service
- clerk.register(service);
+ clerk.register(businessService);
}
//Add the BindingTemplate to this Service
BindingTemplate binding = createWSDLBinding(serviceQName, portName, serviceUrl, wsdlDefinition);
// Register BindingTemplate
clerk.register(binding);
- return binding;
+ if (businessService.getBindingTemplates() == null) businessService.setBindingTemplates(new BindingTemplates());
+ businessService.getBindingTemplates().getBindingTemplate().add(binding);
+ response.setBindingKey(binding.getBindingKey());
+ response.setBusinessService(businessService);
+ return response;
+ }
+
+ public String[] unRegisterBusinessServices(Definition wsdlDefinition) throws RemoteException, ConfigurationException, TransportException, MalformedURLException {
+
+ String[] businessServices = new String[wsdlDefinition.getAllServices().size()];
+ int i=0;
+ for (Object serviceName : wsdlDefinition.getAllServices().keySet()) {
+ QName serviceQName = (QName) serviceName;
+ Service service = wsdlDefinition.getService(serviceQName);
+ //unregister service
+ URL serviceUrl = null;
+ if (service.getPorts()!=null && service.getPorts().size() > 0) {
+ for (Object portName : service.getPorts().keySet()) {
+ //construct the accessURL
+ serviceUrl = new URL(getBindingURL((Port) service.getPorts().get(portName)));
+ businessServices[i++] = unRegisterBusinessService(serviceQName, (String) portName, serviceUrl);
+ }
+ }
+ }
+ return businessServices;
}
- public String unRegister(QName serviceName, String portName, URL serviceUrl) throws RemoteException, ConfigurationException, TransportException {
+ public String unRegisterBusinessService(QName serviceName, String portName, URL serviceUrl) throws RemoteException, ConfigurationException, TransportException {
- String serviceKey = Property.getServiceKey(properties, serviceName);
+ String serviceKey = UDDIKeyConvention.getServiceKey(properties, serviceName.getLocalPart());
BusinessService service = lookupService(serviceKey);
boolean isRemoveServiceIfNoTemplates = true;
- String bindingKey = Property.getBindingKey(properties, serviceName, portName, serviceUrl);
+ String bindingKey = UDDIKeyConvention.getBindingKey(properties, serviceName, portName, serviceUrl);
//check if this bindingKey is in the service's binding templates
for (BindingTemplate bindingTemplate : service.getBindingTemplates().getBindingTemplate()) {
if (bindingKey.equals(bindingTemplate.getBindingKey())) {
@@ -269,7 +356,7 @@ public class WSDL2UDDI {
* @return set of WSDL Binding tModels
* @throws WSDLException
*/
- public Set<TModel> createWSDLBindingTModels(String wsdlURL, Map<QName,Binding> bindings) throws WSDLException
+ protected Set<TModel> createWSDLBindingTModels(String wsdlURL, Map<QName,Binding> bindings) throws WSDLException
{
Set<TModel> tModels = new HashSet<TModel>();
@@ -299,7 +386,7 @@ public class WSDL2UDDI {
if (namespace!=null && !"".equals(namespace)) {
// A keyedReference with a tModelKey of the WSDL Entity Type category system and a keyValue of "binding".
KeyedReference namespaceReference = newKeyedReference(
- "uddi:uddi.org:xml:namespace", "uddi-org:xml:binding:namespace", namespace);
+ "uddi:uddi.org:xml:namespace", "uddi-org:xml:namespace", namespace);
categoryBag.getKeyedReference().add(namespaceReference);
}
@@ -397,7 +484,7 @@ public class WSDL2UDDI {
<p>The tModel MUST contain an overviewDoc with an overviewURL containing the location
of the WSDL document that describes the wsdl:portType.</p>
- * @param wsdlURL
+ * @param wsdlURL This is used to set the Overview URL
* @param portType Map
* @return set of WSDL PortType tModels
* @throws WSDLException
@@ -444,7 +531,7 @@ public class WSDL2UDDI {
// MUST NOT contain a keyedReference to the XML Namespace category system.
if (namespace!=null && !"".equals(namespace)) {
KeyedReference namespaceReference = newKeyedReference(
- "uddi:uddi.org:xml:namespace", "uddi-org:xml:porttype:namespace", namespace);
+ "uddi:uddi.org:xml:namespace", "uddi-org:xml:namespace", namespace);
categoryBag.getKeyedReference().add(namespaceReference);
}
@@ -454,15 +541,7 @@ public class WSDL2UDDI {
return tModels;
}
- protected KeyedReference newKeyedReference(String tModelKey, String value)
- {
- KeyedReference typesReference = new KeyedReference();
- typesReference.setTModelKey(tModelKey);
- typesReference.setKeyValue(value);
- return typesReference;
- }
-
- protected KeyedReference newKeyedReference(String tModelKey, String keyName, String value)
+ protected static KeyedReference newKeyedReference(String tModelKey, String keyName, String value)
{
KeyedReference typesReference = new KeyedReference();
typesReference.setTModelKey(tModelKey);
@@ -476,22 +555,22 @@ public class WSDL2UDDI {
* @param processName
* @return
*/
- public FindTModel createFindBindingTModelForPortType (String portType, String namespace) {
+ public static FindTModel createFindBindingTModelForPortType (String portType, String namespace) {
FindTModel findTModel = new FindTModel();
CategoryBag categoryBag = new CategoryBag();
if (namespace!=null && namespace.length()!=0) {
KeyedReference namespaceReference = newKeyedReference(
- "uddi:uddi.org:xml:namespace", namespace);
+ "uddi:uddi.org:xml:namespace", "uddi-org:xml:namespace", namespace);
categoryBag.getKeyedReference().add(namespaceReference);
}
KeyedReference bindingReference = newKeyedReference(
- "uddi:uddi.org:wsdl:types", "binding");
+ "uddi:uddi.org:wsdl:types", "uddi-org:wsdl:types", "binding");
categoryBag.getKeyedReference().add(bindingReference);
KeyedReference portTypeReference = newKeyedReference(
- "uddi:uddi.org:wsdl:porttypereference", portType);
+ "uddi:uddi.org:wsdl:porttypereference", "uddi-org:wsdl:portTypeReference", portType);
categoryBag.getKeyedReference().add(portTypeReference);
findTModel.setCategoryBag(categoryBag);
@@ -507,28 +586,24 @@ public class WSDL2UDDI {
* @param processName
* @return
*/
- public FindTModel createFindPortTypeTModelForPortType (String portType, String namespace) {
+ public static FindTModel createFindPortTypeTModelForPortType (String portTypeName, String namespace) {
FindTModel findTModel = new FindTModel();
Name name = new Name();
- name.setLang(lang);
- name.setValue(portType);
+ name.setLang("en");
+ name.setValue(portTypeName);
findTModel.setName(name);
CategoryBag categoryBag = new CategoryBag();
if (namespace!=null && namespace.length()!=0) {
KeyedReference namespaceReference = newKeyedReference(
- "uddi:uddi.org:xml:namespace", namespace);
+ "uddi:uddi.org:xml:namespace", "uddi-org:xml:namespace", namespace);
categoryBag.getKeyedReference().add(namespaceReference);
}
KeyedReference bindingReference = newKeyedReference(
- "uddi:uddi.org:wsdl:types", "portType");
+ "uddi:uddi.org:wsdl:types", "uddi-org:wsdl:types", "portType");
categoryBag.getKeyedReference().add(bindingReference);
- KeyedReference portTypeReference = newKeyedReference(
- "uddi:uddi.org:wsdl:porttypereference", portType);
- categoryBag.getKeyedReference().add(portTypeReference);
-
findTModel.setCategoryBag(categoryBag);
if (log.isDebugEnabled()) {
@@ -545,13 +620,34 @@ public class WSDL2UDDI {
* @throws ConfigurationException
* @throws TransportException
*/
- public BusinessService lookupService(String serviceKey) throws RemoteException, ConfigurationException, TransportException {
+ private BusinessService lookupService(String serviceKey) throws RemoteException, ConfigurationException, TransportException {
//Checking if this serviceKey already exist
BusinessService service = clerk.findService(serviceKey);
return service;
}
+ public BusinessServices createBusinessServices(Definition wsdlDefinition) {
+ BusinessServices businessServices = new BusinessServices();
+ for (Object serviceName : wsdlDefinition.getAllServices().keySet()) {
+ QName serviceQName = (QName) serviceName;
+ Service service = wsdlDefinition.getService(serviceQName);
+ BusinessService businessService = createBusinessService(serviceQName, wsdlDefinition);
+ //service.getExtensibilityElements().
+ //add the bindingTemplates
+ URL serviceUrl = null;
+ if (service.getPorts()!=null && service.getPorts().size()>0) {
+ businessService.setBindingTemplates(new BindingTemplates());
+ for (Object portName : service.getPorts().keySet()) {
+ BindingTemplate bindingTemplate = createWSDLBinding(serviceQName, (String) portName, serviceUrl, wsdlDefinition);
+ businessService.getBindingTemplates().getBindingTemplate().add(bindingTemplate);
+ }
+ }
+ businessServices.getBusinessService().add(businessService);
+ }
+
+ return businessServices;
+ }
/**
* Creates a UDDI Business Service.
*
@@ -559,14 +655,14 @@ public class WSDL2UDDI {
* @param wsldDefinition
* @return
*/
- public BusinessService createBusinessService(QName serviceQName, Definition wsdlDefinition) {
+ protected BusinessService createBusinessService(QName serviceQName, Definition wsdlDefinition) {
log.debug("Constructing Service UDDI Information for " + serviceQName);
BusinessService service = new BusinessService();
// BusinessKey
service.setBusinessKey(businessKey);
// ServiceKey
- service.setServiceKey(Property.getServiceKey(properties, serviceQName));
+ service.setServiceKey(UDDIKeyConvention.getServiceKey(properties, serviceQName.getLocalPart()));
// Description
String serviceDescription = properties.getProperty(Property.SERVICE_DESCRIPTION, Property.DEFAULT_SERVICE_DESCRIPTION);
// Override with the service description from the WSDL if present
@@ -591,16 +687,16 @@ public class WSDL2UDDI {
String namespace = serviceQName.getNamespaceURI();
if (namespace!=null && namespace!="") {
KeyedReference namespaceReference = newKeyedReference(
- "uddi:uddi.org:xml:namespace", "service namespace", namespace);
+ "uddi:uddi.org:xml:namespace", "uddi-org:xml:namespace", namespace);
categoryBag.getKeyedReference().add(namespaceReference);
}
KeyedReference serviceReference = newKeyedReference(
- "uddi:uddi.org:wsdl:types", "WSDL type", "service");
+ "uddi:uddi.org:wsdl:types", "uddi-org:wsdl:types", "service");
categoryBag.getKeyedReference().add(serviceReference);
KeyedReference localNameReference = newKeyedReference(
- "uddi:uddi.org:xml:localname", "service local name", serviceQName.getLocalPart());
+ "uddi:uddi.org:xml:localname", "uddi-org:xml:localName", serviceQName.getLocalPart());
categoryBag.getKeyedReference().add(localNameReference);
service.setCategoryBag(categoryBag);
@@ -608,19 +704,22 @@ public class WSDL2UDDI {
return service;
}
- public BindingTemplate createWSDLBinding(QName serviceQName, String portName, URL serviceUrl, Definition wsdlDefinition) {
+ protected BindingTemplate createWSDLBinding(QName serviceQName, String portName, URL serviceUrl, Definition wsdlDefinition) {
BindingTemplate bindingTemplate = new BindingTemplate();
// Set BusinessService Key
- bindingTemplate.setServiceKey(Property.getServiceKey(properties, serviceQName));
- // Set Binding Key
- String bindingKey = Property.getBindingKey(properties, serviceQName, portName, serviceUrl);
- bindingTemplate.setBindingKey(bindingKey);
- // Set AccessPoint
- AccessPoint accessPoint = new AccessPoint();
- accessPoint.setUseType(AccessPointType.END_POINT.toString());
- accessPoint.setValue(urlLocalizer.rewrite(serviceUrl));
- bindingTemplate.setAccessPoint(accessPoint);
+ bindingTemplate.setServiceKey(UDDIKeyConvention.getServiceKey(properties, serviceQName.getLocalPart()));
+
+ if (serviceUrl!=null) {
+ // Set AccessPoint
+ AccessPoint accessPoint = new AccessPoint();
+ accessPoint.setUseType(AccessPointType.END_POINT.toString());
+ accessPoint.setValue(urlLocalizer.rewrite(serviceUrl));
+ bindingTemplate.setAccessPoint(accessPoint);
+ // Set Binding Key
+ String bindingKey = UDDIKeyConvention.getBindingKey(properties, serviceQName, portName, serviceUrl);
+ bindingTemplate.setBindingKey(bindingKey);
+ }
Service service = wsdlDefinition.getService(serviceQName);
if (service!=null) {
@@ -628,6 +727,30 @@ public class WSDL2UDDI {
Port port = service.getPort(portName);
if (port!=null) {
+ if (serviceUrl==null) {
+ for (Object element: port.getExtensibilityElements()) {
+ if (element instanceof SOAPAddress) {
+ SOAPAddress address = (SOAPAddress) element;
+ URL locationURI;
+ try {
+ locationURI = new URL(address.getLocationURI());
+ if (locationURI!=null) {
+ AccessPoint accessPoint = new AccessPoint();
+ accessPoint.setUseType(AccessPointType.END_POINT.toString());
+ accessPoint.setValue(urlLocalizer.rewrite(locationURI));
+ bindingTemplate.setAccessPoint(accessPoint);
+ // Set Binding Key
+ String bindingKey = UDDIKeyConvention.getBindingKey(properties, serviceQName, portName, locationURI);
+ bindingTemplate.setBindingKey(bindingKey);
+ }
+ break;
+ } catch (MalformedURLException e) {
+ log.error(e.getMessage());
+ }
+ }
+ }
+
+ }
Binding binding = port.getBinding();
// Set the Binding Description
String bindingDescription = properties.getProperty(Property.BINDING_DESCRIPTION, Property.DEFAULT_BINDING_DESCRIPTION);
@@ -679,5 +802,26 @@ public class WSDL2UDDI {
return bindingTemplate;
}
+ /**
+ * Obtains the accessUrl from the WSDL
+ * @param port
+ * @return
+ * @throws MalformedURLException
+ */
+ private String getBindingURL(Port port) throws MalformedURLException {
+
+ String bindingUrl = null;
+ for (Object element: port.getExtensibilityElements()) {
+ if (element instanceof SOAPAddress) {
+ SOAPAddress address = (SOAPAddress) element;
+ URL locationURI = new URL(address.getLocationURI());
+ if (locationURI!=null) {
+ bindingUrl = urlLocalizer.rewrite(locationURI);
+ break;
+ }
+ }
+ }
+ return bindingUrl;
+ }
}
Modified: juddi/branches/juddi-3.2.x/juddi-client/src/main/java/org/apache/juddi/v3/client/mapping/WSDLLocatorImpl.java
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-client/src/main/java/org/apache/juddi/v3/client/mapping/WSDLLocatorImpl.java?rev=1481240&r1=1481239&r2=1481240&view=diff
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-client/src/main/java/org/apache/juddi/v3/client/mapping/WSDLLocatorImpl.java (original)
+++ juddi/branches/juddi-3.2.x/juddi-client/src/main/java/org/apache/juddi/v3/client/mapping/WSDLLocatorImpl.java Sat May 11 00:27:33 2013
@@ -19,6 +19,7 @@ package org.apache.juddi.v3.client.mappi
import java.io.IOException;
import java.io.InputStream;
+import java.io.StringReader;
import java.net.URI;
import java.net.URL;
@@ -26,117 +27,205 @@ import javax.wsdl.xml.WSDLLocator;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
+import org.apache.http.HttpEntity;
+import org.apache.http.HttpResponse;
+import org.apache.http.auth.AuthScope;
+import org.apache.http.auth.UsernamePasswordCredentials;
+import org.apache.http.client.ResponseHandler;
+import org.apache.http.client.methods.HttpGet;
+import org.apache.http.impl.client.BasicResponseHandler;
+import org.apache.http.impl.client.DefaultHttpClient;
import org.xml.sax.InputSource;
/**
- * Implementation of the interface {@link WSDLLocatorImpl}.
- *
- * @author <a href="mailto:kstam@apache.org">Kurt T Stam</a>
+ * Implementation of the interface {@link WSDLLocatorImpl}.
*
+ * @author <a href="mailto:kstam@apache.org">Kurt T Stam</a> Modified for
+ * support http based credentials by Alex O'Ree
*/
public class WSDLLocatorImpl implements WSDLLocator {
- private final Log log = LogFactory.getLog(this.getClass());
- private InputStream inputStream = null;
- private URI baseURI;
- private String latestImportURI;
- /**
- * Constructor taking the URI to the WSDL. This class implements the {@link WSDLLocatorImpl}
- * Interface.
- *
- * @param baseURI - URI of the WSDL
- */
- public WSDLLocatorImpl(URI baseURI) {
- this.baseURI = baseURI;
- }
- /**
- * @see WSDLLocatorImpl.getBaseInputSource
- */
- public InputSource getBaseInputSource() {
- InputSource inputSource = null;
- try {
- inputStream = baseURI.toURL().openStream();
- inputSource =new InputSource(inputStream);
- } catch (IOException e) {
- log.error(e.getMessage(),e);
- }
- return inputSource;
- }
- /**
- * Internal method to normalize the importUrl. The importLocation can be relative to
- * the parentLocation.
- *
- * @param parentLocation
- * @param importLocation
- * @return
- */
- protected URL constructImportUrl(String parentLocation, String importLocation) {
- URL importUrl = null;
- try {
- URI importLocationURI = new URI(importLocation);
- if (importLocationURI.getScheme()!=null || parentLocation==null) {
- importUrl = importLocationURI.toURL();
- } else {
- String parentDir = parentLocation.substring(0, parentLocation.lastIndexOf("/"));
- URI uri = new URI(parentDir + "/" + importLocation);
- importUrl = uri.normalize().toURL();
- }
- } catch (Exception e) {
- log.error(e.getMessage(),e);
- }
- if (importUrl != null)
- log.debug("importUrl: " + importUrl.toExternalForm());
- else
- log.error("importUrl is null!");
- return importUrl;
- }
-
- /**
- * @see WSDLLocatorImpl.getImportInputSource
- */
- public InputSource getImportInputSource(String parentLocation, String importLocation)
- {
- InputSource inputSource = null;
- try {
- URL importUrl = constructImportUrl(parentLocation, importLocation);
- InputStream inputStream = importUrl.openStream();
- inputSource = new InputSource(inputStream);
- latestImportURI = importUrl.toExternalForm();
- } catch (Exception e) {
- log.error(e.getMessage(),e);
- }
- return inputSource;
- }
- /**
- * @see WSDLLocatorImpl.getBaseURI
- */
- public String getBaseURI() {
- String baseURIStr = null;
- try {
- baseURIStr = baseURI.toURL().toExternalForm();
- } catch (IOException e) {
- log.error(e.getMessage(),e);
- }
- return baseURIStr;
- }
- /**
- * @see WSDLLocatorImpl.getLatestImportURI
- */
- public String getLatestImportURI() {
- return latestImportURI;
- }
- /**
- * @see WSDLLocatorImpl.close
- */
- public void close() {
- if (inputStream!=null) {
- try {
- inputStream.close();
- } catch (IOException e) {
- log.error(e.getMessage(),e);
- }
- }
- }
-
+ private final Log log = LogFactory.getLog(this.getClass());
+ private InputStream inputStream = null;
+ private URI baseURI;
+ private String latestImportURI;
+ private String username = null, password = null, domain = null;
+
+ /**
+ * Constructor taking the URI to the WSDL. This class implements the
+ * {@link WSDLLocatorImpl} Interface.
+ *
+ * @param baseURI - URI of the WSDL
+ */
+ public WSDLLocatorImpl(URI baseURI) {
+ this.baseURI = baseURI;
+ }
+
+ /**
+ * Constructor taking the URI to the WSDL. This class implements the
+ * {@link WSDLLocatorImpl} Interface and includes support for HTTP
+ * Authentication
+ *
+ * @param baseURI
+ * @param username
+ * @param password
+ * @param domain
+ */
+ public WSDLLocatorImpl(URI baseURI, String username, String password, String domain) {
+ this.baseURI = baseURI;
+ this.username = username;
+ this.password = password;
+ this.domain = domain;
+ }
+
+ /**
+ * @see WSDLLocatorImpl.getBaseInputSource
+ */
+ public InputSource getBaseInputSource() {
+ return getImportFromUrl(baseURI.toString());
+ }
+
+ /**
+ * Internal method to normalize the importUrl. The importLocation can be
+ * relative to the parentLocation.
+ *
+ * @param parentLocation
+ * @param importLocation
+ * @return
+ */
+ protected URL constructImportUrl(String parentLocation, String importLocation) {
+ URL importUrl = null;
+ try {
+ URI importLocationURI = new URI(importLocation);
+ if (importLocationURI.getScheme() != null || parentLocation == null) {
+ importUrl = importLocationURI.toURL();
+ } else {
+ String parentDir = parentLocation.substring(0, parentLocation.lastIndexOf("/"));
+ URI uri = new URI(parentDir + "/" + importLocation);
+ importUrl = uri.normalize().toURL();
+ }
+ } catch (Exception e) {
+ log.error(e.getMessage(), e);
+ }
+ if (importUrl != null) {
+ log.debug("importUrl: " + importUrl.toExternalForm());
+ } else {
+ log.error("importUrl is null!");
+ }
+ return importUrl;
+ }
+
+ private InputSource getImportFromUrl(String url) {
+ InputSource inputSource = null;
+ DefaultHttpClient httpclient = new DefaultHttpClient();
+ try {
+ URL url2 = new URL(url);
+ if (!url.toLowerCase().startsWith("http")) {
+ return getImportFromFile(url);
+ }
+
+ if (username != null && username.length() > 0
+ && password != null && password.length() > 0) {
+ int port = 80;
+ if (url.toLowerCase().startsWith("https://")) {
+ port = 443;
+ }
+
+ if (url2.getPort() > 0) {
+ port = url2.getPort();
+ }
+
+ httpclient.getCredentialsProvider().setCredentials(
+ new AuthScope(url2.getHost(), port),
+ new UsernamePasswordCredentials(username, password));
+ }
+ HttpGet httpGet = new HttpGet(url);
+ try {
+
+ HttpResponse response1 = httpclient.execute(httpGet);
+ //System.out.println(response1.getStatusLine());
+ // HttpEntity entity1 = response1.getEntity();
+ // do something useful with the response body
+ // and ensure it is fully consumed
+ ResponseHandler<String> responseHandler = new BasicResponseHandler();
+ String handleResponse = responseHandler.handleResponse(response1);
+ StringReader sr = new StringReader(handleResponse);
+ inputSource = new InputSource(sr);
+
+
+ } finally {
+ httpGet.releaseConnection();
+
+ }
+
+ // InputStream inputStream = importUrl.openStream();
+ //inputSource = new InputSource(inputStream);
+ latestImportURI = url;
+ } catch (Exception e) {
+ log.error(e.getMessage(), e);
+ } finally {
+ httpclient.getConnectionManager().shutdown();
+ }
+ return inputSource;
+ }
+
+ /**
+ * @see WSDLLocatorImpl.getImportInputSource
+ */
+ public InputSource getImportInputSource(String parentLocation, String importLocation) {
+ InputSource inputSource = null;
+ try {
+ URL importUrl = constructImportUrl(parentLocation, importLocation);
+ return getImportFromUrl(importUrl.toExternalForm());
+ } catch (Exception e) {
+ log.error(e.getMessage(), e);
+ }
+ return inputSource;
+ }
+
+ /**
+ * @see WSDLLocatorImpl.getBaseURI
+ */
+ public String getBaseURI() {
+ String baseURIStr = null;
+ try {
+ baseURIStr = baseURI.toURL().toExternalForm();
+ } catch (IOException e) {
+ log.error(e.getMessage(), e);
+ }
+ return baseURIStr;
+ }
+
+ /**
+ * @see WSDLLocatorImpl.getLatestImportURI
+ */
+ public String getLatestImportURI() {
+ return latestImportURI;
+ }
+
+ /**
+ * @see WSDLLocatorImpl.close
+ */
+ public void close() {
+ if (inputStream != null) {
+ try {
+ inputStream.close();
+ } catch (IOException e) {
+ log.error(e.getMessage(), e);
+ }
+ }
+ }
+
+ private InputSource getImportFromFile(String url) {
+ InputSource inputSource = null;
+ try {
+ URL importUrl = new URL(url);
+ inputStream = importUrl.openStream();
+ inputSource = new InputSource(inputStream);
+ latestImportURI = importUrl.toExternalForm();
+ } catch (Exception e) {
+ log.error(e.getMessage(), e);
+ }
+ return inputSource;
+ }
}
-
Modified: juddi/branches/juddi-3.2.x/juddi-client/src/test/java/org/apache/juddi/v3/client/mapping/BPEL2UDDITest.java
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-client/src/test/java/org/apache/juddi/v3/client/mapping/BPEL2UDDITest.java?rev=1481240&r1=1481239&r2=1481240&view=diff
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-client/src/test/java/org/apache/juddi/v3/client/mapping/BPEL2UDDITest.java (original)
+++ juddi/branches/juddi-3.2.x/juddi-client/src/test/java/org/apache/juddi/v3/client/mapping/BPEL2UDDITest.java Sat May 11 00:27:33 2013
@@ -27,6 +27,7 @@ import javax.wsdl.WSDLException;
import javax.xml.bind.JAXBException;
import javax.xml.namespace.QName;
+import org.apache.commons.configuration.ConfigurationException;
import org.apache.juddi.jaxb.PrintUDDI;
import org.junit.Assert;
import org.junit.BeforeClass;
@@ -48,11 +49,11 @@ public class BPEL2UDDITest {
ReadWSDL rw = new ReadWSDL();
@BeforeClass
- public static void before() throws JAXBException {
+ public static void before() throws JAXBException, ConfigurationException {
Properties properties = new Properties();
properties.put("keyDomain", "juddi.apache.org");
properties.put("nodeName", "localhost");
- URLLocalizer urlLocalizer = new URLLocalizerImpl();
+ URLLocalizer urlLocalizer = new URLLocalizerDefaultImpl();
bpel2UDDI = new BPEL2UDDI(null, urlLocalizer, properties);
}
Modified: juddi/branches/juddi-3.2.x/juddi-client/src/test/java/org/apache/juddi/v3/client/mapping/ReadWSDLTest.java
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-client/src/test/java/org/apache/juddi/v3/client/mapping/ReadWSDLTest.java?rev=1481240&r1=1481239&r2=1481240&view=diff
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-client/src/test/java/org/apache/juddi/v3/client/mapping/ReadWSDLTest.java (original)
+++ juddi/branches/juddi-3.2.x/juddi-client/src/test/java/org/apache/juddi/v3/client/mapping/ReadWSDLTest.java Sat May 11 00:27:33 2013
@@ -14,7 +14,9 @@
*/
package org.apache.juddi.v3.client.mapping;
+import java.net.MalformedURLException;
import java.net.URISyntaxException;
+import java.net.URL;
import javax.wsdl.Definition;
import javax.wsdl.WSDLException;
@@ -27,20 +29,27 @@ import org.junit.Test;
*/
public class ReadWSDLTest {
- @Test
- public void readFromFile() throws WSDLException, URISyntaxException {
-
- ReadWSDL readWSDL = new ReadWSDL();
- Definition definition = readWSDL.readWSDL("wsdl/HelloWorld.wsdl");
- Assert.assertNotNull(definition);
- }
-
- @Test
- public void readFromJar() throws WSDLException, URISyntaxException {
-
- ReadWSDL readWSDL = new ReadWSDL();
- Definition definition = readWSDL.readWSDL("uddi_v3_service.wsdl");
- Assert.assertNotNull(definition);
- }
-
+ @Test
+ public void readFromFile() throws WSDLException, URISyntaxException {
+
+ ReadWSDL readWSDL = new ReadWSDL();
+ Definition definition = readWSDL.readWSDL("wsdl/HelloWorld.wsdl");
+ Assert.assertNotNull(definition);
+ }
+
+ @Test
+ public void readFromURL() throws WSDLException, URISyntaxException, MalformedURLException {
+
+ ReadWSDL readWSDL = new ReadWSDL();
+ Definition definition = readWSDL.readWSDL(new URL("http://graphical.weather.gov/xml/SOAP_server/ndfdXMLserver.php?wsdl"));
+ Assert.assertNotNull(definition);
+ }
+
+ @Test
+ public void readFromJar() throws WSDLException, URISyntaxException {
+
+ ReadWSDL readWSDL = new ReadWSDL();
+ Definition definition = readWSDL.readWSDL("uddi_v3_service.wsdl");
+ Assert.assertNotNull(definition);
+ }
}
Modified: juddi/branches/juddi-3.2.x/juddi-client/src/test/java/org/apache/juddi/v3/client/mapping/ServiceLocatorTest.java
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-client/src/test/java/org/apache/juddi/v3/client/mapping/ServiceLocatorTest.java?rev=1481240&r1=1481239&r2=1481240&view=diff
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-client/src/test/java/org/apache/juddi/v3/client/mapping/ServiceLocatorTest.java (original)
+++ juddi/branches/juddi-3.2.x/juddi-client/src/test/java/org/apache/juddi/v3/client/mapping/ServiceLocatorTest.java Sat May 11 00:27:33 2013
@@ -39,7 +39,7 @@ public class ServiceLocatorTest {
Properties properties = new Properties();
- ServiceLocator locator = new ServiceLocator(null, new URLLocalizerImpl(), properties);
+ ServiceLocator locator = new ServiceLocator(null, new URLLocalizerDefaultImpl(), properties);
System.out.println(locator);
locator.shutdown();
} catch (Exception e) {
Modified: juddi/branches/juddi-3.2.x/juddi-client/src/test/java/org/apache/juddi/v3/client/mapping/WSDL2UDDITest.java
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-client/src/test/java/org/apache/juddi/v3/client/mapping/WSDL2UDDITest.java?rev=1481240&r1=1481239&r2=1481240&view=diff
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-client/src/test/java/org/apache/juddi/v3/client/mapping/WSDL2UDDITest.java (original)
+++ juddi/branches/juddi-3.2.x/juddi-client/src/test/java/org/apache/juddi/v3/client/mapping/WSDL2UDDITest.java Sat May 11 00:27:33 2013
@@ -26,6 +26,7 @@ import javax.wsdl.WSDLException;
import javax.xml.bind.JAXBException;
import javax.xml.namespace.QName;
+import org.apache.commons.configuration.ConfigurationException;
import org.apache.juddi.jaxb.PrintUDDI;
import org.junit.Assert;
import org.junit.Test;
@@ -40,7 +41,7 @@ public class WSDL2UDDITest {
ReadWSDL rw = new ReadWSDL();
@Test
- public void testUDDIBindingModel() throws WSDLException, JAXBException {
+ public void testUDDIBindingModel() throws WSDLException, JAXBException, ConfigurationException {
// Reading the WSDL
Definition wsdlDefinition = rw.readWSDL("wsdl/HelloWorld.wsdl");
@@ -48,7 +49,7 @@ public class WSDL2UDDITest {
Properties properties = new Properties();
properties.put("keyDomain", "juddi.apache.org");
- WSDL2UDDI wsdl2UDDI = new WSDL2UDDI(null, new URLLocalizerImpl(), properties);
+ WSDL2UDDI wsdl2UDDI = new WSDL2UDDI(null, new URLLocalizerDefaultImpl(), properties);
Set<TModel> tModels = new HashSet<TModel>();
@SuppressWarnings("unchecked")
Map<QName,PortType> portTypes = (Map<QName,PortType>) wsdlDefinition.getAllPortTypes();
@@ -63,7 +64,7 @@ public class WSDL2UDDITest {
}
@Test
- public void testWSDLBindingModel() throws WSDLException, JAXBException {
+ public void testWSDLBindingModel() throws WSDLException, JAXBException, ConfigurationException {
// Reading the WSDL
Definition wsdlDefinition = rw.readWSDL("wsdl/HelloWorld.wsdl");
@@ -71,7 +72,7 @@ public class WSDL2UDDITest {
Properties properties = new Properties();
properties.put("keyDomain", "juddi.apache.org");
- WSDL2UDDI wsdl2UDDI = new WSDL2UDDI(null, new URLLocalizerImpl(), properties);
+ WSDL2UDDI wsdl2UDDI = new WSDL2UDDI(null, new URLLocalizerDefaultImpl(), properties);
Set<TModel> tModels = new HashSet<TModel>();
@SuppressWarnings("unchecked")
Map<QName,Binding> bindings= (Map<QName,Binding>) wsdlDefinition.getAllBindings();
Modified: juddi/branches/juddi-3.2.x/juddi-core-openjpa/src/test/resources/juddiv3.properties
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-core-openjpa/src/test/resources/juddiv3.properties?rev=1481240&r1=1481239&r2=1481240&view=diff
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-core-openjpa/src/test/resources/juddiv3.properties (original)
+++ juddi/branches/juddi-3.2.x/juddi-core-openjpa/src/test/resources/juddiv3.properties Sat May 11 00:27:33 2013
@@ -87,4 +87,38 @@ juddi.auth.token.Timeout=15
# tModelinstanceparms and anything else that references a KeyName
# default value is true.
# set to false for backwards compatibility or for a more lax registry
-juddi.validation.enforceReferentialIntegrity=true
\ No newline at end of file
+juddi.validation.enforceReferentialIntegrity=true
+
+#As of 3.1.5 Email delivery options for subscription API functions
+
+#uddi.mail.smtp.from
+##The Operatorâs Email address
+
+#juddi.mail.smtp.host
+##The hostname of the SMTP server
+
+#juddi.mail.smtp.port
+##The portname of the SMTP server
+
+#juddi.mail.smtp.socketFactory.class
+##If set, specifies the name of a class that implements the javax.net.SocketFactory interface. This class will be used to create SMTP sockets.
+
+#juddi.mail.smtp.socketFactory.fallback
+##If set to true, failure to create a socket using the specified socket factory class will cause the socket to be created using the java.net.Socket class. Defaults to true.
+
+#juddi.mail.smtp.starttls.enable
+##if true, enables the use of the STARTTLS command (if supported by the server) to switch the connection to a TLS-protected connection before issuing any login commands. Note that an appropriate trust store must configured so that the client will trust the serverâs certificate. Defaults to false.
+
+#juddi.mail.smtp.socketFactory.port
+##Specifies the port to connect to when using the specified socket factory. If not set, the default port will be used.
+
+#juddi.mail.smtp.auth
+##If true, attempt to authenticate the user using the AUTH command. Defaults to false.
+
+#juddi.mail.smtp.username
+##Username used to authenticate to the SMTP server
+##used only if juddi.mail.smtp.auth is true
+
+#juddi.mail.smtp.password
+##Password used to authenticate to the SMTP server
+##used only if juddi.mail.smtp.auth is true
\ No newline at end of file
Modified: juddi/branches/juddi-3.2.x/juddi-core/src/main/java/org/apache/juddi/subscription/notify/SMTPNotifier.java
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-core/src/main/java/org/apache/juddi/subscription/notify/SMTPNotifier.java?rev=1481240&r1=1481239&r2=1481240&view=diff
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-core/src/main/java/org/apache/juddi/subscription/notify/SMTPNotifier.java (original)
+++ juddi/branches/juddi-3.2.x/juddi-core/src/main/java/org/apache/juddi/subscription/notify/SMTPNotifier.java Sat May 11 00:27:33 2013
@@ -8,6 +8,7 @@ import java.util.Properties;
import javax.mail.Address;
import javax.mail.Message.RecipientType;
+import javax.mail.PasswordAuthentication;
import javax.mail.Session;
import javax.mail.Transport;
import javax.mail.internet.InternetAddress;
@@ -37,7 +38,7 @@ public class SMTPNotifier implements Not
private final static String[] mailProps = {"mail.smtp.from", "mail.smtp.host", "mail.smtp.port",
"mail.smtp.socketFactory.class", "mail.smtp.socketFactory.fallback", "mail.smtp.starttls.enable",
- "mail.smtp.socketFactory.port","mail.smtp.auth"};
+ "mail.smtp.socketFactory.port","mail.smtp.auth","mail.smtp.user","mail.smtp.password"};
protected Properties getEMailProperties() throws ConfigurationException {
if (properties==null) {
@@ -88,10 +89,20 @@ public class SMTPNotifier implements Not
if (!accessPointUrl.startsWith("mailto:")) {
log.warn("smtp accessPointUrl for bindingTemplate " + bindingTemplate.getEntityKey() +
" should start with 'mailto'");
- //TODO maybe update the user's bindingTemplate with the error?
+ //TODO maybe update the user's bindingTemplate with the error?, and also validate setting onsave
} else {
notificationEmailAddress = accessPointUrl.substring(accessPointUrl.indexOf(":")+1);
- session = Session.getInstance(getEMailProperties());
+ if (Boolean.getBoolean(getEMailProperties().getProperty("mail.smtp.starttls.enable"))) {
+ final String username = getEMailProperties().getProperty("mail.smtp.username");
+ final String password = getEMailProperties().getProperty("mail.smtp.password");
+ session = Session.getInstance(getEMailProperties(), new javax.mail.Authenticator() {
+ protected PasswordAuthentication getPasswordAuthentication() {
+ return new PasswordAuthentication(username, password);
+ }
+ });
+ } else {
+ session = Session.getInstance(getEMailProperties());
+ }
}
}
Modified: juddi/branches/juddi-3.2.x/juddi-core/src/test/resources/juddiv3.properties
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-core/src/test/resources/juddiv3.properties?rev=1481240&r1=1481239&r2=1481240&view=diff
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-core/src/test/resources/juddiv3.properties (original)
+++ juddi/branches/juddi-3.2.x/juddi-core/src/test/resources/juddiv3.properties Sat May 11 00:27:33 2013
@@ -59,9 +59,6 @@ juddi.subscription.chunkexpiration.minut
# jUDDI Authentication module to use
juddi.authenticator = org.apache.juddi.v3.auth.JUDDIAuthenticator
#
-# jUDDI UUIDGen implementation to use
-juddi.uuidgen = org.apache.juddi.uuidgen.DefaultUUIDGen
-#
# jUDDI Cryptor implementation to use
juddi.cryptor = org.apache.juddi.cryptor.DefaultCryptor
#
@@ -88,4 +85,39 @@ juddi.auth.token.Timeout=15
# tModelinstanceparms and anything else that references a KeyName
# default value is true.
# set to false for backwards compatibility or for a more lax registry
-juddi.validation.enforceReferentialIntegrity=true
\ No newline at end of file
+juddi.validation.enforceReferentialIntegrity=true
+
+
+#As of 3.1.5 Email delivery options for subscription API functions
+
+#uddi.mail.smtp.from
+##The Operatorâs Email address
+
+#juddi.mail.smtp.host
+##The hostname of the SMTP server
+
+#juddi.mail.smtp.port
+##The portname of the SMTP server
+
+#juddi.mail.smtp.socketFactory.class
+##If set, specifies the name of a class that implements the javax.net.SocketFactory interface. This class will be used to create SMTP sockets.
+
+#juddi.mail.smtp.socketFactory.fallback
+##If set to true, failure to create a socket using the specified socket factory class will cause the socket to be created using the java.net.Socket class. Defaults to true.
+
+#juddi.mail.smtp.starttls.enable
+##if true, enables the use of the STARTTLS command (if supported by the server) to switch the connection to a TLS-protected connection before issuing any login commands. Note that an appropriate trust store must configured so that the client will trust the serverâs certificate. Defaults to false.
+
+#juddi.mail.smtp.socketFactory.port
+##Specifies the port to connect to when using the specified socket factory. If not set, the default port will be used.
+
+#juddi.mail.smtp.auth
+##If true, attempt to authenticate the user using the AUTH command. Defaults to false.
+
+#juddi.mail.smtp.username
+##Username used to authenticate to the SMTP server
+##used only if juddi.mail.smtp.auth is true
+
+#juddi.mail.smtp.password
+##Password used to authenticate to the SMTP server
+##used only if juddi.mail.smtp.auth is true
\ No newline at end of file
Modified: juddi/branches/juddi-3.2.x/juddi-examples/hello-world/src/main/java/org/apache/juddi/example/helloworld/HelloWorld.java
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-examples/hello-world/src/main/java/org/apache/juddi/example/helloworld/HelloWorld.java?rev=1481240&r1=1481239&r2=1481240&view=diff
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-examples/hello-world/src/main/java/org/apache/juddi/example/helloworld/HelloWorld.java (original)
+++ juddi/branches/juddi-3.2.x/juddi-examples/hello-world/src/main/java/org/apache/juddi/example/helloworld/HelloWorld.java Sat May 11 00:27:33 2013
@@ -30,8 +30,6 @@ public class HelloWorld {
// create a manager and read the config in the archive;
// you can use your config file name
UDDIClerkManager clerkManager = new UDDIClerkManager("META-INF/hello-world-uddi.xml");
- // register the clerkManager with the client side container
- UDDIClientContainer.addClerkManager(clerkManager);
// a ClerkManager can be a client to multiple UDDI nodes, so
// supply the nodeName (defined in your uddi.xml.
// The transport can be WS, inVM, RMI etc which is defined in the uddi.xml
Modified: juddi/branches/juddi-3.2.x/juddi-examples/pom.xml
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-examples/pom.xml?rev=1481240&r1=1481239&r2=1481240&view=diff
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-examples/pom.xml (original)
+++ juddi/branches/juddi-3.2.x/juddi-examples/pom.xml Sat May 11 00:27:33 2013
@@ -32,5 +32,7 @@
<module>simple-browse</module>
<module>simple-publish</module>
<module>uddi-annotations</module>
+ <module>wsdl2uddi</module>
+ <module>wsdl2uddi-lifecyle</module>
</modules>
-</project>
\ No newline at end of file
+</project>
Modified: juddi/branches/juddi-3.2.x/juddi-examples/uddi-annotations/src/main/resources/META-INF/sales-uddi.xml
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-examples/uddi-annotations/src/main/resources/META-INF/sales-uddi.xml?rev=1481240&r1=1481239&r2=1481240&view=diff
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-examples/uddi-annotations/src/main/resources/META-INF/sales-uddi.xml (original)
+++ juddi/branches/juddi-3.2.x/juddi-examples/uddi-annotations/src/main/resources/META-INF/sales-uddi.xml Sat May 11 00:27:33 2013
@@ -24,7 +24,7 @@
</nodes>
<clerks registerOnStartup="true">
<clerk name="BobCratchit" node="default" publisher="sales" password="sales">
- <class>org.apache.juddi.samples.HelloWorldImpl</class>
+ <class>org.apache.juddi.example.HelloWorldImpl</class>
</clerk>
</clerks>
</manager>
Modified: juddi/branches/juddi-3.2.x/juddi-examples/uddi-annotations/src/main/resources/META-INF/uddi-annotations.xml
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-examples/uddi-annotations/src/main/resources/META-INF/uddi-annotations.xml?rev=1481240&r1=1481239&r2=1481240&view=diff
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-examples/uddi-annotations/src/main/resources/META-INF/uddi-annotations.xml (original)
+++ juddi/branches/juddi-3.2.x/juddi-examples/uddi-annotations/src/main/resources/META-INF/uddi-annotations.xml Sat May 11 00:27:33 2013
@@ -24,7 +24,7 @@
</nodes>
<clerks registerOnStartup="true">
<clerk name="ROOTClerk" node="default" publisher="root" password="root">
- <class>org.apache.juddi.samples.HelloWorldImpl</class>
+ <class>org.apache.juddi.example.HelloWorldImpl</class>
</clerk>
</clerks>
</manager>
Modified: juddi/branches/juddi-3.2.x/juddi-examples/uddi-annotations/src/main/webapp/WEB-INF/beans.xml
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-examples/uddi-annotations/src/main/webapp/WEB-INF/beans.xml?rev=1481240&r1=1481239&r2=1481240&view=diff
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-examples/uddi-annotations/src/main/webapp/WEB-INF/beans.xml (original)
+++ juddi/branches/juddi-3.2.x/juddi-examples/uddi-annotations/src/main/webapp/WEB-INF/beans.xml Sat May 11 00:27:33 2013
@@ -24,7 +24,7 @@
<import resource="classpath:META-INF/cxf/cxf-extension-soap.xml" />
<import resource="classpath:META-INF/cxf/cxf-servlet.xml" />
- <jaxws:endpoint id="helloworld" implementor="org.apache.juddi.samples.HelloWorldImpl"
+ <jaxws:endpoint id="helloworld" implementor="org.apache.juddi.example.HelloWorldImpl"
address="/helloworld" />
</beans>
Modified: juddi/branches/juddi-3.2.x/juddi-examples/uddi-annotations/src/main/webapp/WEB-INF/classes/juddiv3.properties
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-examples/uddi-annotations/src/main/webapp/WEB-INF/classes/juddiv3.properties?rev=1481240&r1=1481239&r2=1481240&view=diff
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-examples/uddi-annotations/src/main/webapp/WEB-INF/classes/juddiv3.properties (original)
+++ juddi/branches/juddi-3.2.x/juddi-examples/uddi-annotations/src/main/webapp/WEB-INF/classes/juddiv3.properties Sat May 11 00:27:33 2013
@@ -90,15 +90,44 @@ juddi.server.port=8080
# Duration of time for tokens to expire
juddi.auth.token.Timeout=15
-
-# As of 3.1.5
-# Duration of time for tokens to expire
-juddi.auth.token.Timeout=15
-
# As of 3.1.5
# This setting will force referential integrity for all tModels (except keyGenerators),
# category bags, bindingTemplate/AccessPoint/hostingRedirector (referencing another host),
# tModelinstanceparms and anything else that references a KeyName
# default value is true.
# set to false for backword compatability or for a more lax registry
-juddi.validation.enforceReferentialIntegrity=false
\ No newline at end of file
+juddi.validation.enforceReferentialIntegrity=false
+
+#As of 3.1.5 Email delivery options for subscription API functions
+
+#uddi.mail.smtp.from
+##The Operatorâs Email address
+
+#juddi.mail.smtp.host
+##The hostname of the SMTP server
+
+#juddi.mail.smtp.port
+##The portname of the SMTP server
+
+#juddi.mail.smtp.socketFactory.class
+##If set, specifies the name of a class that implements the javax.net.SocketFactory interface. This class will be used to create SMTP sockets.
+
+#juddi.mail.smtp.socketFactory.fallback
+##If set to true, failure to create a socket using the specified socket factory class will cause the socket to be created using the java.net.Socket class. Defaults to true.
+
+#juddi.mail.smtp.starttls.enable
+##if true, enables the use of the STARTTLS command (if supported by the server) to switch the connection to a TLS-protected connection before issuing any login commands. Note that an appropriate trust store must configured so that the client will trust the serverâs certificate. Defaults to false.
+
+#juddi.mail.smtp.socketFactory.port
+##Specifies the port to connect to when using the specified socket factory. If not set, the default port will be used.
+
+#juddi.mail.smtp.auth
+##If true, attempt to authenticate the user using the AUTH command. Defaults to false.
+
+#juddi.mail.smtp.username
+##Username used to authenticate to the SMTP server
+##used only if juddi.mail.smtp.auth is true
+
+#juddi.mail.smtp.password
+##Password used to authenticate to the SMTP server
+##used only if juddi.mail.smtp.auth is true
\ No newline at end of file
Propchange: juddi/branches/juddi-3.2.x/juddi-examples/wsdl2uddi/
------------------------------------------------------------------------------
--- svn:ignore (added)
+++ svn:ignore Sat May 11 00:27:33 2013
@@ -0,0 +1,4 @@
+.settings
+target
+.classpath
+.project
Propchange: juddi/branches/juddi-3.2.x/juddi-examples/wsdl2uddi-lifecyle/
------------------------------------------------------------------------------
--- svn:ignore (added)
+++ svn:ignore Sat May 11 00:27:33 2013
@@ -0,0 +1,4 @@
+.settings
+.classpath
+.project
+target
Modified: juddi/branches/juddi-3.2.x/juddi-examples/wsdl2uddi-lifecyle/README.txt
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-examples/wsdl2uddi-lifecyle/README.txt?rev=1481240&r1=1480510&r2=1481240&view=diff
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-examples/wsdl2uddi-lifecyle/README.txt (original)
+++ juddi/branches/juddi-3.2.x/juddi-examples/wsdl2uddi-lifecyle/README.txt Sat May 11 00:27:33 2013
@@ -7,36 +7,75 @@ This example is a command line demonstra
3. Create Joe Publisher and his keyGenerator and then register the services in wsdl/helloworld.wsdl to jUDDI.
it creates a businessEntity with businessKey 'uddi:uddi.joepublisher.com:business-for-wsdl'
-mvn -Ppublish test
+mvn -Psetup test
You should see the following output being written to the console:
-[INFO] --- exec-maven-plugin:1.1.1:java (default) @ wsdl2uddi ---
-May 08, 2013 12:14:41 PM org.apache.juddi.v3.client.config.ClientConfig loadConfiguration
-INFO: Reading UDDI Client properties file file:/Users/kstam/osc/apache/dev/juddi-patch/juddi-examples/wsdl2uddi/target/classes/META-INF/wsdl2uddi-uddi.xml
-root AUTHTOKEN = authtoken:459d0ac2-cb6c-4dde-813f-1ddba4b99f20
-May 08, 2013 12:14:48 PM org.apache.juddi.v3.client.config.UDDIClerk register
-INFO: Registering tModel with key uddi:uddi.joepublisher.com:keygenerator
-May 08, 2013 12:14:49 PM org.apache.juddi.v3.client.config.UDDIClerk register
+...
+
+May 08, 2013 9:23:07 PM org.apache.juddi.v3.client.config.UDDIClerk register
INFO: Registering business WSDL-Business with key uddi:uddi.joepublisher.com:business-for-wsdl
-Retrieving document at 'file:/Users/kstam/osc/apache/dev/juddi-patch/juddi-examples/wsdl2uddi/target/classes/wsdl/helloworld.wsdl'.
-May 08, 2013 12:14:49 PM org.uddi.JAXBContextUtil getContext
-INFO: Creating JAXB Context for org.uddi.api_v3
-May 08, 2013 12:14:49 PM org.apache.juddi.v3.client.config.UDDIClerk checkForErrorInDispositionReport
-INFO: entityKey uddi:uddi.joepublisher.com:service_helloworld was not found in the registry
-May 08, 2013 12:14:49 PM org.apache.juddi.v3.client.config.UDDIClerk register
-INFO: Registering tModel with key uddi:uddi.joepublisher.com:HelloWorld
-May 08, 2013 12:14:49 PM org.apache.juddi.v3.client.config.UDDIClerk register
-INFO: Registering tModel with key uddi:uddi.joepublisher.com:HelloWorldSoapBinding
-May 08, 2013 12:14:49 PM org.apache.juddi.v3.client.config.UDDIClerk register
-INFO: Registering service HelloWorld with key uddi:uddi.joepublisher.com:service_helloworld
-May 08, 2013 12:14:49 PM org.apache.juddi.v3.client.config.UDDIClerk register
-INFO: Registering bindingTemplate with key uddi:uddi.joepublisher.com:binding_localhost_helloworld_helloworldimplport_8080
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
-4. Check that we can find this business in the registry by running from Queries
+4. Build the wsdl2uddi.war:
+
+mvn clean package
+
+5. Now that the business is there, we can deploy the wsdl2uddi.war which contains the
+JAX-WS HelloWorld WebService and it deploys its wsdl (in wsdl/HelloWorld.wsdl). So on deployment
+it brings up the WebService AND it registers it to UDDI.
+
+From the distro use:
+
+mvn -Pdeploy cargo:deploy
+
+when in src tree tomcat is in a different location, so use the deploydev profile:
+
+mvn -Pdeploydev cargo:deploy
+
+[INFO] Scanning for projects...
+[INFO]
+[INFO] ------------------------------------------------------------------------
+[INFO] Building jUDDI Example WSDL2UDDI Deployment Lifecycle 3.1.5-SNAPSHOT
+[INFO] ------------------------------------------------------------------------
+[INFO]
+[INFO] --- cargo-maven2-plugin:1.3.3:deploy (default-cli) @ wsdl2uddi-lifecycle ---
+[INFO] [edDeployerDeployMojo] Resolved container artifact org.codehaus.cargo:cargo-core-container-tomcat:jar:1.3.3 for container tomcat6x
+[INFO] [stalledLocalDeployer] Deploying [/Users/kstam/osc/apache/dev/juddi-patch/juddi-examples/wsdl2uddi-lifecyle/target/wsdl2uddi.war] to [/Users/kstam/osc/apache/dev/juddi-patch/juddi-examples/wsdl2uddi-lifecyle/../../juddi-tomcat/target/tomcat/apache-tomcat-6.0.26/webapps]...
+[INFO] ------------------------------------------------------------------------
+[INFO] BUILD SUCCESS
+[INFO] ------------------------------------------------------------------------
+
+while on the server in the <tomcat>/logs/juddi.log it should say:
+
+Bringing up the endpoint:
+2013-05-08 21:31:51,763 INFO [org.springframework.web.context.ContextLoader] - Root WebApplicationContext: initialization started
+2013-05-08 21:31:51,792 INFO [org.springframework.web.context.support.XmlWebApplicationContext] - Refreshing Root WebApplicationContext: startup date [Wed May 08 21:31:51 EDT 2013]; root of context hierarchy
+2013-05-08 21:31:51,831 INFO [org.springframework.beans.factory.xml.XmlBeanDefinitionReader] - Loading XML bean definitions from ServletContext resource [/WEB-INF/beans.xml]
+2013-05-08 21:31:51,856 INFO [org.springframework.beans.factory.xml.XmlBeanDefinitionReader] - Loading XML bean definitions from class path resource [META-INF/cxf/cxf.xml]
+2013-05-08 21:31:51,875 INFO [org.springframework.beans.factory.xml.XmlBeanDefinitionReader] - Loading XML bean definitions from class path resource [META-INF/cxf/cxf-extension-soap.xml]
+2013-05-08 21:31:51,885 INFO [org.springframework.beans.factory.xml.XmlBeanDefinitionReader] - Loading XML bean definitions from class path resource [META-INF/cxf/cxf-servlet.xml]
+2013-05-08 21:31:51,892 INFO [org.springframework.beans.factory.xml.XmlBeanDefinitionReader] - Loading XML bean definitions from class path resource [META-INF/cxf/cxf-extension-http.xml]
+2013-05-08 21:31:52,038 INFO [org.springframework.beans.factory.support.DefaultListableBeanFactory] - Pre-instantiating singletons in org.springframework.beans.factory.support.DefaultListableBeanFactory@21e7937: defining beans [cxf,org.apache.cxf.bus.spring.BusApplicationListener,org.apache.cxf.bus.spring.BusWiringBeanFactoryPostProcessor,org.apache.cxf.bus.spring.Jsr250BeanPostProcessor,org.apache.cxf.bus.spring.BusExtensionPostProcessor,org.apache.cxf.resource.ResourceManager,org.apache.cxf.configuration.Configurer,org.apache.cxf.binding.BindingFactoryManager,org.apache.cxf.transport.DestinationFactoryManager,org.apache.cxf.transport.ConduitInitiatorManager,org.apache.cxf.wsdl.WSDLManager,org.apache.cxf.phase.PhaseManager,org.apache.cxf.workqueue.WorkQueueManager,org.apache.cxf.buslifecycle.BusLifeCycleManager,org.apache.cxf.endpoint.ServerRegistry,org.apache.cxf.endpoint.ServerLifeCycleManager,org.apache.cxf.endpoint.ClientLifeCycleManager,org.apache.cxf.transports.http.Q
ueryHandlerRegistry,org.apache.cxf.endpoint.EndpointResolverRegistry,org.apache.cxf.headers.HeaderManager,org.apache.cxf.catalog.OASISCatalogManager,org.apache.cxf.service.factory.FactoryBeanListenerManager,org.apache.cxf.endpoint.ServiceContractResolverRegistry,org.apache.cxf.binding.soap.SoapBindingFactory,org.apache.cxf.binding.soap.SoapTransportFactory,org.apache.cxf.binding.soap.customEditorConfigurer,org.apache.cxf.transport.http.policy.HTTPClientAssertionBuilder,org.apache.cxf.transport.http.policy.HTTPServerAssertionBuilder,org.apache.cxf.transport.http.policy.NoOpPolicyInterceptorProvider,org.apache.cxf.transport.http.ClientOnlyHTTPTransportFactory,org.apache.cxf.transport.servlet.ServletTransportFactory,helloworld]; root of factory hierarchy
+2013-05-08 21:31:52,736 INFO [org.springframework.web.context.ContextLoader] - Root WebApplicationContext: initialization completed in 973 ms
+2013-05-08 21:31:52,744 INFO [org.apache.cxf.bus.spring.BusApplicationContext] - Refreshing org.apache.cxf.bus.spring.BusApplicationContext@f8ffe0b: startup date [Wed May 08 21:31:52 EDT 2013]; parent: Root WebApplicationContext
+2013-05-08 21:31:52,769 INFO [org.springframework.beans.factory.support.DefaultListableBeanFactory] - Pre-instantiating singletons in org.springframework.beans.factory.support.DefaultListableBeanFactory@e161e1f: defining beans []; parent: org.springframework.beans.factory.support.DefaultListableBeanFactory@21e7937
+Reading the clientside config: wsdl2uddi-uddi.xml:
+2013-05-08 21:31:52,780 INFO [org.apache.juddi.v3.client.config.WebHelper] - Reading the managerName from the clientConfig file /META-INF/wsdl2uddi-uddi.xml
+2013-05-08 21:31:52,822 INFO [org.apache.juddi.v3.client.config.ClientConfig] - Reading UDDI Client properties file file:/Users/kstam/osc/apache/dev/juddi-patch/juddi-tomcat/target/tomcat/apache-tomcat-6.0.26/webapps/wsdl2uddi/WEB-INF/classes/META-INF/wsdl2uddi-uddi.xml
+2013-05-08 21:31:52,869 INFO [org.apache.juddi.v3.client.config.WebHelper] - Starting Clerk Manager example-manager...
+2013-05-08 21:31:56,996 INFO [org.uddi.JAXBContextUtil] - Creating JAXB Context for org.uddi.api_v3
+Registering the WSDL:
+2013-05-08 21:31:57,083 INFO [org.apache.juddi.v3.client.config.UDDIClerk] - entityKey uddi:uddi.joepublisher.com:service_helloworld was not found in the registry
+2013-05-08 21:31:57,141 INFO [org.apache.juddi.v3.client.config.UDDIClerk] - Registering tModel with key uddi:uddi.joepublisher.com:HelloWorld
+2013-05-08 21:31:57,366 INFO [org.apache.juddi.v3.client.config.UDDIClerk] - Registering tModel with key uddi:uddi.joepublisher.com:HelloWorldSoapBinding
+2013-05-08 21:31:58,396 INFO [org.apache.juddi.v3.client.config.UDDIClerk] - Registering service HelloWorld with key uddi:uddi.joepublisher.com:service_helloworld
+2013-05-08 21:31:58,421 INFO [org.apache.juddi.v3.client.config.UDDIClerk] - Registering bindingTemplate with key uddi:uddi.joepublisher.com:binding_localhost_helloworld_helloworldimplport_8080
+
+
+6. Check that we can find this business in the registry by running from Queries
mvn -Pfind test
@@ -61,9 +100,42 @@ BindingTemplates: 1
So we got one Service, which one binding. Note that the descriptions were provided in the wsdl file
using <wsdl:documentation> elements.
-5. Finally to remove all data structures call
+7. Finally to undeploy the wsdl2uddi.war call
+
+From the distro use:
+
+mvn -Pdeploy cargo:undeploy
+
+when in src tree tomcat is in a different location, so use the deploydev profile:
-mvn -Pdelete test
+mvn -Pdeploydev cargo:undeploy
+
+This removes the HelloWorld WebService and removes the data from the UDDI server.
+
+ClientSide logging:
+[INFO] Scanning for projects...
+[INFO]
+[INFO] ------------------------------------------------------------------------
+[INFO] Building jUDDI Example WSDL2UDDI Deployment Lifecycle 3.1.5-SNAPSHOT
+[INFO] ------------------------------------------------------------------------
+[INFO]
+[INFO] --- cargo-maven2-plugin:1.3.3:undeploy (default-cli) @ wsdl2uddi-lifecycle ---
+[INFO] [DeployerUndeployMojo] Resolved container artifact org.codehaus.cargo:cargo-core-container-tomcat:jar:1.3.3 for container tomcat6x
+[INFO] [stalledLocalDeployer] Undeploying context [wsdl2uddi] from [/Users/kstam/osc/apache/dev/juddi-patch/juddi-examples/wsdl2uddi-lifecyle/../../juddi-tomcat/target/tomcat/apache-tomcat-6.0.26/webapps]...
+[INFO] [stalledLocalDeployer] Trying to delete WAR from [/Users/kstam/osc/apache/dev/juddi-patch/juddi-examples/wsdl2uddi-lifecyle/../../juddi-tomcat/target/tomcat/apache-tomcat-6.0.26/webapps/wsdl2uddi.war]...
+[INFO] ------------------------------------------------------------------------
+[INFO] BUILD SUCCESS
+[INFO] ------------------------------------------------------------------------
-This cleans up the business and the wsdl2uddi data structures.
+ServerSide:
+2013-05-08 21:40:39,067 INFO [org.apache.cxf.bus.spring.BusApplicationContext] - Closing org.apache.cxf.bus.spring.BusApplicationContext@f8ffe0b: startup date [Wed May 08 21:31:52 EDT 2013]; parent: Root WebApplicationContext
+2013-05-08 21:40:39,068 INFO [org.springframework.beans.factory.support.DefaultListableBeanFactory] - Destroying singletons in org.springframework.beans.factory.support.DefaultListableBeanFactory@e161e1f: defining beans []; parent: org.springframework.beans.factory.support.DefaultListableBeanFactory@21e7937
+2013-05-08 21:40:39,068 INFO [org.apache.juddi.v3.client.config.UDDIClerkManager] - Stopping UDDI Clerks for manager example-manager
+2013-05-08 21:40:44,011 INFO [org.apache.juddi.v3.client.config.UDDIClerk] - UnRegistering binding key uddi:uddi.joepublisher.com:binding_localhost_helloworld_helloworldimplport_8080
+2013-05-08 21:40:44,047 INFO [org.apache.juddi.v3.client.config.UDDIClerk] - UnRegistering the service uddi:uddi.joepublisher.com:service_helloworld
+2013-05-08 21:40:44,108 INFO [org.apache.juddi.v3.client.config.UDDIClerk] - UnRegistering tModel key uddi:uddi.joepublisher.com:helloworldsoapbinding
+2013-05-08 21:40:44,132 INFO [org.apache.juddi.v3.client.config.UDDIClerk] - UnRegistering tModel key uddi:uddi.joepublisher.com:helloworld
+2013-05-08 21:40:44,145 INFO [org.apache.juddi.v3.client.config.UDDIClerkManager] - UDDI Clerks shutdown completed for manager example-manager
+2013-05-08 21:40:44,146 INFO [org.springframework.web.context.support.XmlWebApplicationContext] - Closing Root WebApplicationContext: startup date [Wed May 08 21:31:51 EDT 2013]; root of context hierarchy
+2013-05-08 21:40:44,147 INFO [org.springframework.beans.factory.support.DefaultListableBeanFactory] - Destroying singletons in org.springframework.beans.factory.support.DefaultListableBeanFactory@21e7937: defining beans [cxf,org.apache.cxf.bus.spring.BusApplicationListener,org.apache.cxf.bus.spring.BusWiringBeanFactoryPostProcessor,org.apache.cxf.bus.spring.Jsr250BeanPostProcessor,org.apache.cxf.bus.spring.BusExtensionPostProcessor,org.apache.cxf.resource.ResourceManager,org.apache.cxf.configuration.Configurer,org.apache.cxf.binding.BindingFactoryManager,org.apache.cxf.transport.DestinationFactoryManager,org.apache.cxf.transport.ConduitInitiatorManager,org.apache.cxf.wsdl.WSDLManager,org.apache.cxf.phase.PhaseManager,org.apache.cxf.workqueue.WorkQueueManager,org.apache.cxf.buslifecycle.BusLifeCycleManager,org.apache.cxf.endpoint.ServerRegistry,org.apache.cxf.endpoint.ServerLifeCycleManager,org.apache.cxf.endpoint.ClientLifeCycleManager,org.apache.cxf.transports.http.QueryHan
dlerRegistry,org.apache.cxf.endpoint.EndpointResolverRegistry,org.apache.cxf.headers.HeaderManager,org.apache.cxf.catalog.OASISCatalogManager,org.apache.cxf.service.factory.FactoryBeanListenerManager,org.apache.cxf.endpoint.ServiceContractResolverRegistry,org.apache.cxf.binding.soap.SoapBindingFactory,org.apache.cxf.binding.soap.SoapTransportFactory,org.apache.cxf.binding.soap.customEditorConfigurer,org.apache.cxf.transport.http.policy.HTTPClientAssertionBuilder,org.apache.cxf.transport.http.policy.HTTPServerAssertionBuilder,org.apache.cxf.transport.http.policy.NoOpPolicyInterceptorProvider,org.apache.cxf.transport.http.ClientOnlyHTTPTransportFactory,org.apache.cxf.transport.servlet.ServletTransportFactory,helloworld]; root of factory hierarchy
Modified: juddi/branches/juddi-3.2.x/juddi-examples/wsdl2uddi-lifecyle/pom.xml
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-examples/wsdl2uddi-lifecyle/pom.xml?rev=1481240&r1=1480510&r2=1481240&view=diff
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-examples/wsdl2uddi-lifecyle/pom.xml (original)
+++ juddi/branches/juddi-3.2.x/juddi-examples/wsdl2uddi-lifecyle/pom.xml Sat May 11 00:27:33 2013
@@ -156,6 +156,64 @@
</plugins>
</build>
</profile>
+ <profile>
+ <id>deploy</id>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.codehaus.cargo</groupId>
+ <artifactId>cargo-maven2-plugin</artifactId>
+ <version>1.3.3</version>
+ <configuration>
+ <container>
+ <containerId>tomcat6x</containerId>
+ </container>
+ <configuration>
+ <type>existing</type>
+ <home>${basedir}/../../juddi-tomcat-${project.parent.version}</home>
+ </configuration>
+ <deployables>
+ <deployable>
+ <groupId>org.apache.juddi.example</groupId>
+ <artifactId>wsdl2uddi-lifecycle</artifactId>
+ <type>war</type>
+
+ </deployable>
+ </deployables>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+ <profile>
+ <id>deploydev</id>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.codehaus.cargo</groupId>
+ <artifactId>cargo-maven2-plugin</artifactId>
+ <version>1.3.3</version>
+ <configuration>
+ <container>
+ <containerId>tomcat6x</containerId>
+ </container>
+ <configuration>
+ <type>existing</type>
+ <home>${basedir}/../../juddi-tomcat/target/tomcat/apache-tomcat-6.0.26</home> -->
+ </configuration>
+ <deployables>
+ <deployable>
+ <groupId>org.apache.juddi.example</groupId>
+ <artifactId>wsdl2uddi-lifecycle</artifactId>
+ <type>war</type>
+
+ </deployable>
+ </deployables>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
</profiles>
<packaging>war</packaging>
</project>
Modified: juddi/branches/juddi-3.2.x/juddi-examples/wsdl2uddi-lifecyle/src/main/resources/META-INF/wsdl2uddi-uddi.xml
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-examples/wsdl2uddi-lifecyle/src/main/resources/META-INF/wsdl2uddi-uddi.xml?rev=1481240&r1=1480510&r2=1481240&view=diff
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-examples/wsdl2uddi-lifecyle/src/main/resources/META-INF/wsdl2uddi-uddi.xml (original)
+++ juddi/branches/juddi-3.2.x/juddi-examples/wsdl2uddi-lifecyle/src/main/resources/META-INF/wsdl2uddi-uddi.xml Sat May 11 00:27:33 2013
@@ -12,14 +12,15 @@
<property name="serverPort" value="8080"/>
</properties>
<description>Main jUDDI node</description>
- <proxyTransport>org.apache.juddi.v3.client.transport.InVMTransport</proxyTransport>
- <custodyTransferUrl>org.apache.juddi.api.impl.UDDICustodyTransferImpl</custodyTransferUrl>
- <inquiryUrl>org.apache.juddi.api.impl.UDDIInquiryImpl</inquiryUrl>
- <publishUrl>org.apache.juddi.api.impl.UDDIPublicationImpl</publishUrl>
- <securityUrl>org.apache.juddi.api.impl.UDDISecurityImpl</securityUrl>
- <subscriptionUrl>org.apache.juddi.api.impl.UDDISubscriptionImpl</subscriptionUrl>
- <subscriptionListenerUrl>org.apache.juddi.api.impl.UDDISubscriptionListenerImpl</subscriptionListenerUrl>
- <juddiApiUrl>org.apache.juddi.api.impl.JUDDIApiImpl</juddiApiUrl>
+ <!-- JAX-WS Transport -->
+ <proxyTransport>org.apache.juddi.v3.client.transport.JAXWSTransport</proxyTransport>
+ <custodyTransferUrl>http://${serverName}:${serverPort}/juddiv3/services/custody-transfer</custodyTransferUrl>
+ <inquiryUrl>http://${serverName}:${serverPort}/juddiv3/services/inquiry</inquiryUrl>
+ <publishUrl>http://${serverName}:${serverPort}/juddiv3/services/publish</publishUrl>
+ <securityUrl>http://${serverName}:${serverPort}/juddiv3/services/security</securityUrl>
+ <subscriptionUrl>http://${serverName}:${serverPort}/juddiv3/services/subscription</subscriptionUrl>
+ <subscriptionListenerUrl>http://${serverName}:${serverPort}/juddiv3/services/subscription-listener</subscriptionListenerUrl>
+ <juddiApiUrl>http://${serverName}:${serverPort}/juddiv3/services/juddi-api</juddiApiUrl>
</node>
</nodes>
<clerks registerOnStartup="true">
Modified: juddi/branches/juddi-3.2.x/juddi-examples/wsdl2uddi-lifecyle/src/main/webapp/WEB-INF/beans.xml
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-examples/wsdl2uddi-lifecyle/src/main/webapp/WEB-INF/beans.xml?rev=1481240&r1=1480510&r2=1481240&view=diff
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-examples/wsdl2uddi-lifecyle/src/main/webapp/WEB-INF/beans.xml (original)
+++ juddi/branches/juddi-3.2.x/juddi-examples/wsdl2uddi-lifecyle/src/main/webapp/WEB-INF/beans.xml Sat May 11 00:27:33 2013
@@ -24,7 +24,7 @@
<import resource="classpath:META-INF/cxf/cxf-extension-soap.xml" />
<import resource="classpath:META-INF/cxf/cxf-servlet.xml" />
- <jaxws:endpoint id="helloworld" implementor="org.apache.juddi.samples.HelloWorldImpl"
+ <jaxws:endpoint id="helloworld" implementor="org.apache.juddi.example.HelloWorldImpl"
address="/helloworld" />
</beans>
Modified: juddi/branches/juddi-3.2.x/juddi-gui/build.xml
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-gui/build.xml?rev=1481240&r1=1481239&r2=1481240&view=diff
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-gui/build.xml (original)
+++ juddi/branches/juddi-3.2.x/juddi-gui/build.xml Sat May 11 00:27:33 2013
@@ -7,8 +7,8 @@
<!-- the Compile on Save feature is turned off for the project. -->
<!-- You can turn off the Compile on Save (or Deploy on Save) setting -->
<!-- in the project's Project Properties dialog box.-->
-<project name="UDDIBrowser" default="default" basedir=".">
- <description>Builds, tests, and runs the project UDDIBrowser.</description>
+<project name="juddi-gui" default="default" basedir=".">
+ <description>Builds, tests, and runs the project juddi-gui.</description>
<import file="nbproject/build-impl.xml"/>
<!--
Modified: juddi/branches/juddi-3.2.x/juddi-gui/nbproject/build-impl.xml
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-gui/nbproject/build-impl.xml?rev=1481240&r1=1481239&r2=1481240&view=diff
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-gui/nbproject/build-impl.xml (original)
+++ juddi/branches/juddi-3.2.x/juddi-gui/nbproject/build-impl.xml Sat May 11 00:27:33 2013
@@ -17,7 +17,7 @@
- cleanup
-->
-<project xmlns:webproject1="http://www.netbeans.org/ns/web-project/1" xmlns:webproject2="http://www.netbeans.org/ns/web-project/2" xmlns:webproject3="http://www.netbeans.org/ns/web-project/3" basedir=".." default="default" name="UDDIBrowser-impl">
+<project xmlns:webproject1="http://www.netbeans.org/ns/web-project/1" xmlns:webproject2="http://www.netbeans.org/ns/web-project/2" xmlns:webproject3="http://www.netbeans.org/ns/web-project/3" basedir=".." default="default" name="juddi-gui-impl">
<import file="ant-deploy.xml"/>
<fail message="Please build using Ant 1.7.1 or higher.">
<condition>
@@ -450,7 +450,7 @@ or ant -Dj2ee.platform.classpath=<ser
</fileset>
</union>
<taskdef classname="org.testng.TestNGAntTask" classpath="${run.test.classpath}" name="testng"/>
- <testng classfilesetref="test.set" failureProperty="tests.failed" methods="${testng.methods.arg}" mode="${testng.mode}" outputdir="${build.test.results.dir}" suitename="UDDIBrowser" testname="TestNG tests" workingDir="${basedir}">
+ <testng classfilesetref="test.set" failureProperty="tests.failed" methods="${testng.methods.arg}" mode="${testng.mode}" outputdir="${build.test.results.dir}" suitename="juddi-gui" testname="TestNG tests" workingDir="${basedir}">
<xmlfileset dir="${build.test.classes.dir}" includes="@{testincludes}"/>
<propertyset>
<propertyref prefix="test-sys-prop."/>
@@ -597,7 +597,7 @@ or ant -Dj2ee.platform.classpath=<ser
<condition else="-testclass @{testClass}" property="test.class.or.method" value="-methods @{testClass}.@{testMethod}">
<isset property="test.method"/>
</condition>
- <condition else="-suitename UDDIBrowser -testname @{testClass} ${test.class.or.method}" property="testng.cmd.args" value="@{testClass}">
+ <condition else="-suitename juddi-gui -testname @{testClass} ${test.class.or.method}" property="testng.cmd.args" value="@{testClass}">
<matches pattern=".*\.xml" string="@{testClass}"/>
</condition>
<delete dir="${build.test.results.dir}" quiet="true"/>
Modified: juddi/branches/juddi-3.2.x/juddi-gui/nbproject/genfiles.properties
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-gui/nbproject/genfiles.properties?rev=1481240&r1=1481239&r2=1481240&view=diff
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-gui/nbproject/genfiles.properties (original)
+++ juddi/branches/juddi-3.2.x/juddi-gui/nbproject/genfiles.properties Sat May 11 00:27:33 2013
@@ -1,8 +1,8 @@
-build.xml.data.CRC32=7208fe83
-build.xml.script.CRC32=f15a2af6
+build.xml.data.CRC32=a17592f3
+build.xml.script.CRC32=33f4ab89
build.xml.stylesheet.CRC32=651128d4@1.38.1.1
# This file is used by a NetBeans-based IDE to track changes in generated files such as build-impl.xml.
# Do not edit this file. You may delete it but then the IDE will never regenerate such files for you.
-nbproject/build-impl.xml.data.CRC32=7208fe83
-nbproject/build-impl.xml.script.CRC32=b9be4a76
+nbproject/build-impl.xml.data.CRC32=a17592f3
+nbproject/build-impl.xml.script.CRC32=6a921c0b
nbproject/build-impl.xml.stylesheet.CRC32=4e9cae83@1.38.1.1
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@juddi.apache.org
For additional commands, e-mail: commits-help@juddi.apache.org