Network Deployment (Distributed operating systems), v8.0 > Develop and deploying applications > Develop web services - UDDI registry > Develop with the UDDI registry > Use the JAXR provider for UDDI


Create a custom internal taxonomy for the JAXR provider

We can create a custom internal taxonomy and make it available to the Java API for XML Registries (JAXR) provider.

Deprecated feature: In WAS v8.0, Java API for XML Registries (JAX-R) APIs are deprecated. The Java Platform, Enterprise Edition (Java EE) 6 platform began the deprecation process for JAX-R because it is based on Universal Description, Discovery and Integration (UDDI) 2 technology, which is no longer relevant. If the applications use JAX-R, then you might consider using UDDI 3.

depfeat

The JAXR provider for UDDI supplies a number of internal taxonomies. You can also supply a custom internal taxonomy.

To create a new custom internal taxonomy and make it available to the JAXR provider, use the following procedure.


Procedure

  1. Create a text file that contains the taxonomy element data. We can use the iso3166-2003-data.txt file in plugins/com.ibm.uddi_1.0.0 as an example. This file is the taxonomy data file for the supplied ISO 3166 taxonomy. The first few lines are:
    iso3166#--#World#--
    iso3166#AD#Andorra#--
    iso3166#AE#United Arab Emirates#--
    iso3166#AE-AJ#'Ajm?n#AE
    iso3166#AE-AZ#Ab? Z?aby[Abu Dhabi]#AE
    iso3166#AE-DU#Dubayy [Dubai]#AE
    iso3166#AE-FU#Al Fujayrah#AE
    iso3166#AE-RK#Ra's al Khaymah#AE
    iso3166#AE-SH#Ash Sh?riqah [Sharjah]#AE
    iso3166#AE-UQ#Umm al Qaywayn#AE
    iso3166#AF#Afghanistan#--
    iso3166#AF-BAL#Balkh#AF
    iso3166#AF-BAM#B?m??n#AF
    

    Each line represents one element of the taxonomy, or one concept in the taxonomy concept tree. Each line has the following format:

    <taxonomy ID>#
    <element value>#
    <element name>#
    <parent element value> 

    The following table describes the tokens in the format.

    Tokens in the format of the taxonomy element data file. The table lists the different tokens along with a description for each one.

    Token Description
    <taxonomy ID> The taxonomy ID is the same for every element of a taxonomy.
    <element value> The concept value (UDDI keyValue).
    <element name> The concept name (UDDI keyName).
    <parent element value> The value of the parent element of the current element in the taxonomy tree. Except for the root element, for every element in the data file, there must be another line that defines a parent element. The root element is denoted by defining itself as its own parent. There must be only one root element, and no elements without parents.
    # The delimiter character. We can define this character for each taxonomy in the taxonomyConfig.properties file; the delimiter does not have to be the number sign (#).

  2. Save a ClassificationScheme (UDDI tModel entity) in the UDDI registry to represent the new internal taxonomy.

    To do this, use the javax.xml.registry.BusinessLifeCycleManager.saveClassificationSchemes() method.

  3. Add the new taxonomy to the taxonomyConfig.properties file

    1. Copy the supplied taxonomyConfig.properties file from the root of the com.ibm.uddi_1.0.0.jar file. The content of the supplied taxonomyConfig.properties file is:
      naics-1997 = UUID:C0B9FE13-179F-413D-8A5B-5004DB8E5BB2, naics-1997-data.txt, #
      naics-2002 = UUID:1FF729F2-1948-46CF-B660-31EC107F1663, naics-2002-data.txt, #
      unspsc  = UUID:DB77450D-9FA8-45D4-A7BC-04411D14E384, unspsc-data.txt,     #
      unspsc7_data = UUID:CD153257-086A-4237-B336-6BDCBDCC6634, unspsc7-data.txt,   #
      iso3166-2003 = UUID:4E49A8D6-D5A2-4FC2-93A0-0411D8D19E88, iso3166-2003-data.txt,#
      
      

      This file has one line for each internal taxonomy that is supplied. Each line has the following format:

      <taxonomy ID> =
      <tModelKey>, <data filename>, <data file delimiter> 
      The following table describes the tokens in the format.

      Tokens in the format of the taxonomyConfig.properties file. The table lists the different tokens along with a description for each one.

      Token Description
      <taxonomy ID> The JAXR provider uses this value internally to identify each taxonomy. This value does not have to be the same as the taxonomy ID in the corresponding taxonomy data file.
      <tModelKey> The tModelKey element of the corresponding UDDI tModel entity, which is the id of the corresponding JAXR ClassificationScheme.
      <data filename> The name of the corresponding taxonomy data file.
      <data file delimiter> The delimiter character used in the taxonomy data file. All internal taxonomies that are supplied use the number sign (#), but user-supplied internal taxonomies might use different delimiter characters.

    2. Add a new line for the new taxonomy to the copy of the taxonomyConfig.properties file. Do not remove any existing taxonomies from the file, because this makes them unavailable to the JAXR provider.

  4. Add the copied taxonomyConfig.properties file to the Java class path, ahead of the jaxruddi.jar file.

  5. If there are any JAXR client programs still running that were started before you added the new taxonomy to the taxonomyConfig.properties file, create a new connection to pick up the new taxonomy.


JAXR provider for UDDI internal taxonomies
Java API for XML Registries (JAXR) provider for UDDI
Use the JAXR provider for UDDI

+

Search Tips   |   Advanced Search