Setting up the My Portal Alert portlet environment

The My Portal Alert portlet allows users to send and receive messages across the site. To configure WebSphere Commerce to support My Portal Alert, do the following:

Installing Push.jar and Log.jar

  1. Download the Messaging Services and PUSH Toolkit for WebSphere Everyplace Connection Manager from the following URL: http://www.ibm.com/support/docview.wss?uid=swg24005102 Ensure you download the Msg/PUSH Tlkt for WECM 5.0.0.2 package, and select: Messaging Services and PUSH Toolkit for WebSphere Everyplace Connection Manager 5.0.1: msgtoolkit.zip 3.3MB

    Note: You may have to register at the site before downloading the package.

  2. After downloading the package, open it to a temporary directory.
  3. In the temporary directory, open the following folder:
    \messagingtoolkit\java\lib
  4. Copy the file log.jar to the following directory:WC_eardir\Enablement-JCAEWGConnector.rar
  5. In the temporary directory, open the following directory:
    \messagingtoolkit\java\lib\xerces2
  6. Copy the file push.jar to the folllowing directory:WC_eardir\Enablement-JCAEWGConnector.rar

Enabling the EWG Connector

To enable the EWG Connector (for SMS messaging), do the following:

  1. Open the Configuration Manager.
  2. Expand WebSphere Commerce > host_name >Commerce >Instance List> Demo > Transport > Outbound.
  3. Select EWG.
  4. In the main window, select Enable Transport.
  5. Save your changes.

Configuring the File and Short Message Service Transports

Messages sent and received through the My Portal Alert portlet can be either sent directly to the portlet itself, or through SMS. If you are sending messages directly to the portlet you must configure the File transport. If you are sending messages via SMS you must configure the Short Message Service transport to send and receive messages. To configure the File and Short Message Service (SMS) transports, do the following:

  1. Log into the WebSphere Commerce Administration Console using the Store Administrator's ID and password.
  2. Select Store > Store Name. Click OK. The Administration Console opens.
  3. Select Configuration > Transports. The Transport Configuration page displays.
  4. Click Add. The Add Transport page displays.
  5. Select File andShort Message Service. Click Add. The Transport Configuration page redisplays.
  6. Select the File options. Ensure that the status is Active. Click Configure. The Transport Configuration Parameters page displays.
  7. Enter the information in the following fields:
    1. Location: Type the path for the file.
    2. File Name: Type the name of the file.
    3. Mode: Specify either 0 for append or 1 for overwrite.
  8. Click OK. The Transport Configuration page displays.
  9. Select Short Message Service. Ensure that the status is Active. Click Configure. The Transport Configuration Parameters page displays.
  10. Enter the information in the following fields:
    1. Host: Type the URL for the WebSphere Everyplace Connection Manager. This is the URL assigned to the machine that has WebSphere Everyplace Connection Manager installed. For example, http://wirelessgateway.domain
    2. Port: Type the WebSphere Everyplace Connection Manager port number (the default is port 13131).
  11. Click OK. The Transport Configuration page redisplays.

Adding entries to the Struts Configuration File

You must add entries to the Struts Configuration file in order to pre-populate the messaging related views for the MyAlert messages device format that is specific to Short Message Service transport. To add these entries, do the following:

  1. Insert the following SQL statement into the Struts Configuration File:
     <forward className="com.ibm.commerce.struts.ECActionForward" 
    name="ViewName/0/-8" path="=MyAlertDefault.jsp"> 
    <set-property property="resourceClassName" value="com.ibm.commerce.messaging.viewcommands.MessagingViewCommandImpl"/> 
    <set-property property="interfaceName" value="com.ibm.commerce.messaging.viewcommands.MessagingViewCommand"/> 
    <set-property property="implClassName" value="com.ibm.commerce.messaging.viewcommands.MessagingViewCommandImpl"/> 
    <set-property property="direct" value="true"/> 
    </forward> 
    
CloudscapeIf you are using Cloudscape:
  1. Start the full test environment.
  2. Open a Web browser and enter the following URL: http://localhost/webapp/wcs/admin/servlet/db.jsp
  3. In the input box, enter the SQL statement above.
  4. Click Submit Query to run the SQL statements.

Configuring a message type to support the My Portal Alert portlet

To support the My Portal Alert portlet, you must configure a message type to support the following transports:

To configure a message type to support the My Portal Alert portlet, you must do the following:

  1. Log into the WebSphere Commerce Administration Console using the Store Administrator's ID and password.
  2. Select Store > store name. Click OK.
  3. Select Configuration > Message Type.
  4. To configure the file transport, do the following:
    1. From the Message Type Configuration page, click New to configure the file transports. The Message Transport Assignment page displays.
    2. Select the message type from the Message Type field.
    3. Add one of the following values in the Message Severity field:
      • Type 0 in both fields if you want this message type to be subscribable. If a message receiver has not subscribed to this message type, any message sent to this message type is not shown in the My Portal Alert portlet.
      • Type 100 in both fields if you want this message type to be unsubscribable. If a message type is unsubscribable, the message group will not display in the My Portal Alert portlet subscription group. Any message sent to this message type is shown in the My Portal Alert portlet.
    4. Select File in the Transport field. If File does not display in the Transport field, activate the transport in the store profile. For more information, see Assigning a message type to a transport method for a site or store.
    5. Select My Alert Messages in the Device Format field. Click Next. The Change Message Transport Assignment, Parameters page displays.
    6. In the Location field, type a secure directory with restricted access for Store or Site Administrators. The files stored in this directory will hold the messages that are sent to this message type.
    7. In the File Name field, type a unique name for this message type. This file name cannot be shared between message types.
    8. Set the Mode field to 0. Click Finish.
  5. To configure the SMS transport, do the following:
    1. From the Message Type Configuration panel, select New to configure the SMS transport. The Message Transport Assignment page displays.
    2. Select the message type from the Message Type field. This message type should match the message type configured in 4b.
    3. Add one of the following values in the Message Severity field:
      • Type 0 in both fields if you want this message type to be subscribable. If a message receiver has not subscribed to this message type, any message sent to this message type is not shown in the My Portal Alert portlet.
      • Type 100 in both fields if you want this message type to be unsubscribable. If a message type is unsubscribable, the message group will not display in the My Portal Alert portlet subscription group. Any message sent to this message type is shown in your SMS device.
    4. Select Short Message Service in the Transport field. If Short Message Service does not display in the Transport field, activate the transport in the store profile. For more information, see Assigning a message type to a transport method for a site or store.
    5. Select SMS messages in the Device Format field. Click Next. The Message Transport Assignment, Parameters page displays.
    6. Type the WebSphere Everyplace Connection Manager URL in the Host field. This URL was configured as part of the WebSphere Everyplace Connection Manager transport configuration.
    7. Type the WebSphere Everyplace Connection Manager port number (the default is port 13131). Click OK. This port number was configured as part of the WebSphere Everyplace Connection Manager set up.
    8. Type a default list of phone numbers in the Phone Number field. Adding numbers to this field is optional. You can separate the numbers using a comma. If you specify a different list using the WebSphere Commerce messaging API, this list will be ignored.
    9. Type SMTP in the Mode field. This instructs WebSphere Everyplace Connection Manager to send the Short Messages Service messages through SMTP protocol.
    10. Click Finish.
  6. All transports are configured for this message type. Repeat these steps to configure additional message types.
  7. Restart the Commerce Server. For more information, see Starting and Stopping WebSphere Commerce.
Related reference

Feedback