Additional Windchill Capabilities > Service Information Management > About Service Structures > Building Service Structures > About Auto Populating a Service Structure
  
About Auto Populating a Service Structure
You can populate a service structure with Information Elements based on custom business rules specified in an XML configuration file. You use the Populate Structure option in the context menu of a service structure to add information elements to the root of a structure, or, groups or sections nested in a structure.
To enable Populate Structure, as a site or organization administrator, you should:
Set the following preferences listed under Structure Population in Preference Management:
Configuration file location— Specifies the location of the XML configuration file for structure population. In case of a clustered setup, make sure that the file path of the XML file is a shared location which is available to all method servers. If the value of this preference is empty, the Populate Structure action will be disabled. The configuration of this preference is required.
Create Group or Section— Determines whether groups or sections should be created during the process of structure population if they do not exist in the structure. A group or a section will be created only if the Matches element is used within the Group or Section element in the configuration file. If the attributeMapping element is used and a matching group or section is missing or does not exist, the application will not create a group or section in the service structure.
These preferences can be set at the site, organization, or context level, depending on business needs.
Configure an XML file to specify the rules of structure population based on business requirements.
Creating the Configuration File
You will need to create rules in the configuration file to specify the filter criteria to collect Information Elements and map them to relevant groups or sections in a service structure. The configuration file is context-specific, which means you can create different configuration files for different contexts such as Product or Library. For more information on the elements and attributes that you can use to create a configuration file, see Doctype for Auto-Populate Configuration File.
Please be aware of the following guidelines when creating the XML configuration file:
Information Elements must have a unique attribute value based on a naming convention or number that can be used to determine which group or section they should be added to. Valid data types for attribute value are String, Integer, Boolean, Date, Real Number and Real Number with Units. If any other type of data is specified for attribute value, it will be processed as String type. For Multi-Value attributes, if any of the attribute values match the expression, the Information Element will be added to the group or section.
Service Effectivity or ATO Expressions can be assigned to Information Elements, which can later be used as filter criteria for structure population.
Groups or sections must have an attribute value which can be used to identify which group or section the Information Element should map to. If the attribute values match, then the Information Element is inserted or populated under the matching group or section. If an Information Element matches more than one group or section, it will be added to all the matching groups or sections. For nested groups or sections, only the unique name of the group or section should be specified. Directory path or file path as a value for internal name is not supported for this action.
If a group or section does not exist in a structure and is created automatically during the structure population process, by default it will be added under the root node of the service structure.
Using the Populate Structure Action
Perform the following steps to populate a service structure with applicable information elements:
1. Navigate to the Structure tab of the service structure that you want to populate with additional Information Elements.
2. Select the root of the service structure, right-click and click Populate Structure.
3. The Populate Structure window opens. Use this wizard to specify filter criteria for the Information Elements to be imported based on Option Filter or Service Effectivity or both. For more information, see Filtering on Options and Managing Service Effectivity.
4. Click OK.
The service structure is populated with the Information Elements that match the specified filter criteria. By default, the Information Elements are sorted in an alphanumeric order in the structure.
Reporting and Error Handling
If the INFO or DEBUG logging is enabled for the com.ptc.arbortext.windchill.corestruct.server.autoPopulation.AutoPopulationTask class, an HTML report is generated after the structure population is complete. In this report you can view information about the objects that were selected for auto-population, the status for those objects, and whether the auto-population was a success or failure. The report is automatically downloaded in the browser; you can choose to view it or save it to a local disk.
You can choose to subscribe to a service structure to receive email notifications when the auto-populate action is processed. The email notification provides a list of the Information Elements that got populated successfully or if the auto-population action failed. Click Actions > Subscribe to set email notifications for Populate Structure Successful and Populate Structure Unsuccessful actions.
The error messages for the populate action are displayed on the Event Management utility. For example, on running the Populate Structure action, if the configuration file is missing or its specified location is incorrect an error message is displayed in Event Management. If the Populate Structure action is successful, its summary information is provided in the Event Management utility.