cancel
Showing results for 
Search instead for 
Did you mean: 

Programmatically detect a PI channel stopped in RWB

Former Member
0 Kudos

Hello,

Does anybody know a way to programmatically detect a PI channel stopped in RWB?

Thanks,

Shawn

Accepted Solutions (1)

Accepted Solutions (1)

baskar_gopalakrishnan2
Active Contributor
0 Kudos

One possible way is ..

Write a java program and using http command to control the channel. if the channel is already stopped based on the http response we can decide whether the channel is stopped or working. we can achieve this using script too.

Controlling the communication channels using http command as follows...

/people/william.li/blog/2007/05/04/control-communication-channels-externally-without-using-rwb

Example: send stop command and see whether the response is 200 OK. If the response is not good then we can decide the channel is already in sleep state.

http(s)://nspad271.pal.sap.corp:50000/AdapterFramework/ChannelAdminServlet?party=&service=BLService&channel=File1_sender&action=stop

Answers (2)

Answers (2)

Former Member
0 Kudos

Thanks guys.

I do not want to control the communication channel externally. It is controlled by a availability time planning. I am looking for a way to detect if the channel is stopped then send out an alert.

Thanks,

Shawn

baskar_gopalakrishnan2
Active Contributor
0 Kudos

Here you go... Understood your question...

Use Integration Directory API using java program and you can detect whether channel is stopped or not and based on the you can send email notification as an alert.

Refer this.. Through this Api we can access to business components, channels and all ID components

http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/b043ef4e-e8d1-2c10-7d88-8077b209c...

Former Member
0 Kudos

Hi,

Did you checked the below blog...of fetching status info of channel...

/people/katlegojackmohlankana.maja/blog/2011/05/24/startstop-a-communication-channel-from-an-abap-program-using-the-external-control-switch

after that call RFC SALERT_XXXXX...to send an email as per your need...

Hope this gives you some direction to proceed.

Rgds

Rajesh

Former Member
0 Kudos

Thanks Baskar,

It sounds a very good direction. Could you please give more detail steps on how to Use Integration Directory API using java program? I could not link ECC_CUSTOMER001QR to detecting channel status.

baskar_gopalakrishnan2
Active Contributor
0 Kudos

Here you go

http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/a0336199-d3c7-2c10-c983-f8a945a45...

Create a custom Java service (EJB - server side component) and deploy as enterprise Java bean in the netweaver. You can run this program using script or command line to get data. Basically you need to code using the integration directory api and using NWDS tool and very similar to doing development like adapter module.

Former Member
0 Kudos

Thanks Baskar.

former_member854360
Active Contributor
0 Kudos

Hi,

To control communication channels externally, you use an HTTP GET or POST request to the following URL:

http(s)://host:port/AdapterFramework/ChannelAdminServlet?party=party&service=service&channel=channel&action=action

See this wiki,

http://wiki.sdn.sap.com/wiki/display/XI/ExternallyControllingtheCommunicationChannel

http://help.sap.com/saphelp_nwpi711/helpdata/en/45/0c86aab4d14dece10000000a11466f/content.htm

You can easily control comm channel through external control.

Please refer the HELP.SAP material on this.

In RWB you need to enable external control on communication channel.

http://help.sap.com/saphelp_nwpi71/helpdata/en/45/0c86aab4d14dece10000000a11466f/content.htm

To control communication channels externally, you use an HTTP GET or POST request to the following URL:

http(s)://host:port/AdapterFramework/ChannelAdminServlet?party=party&service=service&channel=channel&action=action

The XML structure of the HTTP response is documented in a document type definition (DTD) and an XML schema definition (XSD). You can call this information using HTTP at the following addresses:

● http(s)://host:port/AdapterFramework/channelAdmin/ChannelAdmin.dtd

● http(s)://host:port/AdapterFramework/channelAdmin/ChannelAdmin.xsd

You can try this through internet explorer also

http(s)://host:port/AdapterFramework/ChannelAdminServlet?party=party&service=service&channel=channel&action=action