Sun GlassFish Communications Server Diameter Adapter 1.0 Installation and Quick Start Guide

Configuring Diameter for Communications Server

After installation, you are ready to configure the Diameter service. This section provides instructions for configuring the Diameter service by using the Communications Server asadmin Diameter commands.

The following topics are addressed here:

ProcedureTo Configure the Initial Diameter Service

To create the Diameter service, you must use the command line. If you do not specify the target operand, the default instance is used. If the task applies to a cluster, target must specify the cluster name.

After you create the Diameter service by using the create-diameter-service command, the Diameter node appears in the Communications Server Admin Console.

Before You Begin

The Diameter Adapter must be installed before Diameter can be configured.

  1. Create the Diameter service by using the create-diameter-service(1) command.


    asadmin> create-diameter-service target-name
    

    Default target-name is server.

  2. Repeat Step 1 for each additional configuration.

    This is a one-time task per configuration.

  3. Create a Diameter application by using the create-diameter-application(1) command.

    For additional usage information, see To Create a Diameter Application.

  4. Create a Diameter peer by using the create-diameter-peer(1) command.

    For additional usage information, see To Create a Diameter Peer.

  5. Restart the server for changes to take effect.

    Use the stop-domain(1) and start-domain(1) commands.

ProcedureTo Create a Diameter Resource

After configuring the initial Diameter service, you are ready to create a Diameter resource. This section provides instructions for creating a resource for Diameter by using the Communications Server Admin Console.

If you want to work from the command line, you can use the create-admin-object(1) command. Be sure to set the required properties as described in this procedure. For an example command, see Example 2–1.

Before You Begin

The Diameter service, a Diameter application, and a Diameter peer must be created before a Diameter resource can be created.

  1. Open the Admin Console.

  2. Navigate to Resources->Connectors->Admin Object Resource.

  3. Click New.

  4. Select the sundiameter resource adapter.

  5. Select one of the following connection definitions:

    • For Sh Application

      com.sun.diameter.application.sh.api.UserProfileServer

    • For Online Charging Application

      com.sun.diameter.application.credit.ro.api.RoChargingFactory

    • For Offline Charging Application

      com.sun.diameter.application.credit.rf.api.RfChargingFactory

  6. Enter a JNDI name of your choice and click Next.

    The Additional Properties section displays the following Diameter peer properties:

    • PeerId — The ID of the peer

    • Host — Host name or IP address of the peer

    • Port — Port number of the peer

    • Realm — Peer realm

    • SecondaryPeerId — ID of peer to be used when the primary peer is not available

  7. Set PeerId or Host-Port-Realm (others are optional).

    The Host-Port-Realm combination is used to identify unknown peers that are accepted by the Diameter stack.

  8. Configure the PeerId property.

    Specify the peer ID used when creating the peer, such as PeerId: peer_1

  9. Click Finish.


Example 2–1 Creating a Diameter Resource on the Command Line

This example creates a Diameter administered object with JNDI name rf_so.


asadmin> create-admin-object --raname sundiameter --target server 
--property PeerId=charging-peer --restype com.sun.diameter.application.credit.
rf.api.RfChargingFactory diameter/rf_ao 
Command create-admin-object executed successfully.