Notice: This Wiki is now read only and edits are no longer possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.
RSA Console Commands
In version 3.14.0, ECF has introduced a number of Gogo console commands for monitoring and controlling Remote Services by using the OSGi Remote Service Admin (RSA) service. RSA is specified by chapter 122 of the OSGi Compendium specification, and provides the means to examine, export (make available to remote processes) and import (use/consume) remote services.
Gogo Command Scope - The gogo command scope for the following commands is ecf
Toggling RSA Debug Output
By default, RSA output (remote service export registrations, import registrations, unexport registrations, and unimport registrations, along with the associated Endpoint Description (EDEF) are output to the console. To turn the rsa debug output on/off:
Command: rsadebug
Example
osgi> rsadebug RSA debugging OFF osgi> rsadebug RSA debugging ON
Listing Exports
Command: listexports|lexps
Argument:
[endpointid] - Optional. If present, details (edef) are presented about the endpoint with the given endpointid. If not present, a table is presented with Endpoint Id, Exporting Container ID, and Exported Service Id.
Example
osgi> listexports Endpoint Id |Exporting Container ID |Exported Service Id 58176215-e890-4107-aa8b-1055510186da |ecftcp://localhost:3288/server |83 osgi> lexps 58176215-e890-4107-aa8b-1055510186da <endpoint-descriptions xmlns="http://www.osgi.org/xmlns/rsa/v1.0.0"> <endpoint-description> <property name="ecf.endpoint.id" value-type="String" value="ecftcp://localhost:3288/server"/> <property name="ecf.endpoint.id.ns" value-type="String" value="org.eclipse.ecf.core.identity.StringID"/> <property name="ecf.endpoint.ts" value-type="Long" value="1520450143497"/> <property name="ecf.exported.async.interfaces" value-type="String" value="*"/> <property name="ecf.generic.server.hostname" value-type="String" value="localhost"/> <property name="ecf.generic.server.port" value-type="String" value="3288"/> <property name="ecf.rsvc.id" value-type="Long" value="1"/> <property name="endpoint.framework.uuid" value-type="String" value="74747fb9-e9db-4b29-8e4c-882b68a2b03b"/> <property name="endpoint.id" value-type="String" value="58176215-e890-4107-aa8b-1055510186da"/> <property name="endpoint.package.version.com.mycorp.examples.timeservice" value-type="String" value="2.0.0"/> <property name="endpoint.service.id" value-type="Long" value="83"/> <property name="objectClass" value-type="String"> <array> <value>com.mycorp.examples.timeservice.ITimeService</value> </array> </property> <property name="remote.configs.supported" value-type="String"> <array> <value>ecf.generic.server</value> </array> </property> <property name="remote.intents.supported" value-type="String"> <array> <value>passByValue</value> <value>exactlyOnce</value> <value>ordered</value> </array> </property> <property name="service.imported" value-type="String" value="true"/> <property name="service.imported.configs" value-type="String"> <array> <value>ecf.generic.server</value> </array> </property> </endpoint-description> </endpoint-descriptions>
Listing Imports
Command: listimports|limps
Arguments:
[endpointid] - Optional. If present, details (edef) are presented about the endpoint with the given endpointid. If not present, a table is presented with Endpoint Id, Importing Container ID, and Imported Service Id.
Example:
osgi> limps Endpoint Id |Importing Container ID |Imported Service Id 58176215-e890-4107-aa8b-1055510186da |dXJ7UaozuFB+sWL22joWHpsf+RQ= |84 osgi> listimports 58176215-e890-4107-aa8b-1055510186da <endpoint-descriptions xmlns="http://www.osgi.org/xmlns/rsa/v1.0.0"> <endpoint-description> <property name="ecf.endpoint.id" value-type="String" value="ecftcp://localhost:3288/server"/> <property name="ecf.endpoint.id.ns" value-type="String" value="org.eclipse.ecf.core.identity.StringID"/> <property name="ecf.endpoint.ts" value-type="Long" value="1520450143497"/> <property name="ecf.exported.async.interfaces" value-type="String" value="*"/> <property name="ecf.generic.server.hostname" value-type="String" value="localhost"/> <property name="ecf.generic.server.port" value-type="String" value="3288"/> <property name="ecf.rsvc.id" value-type="Long" value="1"/> <property name="endpoint.framework.uuid" value-type="String" value="74747fb9-e9db-4b29-8e4c-882b68a2b03b"/> <property name="endpoint.id" value-type="String" value="58176215-e890-4107-aa8b-1055510186da"/> <property name="endpoint.package.version.com.mycorp.examples.timeservice" value-type="String" value="2.0.0"/> <property name="endpoint.service.id" value-type="Long" value="83"/> <property name="objectClass" value-type="String"> <array> <value>com.mycorp.examples.timeservice.ITimeService</value> </array> </property> <property name="remote.configs.supported" value-type="String"> <array> <value>ecf.generic.server</value> </array> </property> <property name="remote.intents.supported" value-type="String"> <array> <value>passByValue</value> <value>exactlyOnce</value> <value>ordered</value> </array> </property> <property name="service.imported.configs" value-type="String"> <array> <value>ecf.generic.client</value> </array> </property> </endpoint-description> </endpoint-descriptions>
Remote Service Export
RSA allows the exporting of a given OSGi service. Exporting results in the creation/setup of a remote service distribution provider, and typically the publish of an Endpoint Description for discovery by remotes.
Command: exportservice|expsvc
Arguments:
service.id - Required. This is the id of a OSGi service reference to export. [overridingproperties] - Optional. This is a map of service properties provided for overriding the values specific when the OSGi service was registered.