Lesson 1 Create the helloWorld component
Components contain artifacts and processes. Artifacts include runnable files, images, databases, configuration instructions, and anything else that is associated with a software project. Processes define the activities that components can perform.
- To create the helloWorld component:
Click the Components tab and then click Create
In the window that opens, you define the component and specify the location of the artifacts for it.
- In the Name field, type helloWorld.
In the Source Configuration Type list, select File System
This parameter defines the type of artifacts the component uses. All artifacts in a component share the source type. The File System (Versioned) type looks for the artifacts on the file system.Note: The None type can be used for configuration-type or operational-type deployments. For more information about deployment types, see Creating component processes.
- In the Base Path field, specify
the location of the helloWorld folder that you
created earlier, such as /home/user1/artifacts/shared/helloWorld.
The File System (Versioned) source type considers directories in the specified folder as representations of component versions. For this reason, make sure that you specify the helloWorld directory and not the helloWorld/1.0 directory.
- Accept the default values for the other fields on the
page. The Preserve Execute Permissions and Import Versions Automatically check boxes are cleared and the Copy to CodeStation check box is selected. The Default Version Type is set to Full.
- Click Save.
- Click the Components tab and then click Create Component.
- Create a component property.A property is user-defined parameter that can be set at design time or run time. Properties can be defined for components, processes, applications, environments, and other product elements. Here you set the property on the component, but in situations where multiple components share the property, you might set the property value on the environment instead of setting it on every component.
- On the "Component: helloWorld" page, click the Configuration tab and then click Component Properties.
- Click Add Property.
- In the Edit Property window, name the property something like helloHome.
- In the Value field, type the
name of the directory that you created to hold the component artifacts,
for example c:\helloWorld.The component process uses this property later to identify the target location for the component artifacts.
- Click Save.
- Import the component version:
The helloWorld component is ready to use.
- Click the Versions tab.
- Click Import New Versions.
The server creates a version of the component that is based on the folder in the helloWorld folder, and imports the files in the helloWorld/1.0 directory. In this case, the server creates a single version of the component that is based on the helloWorld/1.0 folder. If other folders were in the helloWorld directory, they too would be imported and versions would be created from them.
- Verify that the list of versions includes version 1.0
of the component, as in the following figure:
- Click the version name, 1.0.
- Verify that the list of artifacts includes the files
in the helloWorld/1.0 directory, as in the following