CentraSite Documentation : CentraSite User’s Guide : Using the Asset Catalog : Publishing a New Asset into the Catalog : Adding an Asset to the Catalog Using an Importer : Importing XML Schemas
Importing XML Schemas
When an XML Schema is imported, the schema file is copied to the repository and an XML Schema asset is created in the registry. The asset contains an External Link to the schema file in the repository.
The entries created are summarized in the following diagram:
A schema definition can consist of several physical files that refer to each other using IMPORT or INCLUDE statements. In such cases, each of the schema files is stored in the repository and appropriate references are created in the registry as follows:
Each schema file in the repository that is referred to by a higher-level schema file in the repository has an XML Schema object in the registry that is referred to by the XML Schema object of the higher-level schema file. The reference is implemented as an association of the type uses. The XML Schema object in the registry contains an External Link to the schema file in the repository.
If the importer detects an equivalent schema within CentraSite during the import of a schema, the import dialog will prompt you to specify either Overwrite latest version or Create new version.
You can also choose the option Interactive resolution of Import/Includes, which will allow you to specify how an already existing imported/included file is handled. For each of the imported/included files you have one of these options:
*Overwrite the importing file with new content.
*Create a new version of the file with the new content (if, for example, you want to modify a schema but want to retain its previous version).
*Reuse any version of the file (if, for example, an intermediate version of a schema is currently referred to by a WSDL, you can redirect it to the newest version).
If you choose the Reuse option and there is more than one schema with the same name and namespace, you can choose between these. To allow you to select the required schema, the tab Reuse Existing lists the available schemas that match the given name and also their available versions. You can view the contents of any schema in the list by clicking view link in the column Content; this is useful if you want to check that you have selected the correct file from the list.
Additionally, when importing an XML Schema that refers to other XML Schemas, keep the following points in mind:
*When you have at least a Modify permission on the referenced XML Schema, both the asset's schema and referenced schema are imported automatically.
*When you have only View permission on the referenced XML Schema, the asset's schema is imported and the referenced XML Schema implicitly reused.
*When you do not have any permission on the referenced XML Schema, the asset's schema is imported and a warning message logged.
To import a new XML Schema asset to the catalog
Before you begin, you must have the XML schema file that you want to import. This file can reside on the file system of the computer where your browser is running or it can reside anywhere on the network, as long as its location is addressable through a URL.
1. In CentraSite Control, go to Asset Catalog > Browse.
2. Click the Import icon.
3. In the Import dialog, specify the following attributes:
In this field...
Do the following...
Organization
Choose the organization to which the asset will be added. (The drop-down list will contain the list of organizations to which you are permitted to add assets.) If you select an organization other than your own organization, you will nevertheless be the owner of the asset.
Note:  
Choose the organization with care. You cannot change the organization assignment after the asset is added to the catalog. You can, however, export an asset from one organization and import it to another.
Import as
Choose Schema.
Initial Version
Optional. Enter an identifier for the initial version of the asset. For details, the description of the import dialog for Web service described in Importing Web Services (including Abstract Services).
Name
Optional. Enter a the name for the asset. If you do not specify a name for the asset, it is set automatically to the schema's file name.
Import from
Specify whether the input file will be read from your local file system (the File option) or from a URL-addressable location on the network (the URL option).
URL or File
If the file you are importing resides on the network, specify its URL.
If the file resides in your local file system, specify the file name. You can use the Browse button to navigate to the required folder.
URL Authentication
If you have specified a URL and the site you want to access through the URL requires user authentication, check this box. This opens an Authentication sub-dialog in which you can enter a username and password for authentication at the URL site.
Interactive resolution of Import/Includes
This option determines how referenced schemas are handled when the schema that is referred to already exists in the registry. When this option is enabled, you will be prompted during import to specify whether you want to reuse any schema files referred to in the main file or upload new files.
4. Click Finish.
CentraSite retrieves the specified file and generates the catalog entry. The XML schema asset’s details page is displayed.
What Happens When You Import a New Schema File?
CentraSite retrieves the specified file and generates the catalog entry. If you have specified Interactive resolution of Import/Includes, you will also be prompted to specify whether you wish to reuse any of the schema files that might be referred to in the main schema file using IMPORT or INCLUDE statements or upload new files.
What Happens When You Import an Existing Schema File?
If the importer detects that the schema you are trying to import already exists within CentraSite, the import dialog will prompt you to specify whether you want to Overwrite latest version or Create new version. If you have specified Interactive resolution of Import/Includes, you will be prompted to specify whether you wish to reuse any of the schema files referred to in the main schema file using IMPORT or INCLUDE statements or upload new files.
5. Click OK.
CentraSite retrieves the specified file and generates the catalog entry.
6. During import of an XML Schema asset, CentraSite will not allow you to add the schema to the asset catalog unless you have specified all required attributes in the Schema type definition and all referenced objects to which the XML file has an association. The value for the required attribute must be specified in the schema's profile. Additionally, if the schema asset has internally referenced objects, the value for the required attributes of all such referenced objects should be specified by choosing the Next button at the top right side of the details page in order to add the XML schema asset to the asset catalog. Thus, for example, if the XML schema file that is referenced in the main XML file have required attributes, then you will be prompted to specify a value for the required attributes in order to save the asset.
7. After you specify the value for all of the required attributes, click Save to save the XML schema asset.
8. Review the import log that CentraSite generates for the import process. If errors occur while reading and processing the file, they will be reported in this log.
9. Configure the asset's extended attributes as described in Editing an Asset in the Catalog.
Tip:  
If you had previously imported a WSDL that has an associated schema file and you now re-import just the schema file with modifications, your browser might not display the updated contents of the schema file. This can happen if the browser cache is not being updated automatically. To rectify the problem, you can change your browser settings so that pages are always updated on every visit.
Restriction
XML Schema files can contain references to DTD (Document Type Definition) files. If you import such an XML schema file, the referenced DTD files are not imported to CentraSite.
Copyright © 2005-2016 Software AG, Darmstadt, Germany.

Product LogoContact Support   |   Community   |   Feedback