WAS v8.5 > End-to-end paths > Communications enabled applications

Set up the communications enabled application samples

We can set up a single-server environment to use the computer telephony integration (CTI) and web collaboration capabilities of IBM WebSphere Application Server v8.5.

  1. Install WAS.

  2. Download and extract the communications enabled application samples

  3. Edit...

      CEA_samples_package/scripts/setupCEA.sh

    ...and customize the variables for the application server environment.

  4. Run setupCEA.sh.

    To manually create an application server profile to host the sample applications.

    1. If necessary, start the Profile Management Tool.

    2. After the Profile Management Tool window opens, click Launch Profile Management Tool.

    3. Click Create.

    4. After the Profile Creation wizard opens, define the following settings:

      Environment Type Application server
      Profile Creation Option Advanced profile creation
      Application Deployment Deploy the dmgr console and the default application. We can deploy the sample applications.
      Profile name AppSrvCEA
      Profile directory Accept the value provided, or change the directory path if we use a different convention.
      Node name AppSrvCEANode01
      Server name server1
      Host name Your_host_name
      Administrative security Define settings appropriate for the environment
      Security Certificate (Part 1) Accept the default settings
      Security Certificate (Part 2) Accept the default settings
      Port Values Assignment Accept the values provided

      The SIP_DEFAULTHOST port is required when performing the following steps:

      • Verify the CEA configuration settings are appropriate
      • Download, install, and configure the free Express Talk Basic softphone
      • Download, install, and configure the free X-Lite softphone

      The WC_defaulthost port is required when performing the following exploration scenarios:

      • Simulate customer service interactions to verify the setup and explore the basic features of the CEA widgets
      • Simulate cobrowsing interactions to further explore the features of the CEA widgets
      • Explore the CEA web service sample application

      Be sure to record these port values before proceeding.

      Web Server Definition Accept the default settings
      Profile Creation Summary Click Create

    5. After the profile is created, close the Profile Management Tool.

    To manually install and start the sample IP PBX enterprise application

    1. Start the application server.

    2. Use the dmgr console to install commsvc.pbx.ear

        Applications | New Application | New Enterprise Application | CEA_samples/installableApps/commsvc.pbx.ear | Next | Fast Path | Next

    3. On the remaining pages, accept the default values, and click Next.

    4. On the summary page, click Finish to save the changes to the local configuration. Then click Save to save the changes directly to the master configuration.

    5. Start the sample IP PBX application.

        Applications | Application Types | WebSphere enterprise applications | commsvc.pbx | Start

    To manually install and start the PlantsByWebSphereAjax for CEA sample application.

    The setup procedure for the PlantsByWebSphere Ajax Edition for CEA application requires the EJBDeploy tool for pre-EJB 3.0 modules. When installing WAS, be sure to include this optional feature. If we are using an existing installation that does not include the EJBDeploy tool, use IBM Installation Manager to modify the installation to include the tool before proceeding.

    1. Go to dmgr console page:

        Resources | JDBC | JDBC Providers

      ...and set the scope to Node=AppSrvCEANode01,server=server1.

    2. Click New.

    3. Specify the following properties:

      Database type Derby
      Provider type Derby JDBC Provider
      Implementation type XA Data source
      Name Derby Provider for PlantsByWebSphereAjax (XA)

    4. Click Next.

    5. On the summary page, click Finish to save the changes to the local configuration.

    6. Click Save to save the changes directly to the master configuration.

    7. Go to...

      ...and set the scope to Node=AppSrvCEANode01,server=server1.

    8. Click New.

    9. Specify the following properties:

      Data source name PLANTSDB
      JNDI name jdbc/PlantsByWebSphereAjaxDataSource

    10. Click Next.

    11. Choose Select an existing JDBC Provider.

    12. Choose Derby Provider for PlantsByWebSphereAjax (XA).

    13. Click Next.

    14. For the Database name, enter (exactly) ${APP_INSTALL_ROOT}/${CELL}/PlantsByWebSphereAjax.ear/Database/PLANTSDB

    15. Use this data source in container managed persistence (CMP).

    16. Click Next.

    17. On the remaining pages, accept the default values and click Next.

    18. On the summary page, click Finish to save the changes to the local configuration.

    19. Click Save to save the changes directly to the master configuration.

  5. Prepare, install, and start the CEA PlantsByWebSphereAjax sample application

    1. Generate EJB deployment bindings (and a new EAR file); for example:

        cd CEA_samples_package/installableApps
        /opt/IBM/WebSphere/AppServer/bin/ejbdeploy.sh PlantsByWebSphere.ear /tmp PlantsByWebSphere_Deployed.ear -dbvendor DERBY_V10

    2. Using the dmgr console, install the application.

      1. Select...

          Applications | New Application | New Enterprise Application

      2. Specify the location of the new EAR file, PlantsByWebSphere_Deployed.ear.

      3. Click Next.

      4. Select the Fast Path option.

      5. Click Next.

      6. On the remaining pages, accept the default values and click Next.

      7. On the summary page, click Finish to save the changes to the local configuration.

      8. Click Save to save the changes directly to the master configuration.

    3. Start the application.

        Applications | Application Types | WebSphere enterprise applications | PlantsByWebSphereAjax | Start

  6. Manually install and start the web service sample application (commsvc.ws.sample.ear)

    1. Select...

        Applications | New Application | New Enterprise Application

    2. Specify the location of the web service sample EAR file

        CEA_samples_package/installableApps/commsvc.ws.sample.ear

    3. Click Next.

    4. Select the Fast Path option.

    5. Click Next.

    6. On the remaining pages, accept the default values and click Next.

    7. On the summary page, click Finish to save the changes to the local configuration. Then click Save to save the changes directly to the master configuration.

  7. Select...

      Applications | Application Types | WebSphere enterprise applications | commsvc.ws.sample application | Start

  8. Verify the CEA and virtual host configuration settings are appropriate.

    1. Display...

        Servers | Server Types | Application servers | server1 | Communications Enabled Applications (CEA)

    2. Verify the following settings are appropriate...

      • Communications Enabled Applications services
        • Enable communications service: Selected
      • REST interface
        • Context root: /commsvc.rest
        • Virtual host: default_host
        • Maximum hold time: 30 seconds
      • Telephony access method
        • Use SIP CTI (ECMA TR/87) gateway for telephony access: Selected
          • Host name or IP address: localhost
          • Port: SIP_DEFAULTHOST port of the application server.
          • Protocol: TCP
          • Extract user name from request: Cleared
          • Superuser name: ceauser

      To determine the correct value for Port, visit...

        Application servers | server1 | Ports

    3. Configure the virtual host default_host. Go to...

      Environment | Virtual hosts | default_host | Host Aliases

      ..and ensure that appropriate host aliases exist for each of the following application server ports:

      • WC_defaulthost
      • WC_defaulthost_secure
      • SIP_DEFAULTHOST
      • SIP_DEFAULTHOST_SECURE

      To determine the correct value (number) for each port...

        Servers | Server Types | Application servers | server | Ports

    4. If you modified any of the configuration settings, complete the following actions:

      1. Click OK to save the changes to the local configuration.
      2. Click Save to save the changes to the master configuration.

    5. Restart the application server.

  9. Download, install, and configure the free Express Talk Basic softphone.

    1. Determine the host name or address, and SIP_DEFAULTHOST port, of the application server running the sample IP PBX application

      To view the port numbers assigned to a given server...

        Application servers | servername | Ports

    2. Download Express Talk Basic using the NCH Software site

    3. Run the Express Talk Basic setup file, talksetup.exe. Then accept the default installation settings.

    4. After the installation completes, a Setup wizard opens. Use the first several pages of the setup wizard to define appropriate speaker and microphone settings. (In many cases, we can simply accept the default settings.)

    5. On the SIP Details page of the Setup wizard, use the following account information to configure Express Talk Basic to serve as a phone for a customer.

      • Full Friendly Display Name: Customer

      • Server (SIP Proxy or Virtual PBX): host name or address of the application server; for example: localhost

      • SIP Number (or User Name): Customer

      • Password: Leave this field blank

    6. Click Finish to save the settings.

    7. If the application server is not using the default SIP_DEFAULTHOST port (5060):

      1. On the main Express Talk Basic window, click the Options button.

      2. After the Options window opens, click the Lines tab.

      3. After the Lines page opens, click the Advanced Line Settings button.

      4. After the Advanced SIP Server window opens, select Use a different outbound server.

      5. In the Outbound Server field, enter hostname:port, where hostname is the host name or address of the application server, and port is the SIP_DEFAULTHOST port of the application server; for example: localhost:5061.

      6. Click OK to save the settings, and close the Advanced SIP Server Settings window.

      7. Click OK to save the settings, and close the Options window.

      If the softphone does not register with the IP PBX, ensure the application server and the sample IP PBX application (commsvc.pbx) are running. Additionally, ensure the SIP_DEFAULTHOST port is not being used by another application, such as an email application.

  10. Download, install, and configure the free X-Lite softphone.

    To complete this set of tasks, you must know the host name or address and SIP_DEFAULTHOST port of the application server that is running the sample IP PBX application.

    To view the port numbersassigned to a given server...

      Application servers | servername | Ports

    1. Download X-Lite from the CounterPath site

    2. Run the X-Lite setup file. Then accept the default installation settings (including the option to start X-Lite after the installation completes).

    3. If we are using X-Lite 4.0, click...

        Softphone | Account Settings

      If we are using X-Lite 3.0, click menu located near the top of the softphone. In the menu that opens, select SIP Account Settings.

    4. To configure X-Lite to serve as a phone for a customer service representative, add a new account with the following settings:

      1. User name: CSR

      2. Domain: Host name or address of the application server that is running the sample IP PBX application; for example: localhost

      3. Display name: CSR

      4. Register with domain and receive incoming calls: Selected

      5. If the application server is using the default SIP_DEFAULTHOST port (5060):

        1. Send outbound using the domain: Selected

      6. If the application server is not using the default SIP_DEFAULTHOST port (5060):

        1. Send outbound using the proxy: Selected

        2. Address: hostname:port, where hostname is the host name or address of the application server, and port is the SIP_DEFAULTHOST port of the application server; for example: localhost:5061.

      If the softphone does not register with the IP PBX, ensure the application server and the sample IP PBX application (commsvc.pbx) are running. Additionally, ensure the SIP_DEFAULTHOST port is not being used by another application, such as an email application.

  11. Verify the telephony system is functioning correctly.

    1. Using the customer softphone, Express Talk Basic, enter sip:CSR@hostname,where hostname is the host name or address of the application server that is running the sample IP PBX application; for example: sip:CSR@localhost.

    2. Click Dial.

    3. After the customer service representative softphone (X-Lite) rings, click the green Answer button (on the customer service representative softphone).

    4. After verifying that a connection is present, click the red Hang Up button on the customer phone or the End button on the customer service representative phone.

  12. Simulate customer service interactions to verify the setup and explore the basic features of the CEA widgets.

    • To complete this set of tasks, you must know the WC_defaulthost port of the application server that is running the PlantsByWebSphereAjax application.

      To view the port numbers assigned to a given server...

        Application servers | servername | Ports

    • Before testing customer service interactions, verify the ClickToCall widget is configured appropriately for the environment.

      First edit...

        contactus.html

      ...located in...

        profile_root/installedApps/<cellName>/PlantsByWebSphereAjax.ear/PlantsByWebSphere.war

      Next, within contactus.html, locate the widgetNumber attribute (widgetNumber="sip:CSR@localhost"). If necessary, replace CSR@localhost with the SIP number (address) to be contacted when a click-to-call request is initiated. SIP phone numbers must be specified in the format sip:userName@hostName, where hostName is the host name or IP address of the IP PBX.

    For more information about the sample application, see the supporting documentation provided in the PlantsByWebSphere directory of the CEA samples package that we can download from the Samples page.

  13. Start the customer and customer service representative softphones.

  14. Acting as a customer service representative, register the CallNotification widget with the communications infrastructure.

    1. Start a new web browser instance and load the PlantsByWebSphereAjax for CEA home page...

        http://hostname:port/PlantsByWebSphereAjax/

      ...where hostname is the host name or address of the application server, and port is the WC_defaulthost port of the appropriate application server; for example:

        http://localhost:9080/PlantsByWebSphereAjax/

    2. Click the Call Notification link.

    3. Within the CallNotification widget, enter...

        sip:CSR@hostname

      ...where hostname is the host name or address of the application server that is running the sample IP PBX application. For example:

        sip:CSR@localhost

    4. Click the Start Call Notification button.

  15. Acting as a customer, use the ClickToCall widget to call (contact) the customer service representative.

    1. Start a new web browser instance and load the PlantsByWebSphereAjax for CEA home page, http://hostname:port/PlantsByWebSphereAjax/, where hostname is the host name or address of the application server, and port is the WC_defaulthost port of the appropriate application server; for example: http://localhost:9080/PlantsByWebSphereAjax/

      Best practice: When completing this task on a single machine, use two separate web browsers from different vendors; otherwise, results are unpredictable. For example, do not attempt to use two tabs within the same instance of a given browser, or even two separate instances of the same browser; for example, Firefox. Always use two separate browsers from different vendors; for example, Firefox and Internet Explorer, Chrome and Safari.

    2. Click the Contact Us link.

    3. Within the ClickToCall widget, enter sip:Customer@hostname ,

      where hostname is the host name or address of the application server that is running the sample IP PBX application; for example: sip:Customer@localhost.

    4. Click the Call Me button.

  16. Acting as the customer service representative, use the X-Lite softphone to answer the call.

  17. Acting as the customer, use the Express Talk Basic softphone to answer the call.

  18. Acting as the customer service representative, use the CallNotification widget to start a web collaboration session with the customer.

    1. Within the CallNotification widget, click Cobrowse.

  19. Acting as the customer service representative, send a web page to the customer. Then verify the customer received the page.

    1. Navigate to an appropriate page, and click Send Page.

    2. Verify the page is displayed in customer's browser.

  20. Acting as the customer service representative, set up the Collaboration Dialog to automatically send the customer each new web page that is viewed. Then verify the customer automatically receives new pages.

    1. Within the Collaboration Dialog, click Follow Me and view several different pages in the site.

    2. Verify the final page is displayed in the customer's browser.

  21. Acting as the customer service representative, highlight an area of a page for the customer. Then verify the area was highlighted correctly in the customer's view.

    1. Within the Collaboration Dialog, click Highlight.

    2. Move your mouse pointer across the page to view the areas of the page that can be highlighted.

    3. Click the area of the page to highlight in the customer's browser.

    4. Verify the same area of the page is highlighted in the customer's browser.

  22. To end the collaboration session...in the web browser of the customer or the customer service representative:

    1. Click the Close icon located in the upper right-hand corner of the Collaboration Dialog.

    2. In the Cobrowse widget, click End Collaboration Session.

  23. Simulate cobrowsing interactions to further explore the features of the CEA widgets.

    To complete this set of tasks, you must know the WC_defaulthost port of the application server that is running the PlantsByWebSphereAjax application.

    To view the port numbers assigned to a given server

      Application servers | servername | Ports

  24. Using the Cobrowse widget, invite a second party to participate in a cobrowsing session.

    1. Start a new web browser instance and load the PlantsByWebSphereAjax for CEA home page, http://hostname:port/PlantsByWebSphereAjax/, where hostname is the host name or address of the application server, and port is the WC_defaulthost port of the application server; for example: http://localhost:9080/PlantsByWebSphereAjax/.

    2. Click the Cobrowse link.

    3. Within the Cobrowse widget, click Create.

    4. Copy the invitation link to the operating system clipboard.

  25. Acting as the second party, join the cobrowsing session.

    Start a new web browser instance and load the invitation link.

    Best practice: When completing this task on a single machine, use two separate web browsers from different vendors; otherwise, results are unpredictable. For example, do not attempt to use two tabs within the same instance of a given browser, or even two separate instances of the same browser; for example, Firefox. Always use two separate browsers from different vendors; for example, Firefox and Internet Explorer, Chrome and Safari.

  26. Acting as the first party, send a web page to the second party. Then verify the second party received the page.

    1. Within the Collaboration Dialog, click Send Page.

    2. Verify the page is displayed in the second party's browser.

  27. Acting as the first party, grant control of page navigation to the second party.

    Within the Collaboration Dialog, click Grant Control.

  28. Acting as the second party, set up the Collaboration Dialog to automatically send the first party each new web page that is viewed. Then verify the second party automatically receives new pages.

    Within the Collaboration Dialog, click Follow Me and view several different pages in the site.

    Verify the final page is displayed in the first party's browser.

  29. Acting as the second party, highlight an area of a page for the first party. Then verify the area was highlighted correctly in the first party's view.

    1. Within the Collaboration Dialog, click Highlight.

    2. Move your mouse pointer across the page to view the areas of the page that can be highlighted.

    3. Click the area of the page to highlight in the first party's browser.

    4. Verify the same area of the page is highlighted in the first party's browser.

  30. To end the collaboration session and the call, complete the following steps in the web browser of either party:

    1. Click the Close icon located in the upper right-hand corner of the Collaboration Dialog.

    2. In the Call Notification or Click-To-Call widget, click End Call.

  31. Explore the CEA web service sample application.

    To complete this set of tasks, you must know the WC_defaulthost port of the application server that is running the commsvc.ws.sample application.

    1. View the port numbers assigned to a given server

        Application servers | servername | Ports

    2. Start the customer and customer service representative softphones.

    3. Start a new web browser instance and load the CEA web service sample page...

        http://hostname:port/commsvc.ws.sample/CommWebServiceServlet

      port is the WC_defaulthost port of the application server; for example...

        http://localhost:9080/commsvc.ws.sample/CommWebServiceServlet

    4. After the CEA web service Sample page opens, enter sip:CSR@hostname in the Phone address of record entry-field, where hostname is the host name or address of the application server that is running the sample IP PBX application; for example:

        sip:CSR@localhost

    5. Click the Open session button to obtain control of the phone.

      A request is sent to the sample servlet, which calls the openSession web service API. It might take a few seconds to set up the session with the phone. A Phone Status page opens, presenting the following fields for monitoring and managing the phone:

      • Address of record
      • Call status
      • Caller
      • Callee
      • Call ID
      We can click the Refresh call status button to obtain status updates the sample servlet has received by way of WS-Notification.

    6. In the Peer address of record entry-field, enter...

        sip:Customer@hostname

      ...where hostname is the host name or address of the application server that is running the sample IP PBX application; for example:

        sip:Customer@localhost

    7. Click the Make call button.

      The sample servlet invokes the makeCall web service API to create a call between the customer (sip:Customer@hostname) and the customer service representative (sip:CSR@hostname).

    8. After the customer service representative (X-Lite) softphone rings, answer the call.

    9. After the customer (Express Talk Basic) softphone rings, answer the call.

    10. Click the Refresh call status button to view details about the call that is in progress.

    11. Click the End call button. The sample servlet invokes the endCall web service API to end the call.

    12. Finally, click the Close session button.

      The sample servlet invokes the closeSession web service API to terminate the phone monitoring session.


Related
Samples documentation


+

Search Tips   |   Advanced Search