Salesforce

Resource Repository (Magic xpi 3.x)

« Go Back

Information

 
Created ByKnowledge Migration User
Approval Process StatusPublished
Objective
Description

Resource Repository (Magic xpi 3.x)

The Resource Repository defines the external systems that Magic xpi needs to access during project execution. This provides a way of managing a project's resources from a separate location outside of the actual project. You can also reuse predefined environment settings in different projects, enabling you to switch execution environments quickly and easily. For example, when you activate a component's method or XML interface, you need to specify environment properties such as server, user, and port. The Resource Repository enables the component's settings to refer to a defined resource, and to inherit its properties.

These resource settings can be used with:

  • Components

  • Databases

  • Web Services

  • XML schemas

  • Any other user-defined resources

You can define the following resources in Magic xpi's Resource Repository:


To define a new resource in the Resource Repository:

  1. From the Project menu, select Resources to open the Resource Repository. Alternatively, if the project is closed, you can access this dialog box by opening the Tools menu and selecting Resources.

  2. Click New. The New Resource dialog box opens.

  3. Select one of the resources from the drop-down list. In the Resource Name field, enter a name for your new Resource, and click OK. The Resource Setting window opens.

  4. Your new resource now appears in the left pane of the Resource Setting dialog box, either under the name that you entered or under a generic file carrying the same resource type name.

  5. Click on the new resource in the left pane. Enter a description for the resource in the Resources Setting Description field.

  6. Next, enter the resource's parameters. These parameters are different for each resource. The parameters that you define here also appear in the Component Properties dialog box, under the Settings tab, when you drag the component to the flow area. For more information on specific resource parameters, click on the resources above.

  7. Each resource has additional buttons that are specific to the resource and are used to configure the resource. For more information on these buttons, click on the resource links above.

  8. When you have finished defining your resource, click OK to save your resource and to exit the dialog box.

  9. Alternatively, you can click Cancel to exit the dialog box without saving your new resource.

If you right-click a resource, a context menu with the following options opens:

  • Delete

  • Rename

  • Select as default: If you create more than one resource under a specific resource type, select this option to define one of these resources as the default resource for that type. This option is available when you right-click from a resource that is not the default. The default resource is identified by the icon.

The Resource Setting dialog box also contains the following additional buttons that can be used with all resource types:

Button

Description

New

Click this button to add a resource to the list.

Load

Click this button to import a resource file. You can either overwrite or append existing entries. Click here for more information.

Save As

Click this button to save a resource to a specific location under another name.

Note:

If you are working with a database resource, three additional buttons are activated on this screen. These are:

  • Validate: This validates the connection settings to the selected database.

  • Table: Enables you to filter tables.

  • Owner: This defines the starting owner for database access.

Magic xpi saves the defined resources in two separate XML files. These are:

  • The resources.xml file: This is a general resource type definition, and is saved in the Magic xpi installation folder. There is only one resource type definition file for each Magic xpi Studio installation.

  • The resource_types.xml file: This holds predefined resource type definitions.

Note:

  • At deployment, when you execute the Magic xpi server, the appropriate resource settings files are loaded automatically. When resources are used in the project, they are based on the resource settings that were loaded when the server was executed. If a resource settings file is not found, the server shuts down and an error message appears.

  • When you create a new resource, it cannot have the same name as its parent resource.

  • Magic xpi components that require resource settings have a Settings tab in the Component Properties dialog box. This topic is covered here.

  • You can use environment variables in this repository with the following syntax:
    %environment variable name%

  • If you change an existing resource's name, any components that point to that resource lose their resource configurations. This is because the resource's name is the reference that the components use for resource configuration. To remedy this, open the relevant component's Component Properties dialog box. In the Settings tab, select the resource's new name from the Resource Name property's drop-down list.

Since version:

V3

Related Topics

Reference
Attachment 
Attachment