The UDDI (Universal Description, Discovery and Integration) Project is a comprehensive, open industry initiative enabling businesses to (I) discover each other, and (II) define how they interact over the internet and share information in a global registry architecture. UDDI is the building block which will enable businesses to quickly, easily and dynamically find and transact with one another via their preferred applications.
UDDI4J is a Java class library that provides an API that is can be used to interact with a UDDI registry. This class library generates and parses messages sent to and received from a UDDI server.
The central class in this set of APIs is org.uddi4j.client.UDDIProxy. It is a proxy for the UDDI server that is accessed from client code. Its methods map to the UDDI Version 2.0 API Specification.
The classes within org.uddi4j.datatype represent data objects used to send or receive UDDI information. and in the, business, service, tmodel subpackages represent data objects that are sent on calls or received from the server.
The subpackage org.uddi4j.request contains messages sent to the server. These classes are typically not used directly, rather the UDDIProxy class uses these classes.
Similarly, the subpackage org.uddi4j.response represents response messages from a UDDI
server.
Pluggable transports are supported by the package org.uddi4j.transport.
UDDIException is thrown when errors are received from the UDDI proxy when invoking UDDIProxy inquiry methods. UDDIException can contain a DispositionReport with information about the error.
APIs that do not return a data object return a disposition report directly.
TransportException is thrown if a communication error occurs or if the resulting data cannot be properly parsed as a valid SOAP message. This new exception class is required since the previous use of SOAPException created a dependency on Apache SOAP. TransportException wrappers any communications exception thrown by the underlying SOAP transport implementation (Axis, SOAP, HP-SOAP). The native exception is available, and a stack trace will indicate where the TransportException was thrown as well as the native exceptions stack trace.
Property name | Values | Description |
---|---|---|
org.uddi4j.TransportClassName | org.uddi4j.transport.ApacheSOAPTransport,
org.uddi4j.transport.HPSOAPTransport,
org.uddi4j.transport.ApacheAxisTransport. If missing, it defaults to “org.uddi4j.transport.ApacheSOAPTransport”. The property will be read at startup time, and any change at run time (after the TransportFactory has been invoked) will not have any effect. Also see (*) note below on adding a new SOAP transport. Selecting a SOAP transport |
Selecting a SOAP transport |
org.uddi4j.logEnabled | “true” or “false”. If missing, it defaults to “false”. The property can be changed at run time, and will be checked each time a UDDI message is sent out. Turning logging on or off. |
Turning logging on or off. |
http.proxyHost | Valid host name. | Hostname of http proxy |
https.proxyHost | Valid host name. Defaults to hostname of http proxy. | Hostname of https proxy |
http.proxyPort | Valid port number. Defaults to 80. | Port of http proxy. |
https.proxyPort | Valid port number. Defaults to http.proxyPort. | Port of https proxy. |
http.proxyUserName | Valid user name. | Username for proxy server |
http.proxyPassword | Valid password | Password for proxy server |
http.basicAuthUserName | Valid user name. | Username to use with HTTP Basic Authentication |
http.basicAuthPassword | Valid password | Password to use with HTTP Basic Authentication |
Property name | Allowed Values/Default behavior | Description |
---|---|---|
hpsoap.logDirectory | Valid directory path. In case it is null/missing, or invalid or any error while accessing this directory, the log file will be created in the current directory. The property will be read at startup time, and any change at run time (after the TransportFactory has been invoked) will not have any effect. |
Directory path of log file |
hpsoap.logFileName | Valid file name. In case it is missing, logging will be turned off. In case it is present, but null valued, all logging information will be sent to System.err If file open/write fails, all log information is sent to System.err. The property will be read at startup time, and any change at run time (after the TransportFactory has been invoked) will not have any effect |
File name of log file |
The user can set these properties at startup time
C:> java –Dorg.uddi4j.TransportClassName=org.uddi4j.transport.HPSOAPTransport
-Dorg.uddi4j.logEnabled=true SomeUDDIClient
The user can set these properties at run
time
System.setProperty (“hpsoap.logDirectory”, “/tmp”);
System.setProperty (“hpsoap.logFileName”, “uddi4j.log”);
System.setProperty (“org.uddi4j.logEnabled”, “true”);
UDDIProxy uddiProxy = new UDDIProxy ();
To run a program referencing UDDI4J,
ant targetwhere target is one of the following:
A set of samples is provided to illustrate the basics of using the inquiry api, publish api, and error handling.
The samples require several pieces of information including the following:
A property file is used by the samples to
read values that may need to be modified.
This property file includes the values listed
above, as well as a convenient way to set
the system properties used by UDDI4J as described
in Configuration.
To run the examples, set the classpath as described above, invoke java or jre with the desired sample program name. Example:
java FindBusinessExample
IBM is a registered trademark of IBM,
HP is a registered trademark of Hewlett-Packard Company
Copyright© IBM Corporation 2001, All rights reserved.