...
The ServiceMix SMPP component provides support for receiving and sending SMS using the SMPP protocol via the enterprise service bus. It uses the jSMPP library.
Note |
---|
|
Note that this component is now available only in snapshot, not yet included in a ServiceMix release. |
Installation
Simply drop the servicemix-smpp installer zip in an hotdeploy directory monitored by ServiceMix.
Endpoints
...
lang | xml |
---|
title | Consumer Endpoint |
---|
...
Maven Archetype
You can use Maven servicemix-smpp-service-unit archetype to create a SMPP service unit:
Code Block |
---|
mvn archetype:create \
-DarchetypeGroupId=org.apache.servicemix.tooling \
-DarchetypeArtifactId=servicemix-smpp-service-unit \
-DarchetypeVersion=2010.01 \
-DgroupId=your.group.id \
-DartifactId=your.artifact.id \
-Dversion=your-version
|
Once you've customized the service unit, simply install the SU:
Info |
---|
Remember that to be deployable in ServiceMix, the ServiceUnit has to be embedded in a Service Assembly: only the Service Assembly zip file can be deployed in ServiceMix. To add your SU in a SA, you need to define it in the dependency sets: Code Block |
---|
<dependency>
<groupId>your.group.id</groupId>
<artifactId>your.artifact.id</artifactId>
<version>your-version</version>
</dependency>
|
|
Endpoints Configuration
Consumer Endpoint
A SMPP Consumer endpoint connects to a SMPP server, waiting for incoming SMS message. When a SMS message comes, the endpoint converts it into a JBI message (using the marshaler) and send to the NMR.
...
Code Block |
---|
lang | xml |
---|
title | Provider Consumer Endpoint |
---|
|
<smpp:providerconsumer service="test:service"
endpoint="endpoint"
host="smpp.example.com"
port="2700"
systemId="user"
password="passwd"/>
|
Info |
---|
title | Consumer endpoint attributesEndpoint Attributes |
---|
borderStyle | solidbgColor='lightblue' |
---|
|
Name | Type | Description | Default |
---|
service | QName | the service name of the endpoint | require to be spec'd | endpoint | string | the endpoint name of the endpoint | require to be spec'd | targetService | QName QName | the service name of the target endpoint | | targetEndpoint | string | the endpoint name of the target endpoint | | host | string | the SMPP server hostname/IP | require to be spec'd | port | int | the SMPP server port number | 2700 | systemId | string | the SMPP user system ID | require to be spec'd | password | string | the SMPP user password | require to be spec'd | marshaler | class | org.apache.servicemix.smpp.marshaler.SmppMarshalerSupport | DefaultSmppMarshaler |
|
...
Provider Endpoint
A SMPP Provider endpoint expects messages coming from the NMR, converts it into a SMS message (using the marshaler) and send to the SMPP server.
Code Block |
---|
lang | xml |
---|
title | Provider Endpoint |
---|
|
<smpp:provider service="test:service"
endpoint="endpoint"
host="smpp.example.com"
port="2700"
systemId="user"
password="passwd"/>
|
Info |
---|
title | Provider endpoint attributesEndpoint Attributes |
---|
borderStyle | solidbgColor='lightblue' |
---|
|
Name | Type | Description | Default |
---|
service | QName | the service name of the endpoint | require to be spec'd | endpoint | string | the endpoint name of the endpoint | require to be spec'd | targetService | QName | the service name of the target endpoint | | targetEndpoint | string | the endpoint name of the target endpoint | | host | string | the SMPP server hostname/IP | require to be spec'd | port | int | the SMPP server port number | 2700 | systemId | string | the SMPP user system ID | require to be spec'd | password | string | the SMPP user password | require to be spec'd | marshaler | class | org.apache.servicemix.smpp.marshaler.SmppMarshalerSupport | DefaultSmppMarshaler |
|
...