Creating User Profile Properties

User profile properties are name/value pairs attached to users and used for entering personal information about users (and groups). For example, you could create a property set called "human resources" that contains properties such as "gender," "hire date," and "social security number." User profile properties appear as input fields in the WebLogic Administration Portal when you edit a user's profile values. (You can also assign user profile property values to groups.) The properties you create are also used to define rules for personalization, delegated administration, or visitor entitlements. Users and groups can have multiple profiles.

Note: The topic of user profile properties is one piece in a larger body of user management issues. For more information, see the WebLogic Portal User Management Guide on the edocs Web site.

WebLogic Portal provides a default user profile property set called CustomerProperties.usr that contains many common properties you may want to use.

This topic contains the following sections:

To create a User Profile Property set

To add properties to a property set

To modify properties and their values

To delete properties

To surface properties from external data stores

To create a User Profile Property set

  1. In the WebLogic Workshop Application window, right-click the data\userprofiles folder and choose New --> User Profile Property Set.
  2. In the New File window, enter a name for the User Profile property set in the File name field. Make sure you keep the .usr file extension.
  3. Click Create. The User Profile Property Set designer appears.
  4. Use the next procedure to add properties to the property set.

To add properties to a property set

After you create a property set, you add the properties you want to it.

  1. In the Palette window, drag one of the types of properties into the designer window.

    The type defines the number of values that can be entered for the property. Following are descriptions of each type.

    Single Unrestricted - A single unrestricted property can have only one value, but you can enter any value.

    Single Restricted - A single restricted property can have only one value, and you are restricted to selecting that value from a predefined list.

    Multiple Unrestricted - A multiple unrestricted property can have multiple values, and you can enter any values.

    Multiple Restricted - A multiple restricted property can have multiple values, and you are restricted to selecting the values from a predefined list.
  2. In the Property Editor window:

    Note: Any change to Data Type, Selection Mode, or Value Range removes anything previously entered in the Values field.

  3. Save the file after you have added all the properties you want.

Note: You can also use the Property Control to programmatically create and manage properties. However, properties created with this control are not surfaced in the WebLogic Administration Portal. They must be modified and updated programmatically.

To modify properties and their values

To modify properties and their values, double-click the property set file in the the Application window, click the property you want to modify, and change the values in the Property designer window.

You can also use the <profile:setProperty> JSP Tag in your JSPs or the Property Control in your Page Flows to modify existing property values for users.

To delete properties

You can delete individual properties from a property set, and you can delete property sets.

To delete a property from a property set, open the property set file, select the property, and press the Delete key.

To delete a property set, select the property set file in the Application window and press the Delete key.

You can also use the <profile:removeProperty> JSP Tag in your JSPs or the Property Control in your Page Flows to remove existing property values for users.

To surface properties from external data stores

Use this procedure if you created a unified user profile to access external user/group properties and you want to use those properties to define rules for personalization, delegated administration, or visitor entitlements.

After you create a unified user profile to access user/group properties stored in an external user store, such as an LDAP server, you can access those external properties only through WebLogic Portal's JSP tags, controls, or API. Those external properties are not yet accessible in the WebLogic Administration Portal.

If you want those external properties to be used in defining rules for personalization, delegated administration, or visitor entitlements, you must surface those properties in the WebLogic Administration Portal.

Note: The properties you surface from an external user store may be read-only, meaning their values cannot be updated in the WebLogic Administration Portal. To make those properties writable, your custom unified user profile would have to implement writable properties.

Passwords are not properties.

  1. Create a unified user profile for the external data store. See Unified User Profiles in the User Management Guide on BEA's e-docs Web site.
  2. Create a user profile property set for the external data store. The name you give the property set is important.

    Find the name of the property set to create. In your enterprise application root directory, inside p13N_ejb.jar, open META-INF/ejb-jar.xml. In the <!-- User Profile Manager --> section, locate the name entry for your external store, such as <env-entry-name>PropertyMapping/ldap</env-entry-name> or <env-entry-name>PropertyMapping/MyExternalStore</env-entry-name>. The name following PropertyMapping/ is the name you must give to the new property set. The name is case sensitive. For example, in the two examples shown, the property set would be named ldap.usr or MyExternalStore.usr.

    If you are using the LDAP unified user profile provided by WebLogic Portal, name the property set ldap.usr.
  3. Add properties to the property set that exactly match the property names in the external store you want to surface.
  4. Save the property set file.

Related Topics

Property Set Designer window

Unified User Profiles (edocs)

Creating Segments

Creating Content Selectors

Creating Campaigns

Creating Request Properties

Creating Session Properties

Creating Catalog Structure Properties

Registering Custom Events

Tutorial: Showing Personalized Content in a Portlet