For retrieving business card information, you can set up
a dual repository of an LDAP directory and a custom IBM® Notes® application.
Before you begin
This section describes how to configure the business card
using two storage repositories: an LDAP directory with a custom Notes application
repository. Here, we describe how you can set up an LDAP directory
as the primary storage, and a custom Notes application
as the secondary storage. These directions assume the following:
- Domino® and IBM Sametime® Community Server
have already been installed and configured to run properly
- Sametime authentication
is configured to use an LDAP directory
- The LDAP server is running and accessible by the Sametime Community Server
- Business card information can be retrieved from your Sametime directory
- A custom Notes application
based upon any template has been created and contains user records
for each corresponding person document defined in the Sametime directory. (In
our example, this custom application is named bcardstorage.nsf).
- To use a custom Notes application
as a secondary repository, each user record in the custom application
must have a common field whose unique value matches the value of the
same field for the person in the Sametime directory. By default,
the common field that is used is the internet email address).
- The view you use in this database must have at least one column
sorted for every key. A sorted column must exist for the database
field used as the common field.
- Photos must be less than 45 KB (recommended: 10 KB) and must be
in the .jpg or .gif file type.
Procedure
- Log in to the WebSphere® Integrated
Solutions Console as the WebSphere administrator.
- Click .
- In the Sametime Community Servers list,
click the deployment name of the server with the business card information
that you want to add or change.
- Click the Business Card tab.
- In the Business Card Contents section, select the attribute
you want displayed in users' business cards, and then click Add to
include the selected attribute. If you do not want to display any
pre-selected information, select each attribute, and then click Remove.
- In the Attribute Definition section,
choose Attribute Values that are appropriate
for your deployment. Each LDAP directory has its own naming schema,
so be sure to confirm that each attribute value selected for display
is mapped to the correct LDAP attribute as defined by your LDAP schema.
If you prefer to map another attribute value to the attribute name
instead of the default value, then choose User Defined.
The following table lists the default attribute value that is
mapped to each attribute name.
Table 1. Attribute names and values
Attribute Name |
Attribute Value |
E-mail address |
mail |
Telephone |
telephoneNumber |
Title |
title |
Photo |
jpegPhoto (requires the inetOrgPerson objectClass) |
Address |
postalAddress |
Company |
ou |
Name |
cn |
|
|
- If you select User Defined for an Attribute
Value, then enter an attribute to map to the Attribute
Name.
- In the Attribute Definition table,
change the Attribute Value for the attributes
that will be retrieved from the secondary storage to User
Defined and leave the User Defined field
blank. For example, if you are retrieving users' Telephone and Title
information from the custom Notes application;
therefore, change the values for the Telephone & Title attributes
to User Defined, and leave the User
Defined field blank, and then click Reset to
save the changes
Note: These values are blank to ensure
they are retrieved from the secondary repository (the Notes application)
and not from the primary repository, which is the LDAP directory.
- Modify the UserInfoConfig.xml file located in the Domino program directory
(\lotus\domino\UserInfoConfig.xml) using a text editor. The UserInfo
application fetches and delivers user information for each incoming
client request (a user's request to view a particular user's business
card). When you are using an LDAP directory as primary storage and
a custom Notes application
as secondary storage, make these modifications:
- Add the following Notes_CUSTOM_DB
Storage tag inside the Resources tag:
<Storage type="NOTES_CUSTOM_DB">
<StorageDetails DbName="bcardstorage.nsf" View="$BCardView"/>
<Details>
<Detail Id="Title" FieldName="JobTitle" Type="text/plain"/>
<Detail Id="Telephone" FieldName="OfficePhoneNumber" Type="text/plain"/>
</Details>
</Storage>
Note: In the <StorageDetails> tag, the
following settings are specified:
- DbName = database_path Filename of the custom Notes application
(relative path to the Domino data
directory)
- View = view_name The name of the Notes view that
displays the documents containing the user records.
- The <Details> section defines the attributes that will be retrieved
by Sametime from the
corresponding storage repository. In this example, we are pulling
the telephone attribute from the custom Notes application
database
- The attributes Title and Telephone must come from the
custom Notes application
rather than from LDAP, therefore, remove the following information
from the <details> tag of the LDAP storage:
<Detail
Id="Title" FieldName="title" Type="text/plain"/> <Detail Id="Telephone"
FieldName="telephoneNumber" Type="text/plain"/>
- Add the following information to the <BlackBoxConfiguration>
section. Make sure it is listed after the LDAP blackbox as the list
order defines the search order:
<BlackBox type="NOTES_CUSTOM_DB"
name="com.ibm.sametime.userinfo.userinfobb.UserInfoNotesCustomBB"
MaxInstances="4"/>
- The UserInfoConfig.xml now looks like this:
<UserInformation>
<Resources>
<Storage type="LDAP">
<CommonField CommonFieldName="MailAddress"/>
<StorageDetails HostName="ldap.austin.ibm.com" Port="389" UserName="username"
Password="password" SslEnabled="false" SslPort="636" BaseDN="o=ibm" Scope="2"
SearchFilter="(&(objectclass=organizationalPerson)(|(cn=%s)(givenname=%s)
(sn=%s)(mail=%s)))"/>
<!-- Add another StorageDetails tag to support another ldap server.
The listing order implies the searching order -->
<!-- Scope: 0=OBJECT_SCOPE 1=ONELEVEL_SCOPE 2=SUBTREE_SCOPE-->
<SslProperties KeyStorePath="" KeyStorePassword=""/>
<Details>
<Detail Id="MailAddress" FieldName="e-mail" Type="text/plain"/>
<Detail Id="Name" FieldName="cn" Type="text/plain"/>
<Detail Id="Location" FieldName="postalAddress" Type="text/plain"/>
<Detail Id="Company" FieldName="ou" Type="text/plain"/>
<Detail Id="Photo" FieldName="jpegPhoto" Type="image/jpeg"/>
</Details>
</Storage>
<Storage type="NOTES_CUSTOM_DB">
<StorageDetails DbName="bcardstorage.nsf" View="$BCardView"/>
<Details>
<Detail Id="Title" FieldName="JobTitle" Type="text/plain"/>
<Detail Id="Telephone" FieldName="OfficePhoneNumber" Type="text/plain"/>
</Details>
</Storage>
</Resources>
<ParamsSets>
<Set SetId="0" params="MailAddress,Name,Title,Location,Telephone,Photo,Company"/>
<Set SetId="1" params="MailAddress,Name,Title,Location,Telephone,Photo,Company"/>
</ParamsSets>
<BlackBoxConfiguration>
<BlackBox type="LDAP" name="com.ibm.sametime.userinfo.userinfobb.UserInfoLdapBB"
MaxInstances="5"/>
<BlackBox type="NOTES_CUSTOM_DB"
name="com.ibm.sametime.userinfo.userinfobb.UserInfoNotesCustomBB"
MaxInstances="4"/>
</BlackBoxConfiguration>
</UserInformation>
- Restart the Sametime Community
Server and the Domino server
to effect the changes. You have successfully configured the business
card to display information for a single user from dual storage repositories:
an LDAP directory and a custom Notes application.
What to do next
An optional setting in UserInfoConfig.xml file
lets you map a detail to more than one attribute. As a result, the
returned value for a detail is composed of a list of attributes retrieved
from the storage.
You can do this by mapping an item to a comma-separated
list of attributes.
<Detail Id="Telephone" FieldName="telephoneNumber,mobile" Type="text/plain" />
The
response can contain a list of values separated by any character chosen
by the administrator. To apply the new separator, edit the UserInfoConfig.xml file.
- Open UserInfoConfig.xml in an editor.
- Choose the Detail tag that you want to use to retrieve a list
of attributes.
- Complete the FieldName property with the
list of attributes to retrieve, separated by commas.
- Add an additional property: DisplaySeparator.
Set its value to the required character that should appear in the
response XML between any 2 retrieved attributes values. For example, <Detail
Id="Telephone" FieldName="telephoneNumber,mobile" Type="text/plain"
DisplaySeparator="/"/>.
Note: To ensure a correct display
on iOS, use the /
symbol as the displaySeparator
.
- Log in to the WebSphere Integrated
Solutions Console as the WebSphere administrator.
- Click Sametime System Console > Sametime
Servers > Sametime Community Servers.
- In the Sametime Community
Servers list, click the deployment name of the server with the connectivity
information that you want to change.
- Click the Business Card tab.
- Verify that the mapping of this detail (the Telephone detail
in the example) is empty.
- Click OK.
- Restart the server.