Jump to: navigation, search

Difference between revisions of "SMILA/Project Concepts/CrawlerController Remote Management"

(Description.)
m
 
(2 intermediate revisions by 2 users not shown)
Line 2: Line 2:
  
 
=== How to manage CrawlerController remotely ===
 
=== How to manage CrawlerController remotely ===
Bundle org.eclipse.eilf.management.crawlercontroller allows remote management of the CrawlerController.
+
Bundle org.eclipse.smila.management.crawlercontroller allows remote management of the CrawlerController.
Currently the following methods of the CrawlerController are offered for management:  
+
Currently the following methods of the CrawlerController are offered for management:
 +
 
 
- startCrawl(String dataSourceId),
 
- startCrawl(String dataSourceId),
 +
 
- stopCrawl(String dataSourceId),
 
- stopCrawl(String dataSourceId),
 +
 
- getStatus(String dataSourceId)
 
- getStatus(String dataSourceId)
 +
 
- getActiveCrawls()
 
- getActiveCrawls()
  
To activate remote JMX management EILF application must be started with the following JVM arguments:
+
 
 +
To activate remote JMX management SMILA application must be started with the following JVM arguments:
 
<source lang="text">
 
<source lang="text">
 
-Dcom.sun.management.jmxremote
 
-Dcom.sun.management.jmxremote
Line 20: Line 25:
 
=== JMX agent application ===
 
=== JMX agent application ===
 
JMX agent application (jmxagent) allows remote management of the CrawlerController and batch execution of the CrawlerController methods.
 
JMX agent application (jmxagent) allows remote management of the CrawlerController and batch execution of the CrawlerController methods.
jmxagent is currently available at [[https://svn.brox.de/svn/eccenca/PoC/GenericMonitoring/org.eclipse.eilf.monitoring.jmxagent]]
+
Jmxagent is available as bundle of the SMILA project org.eclipse.smila.monitoring.jmxagent, but it will be also compiled into the jmxagent-folder of SMILA.
It can be started as a java application in Eclipse, or compiled with ant command and then started from console with the appropriate run script from build directory (run.bat or run.sh).
+
It can be started as a java application in Eclipse, or from console with the appropriate run script from build directory (run.bat or run.sh).
You can also check sample batch execution script sample.sh.
+
You can also check sample batch execution script startcrawl.sh or starcrawl.bat.
Latest build of the agent can also be downloaded at [[https://bugs.brox.de/bamboo/download/ECCENCA-CCREMOTECLIENT/artifacts/latest/latest/jmxagent.zip]]
+
 
  
 
=== Configuring the JMX agent application ===
 
=== Configuring the JMX agent application ===
Line 29: Line 34:
 
==== Using command line arguments ====
 
==== Using command line arguments ====
 
jmxagent run.bat or run.sh script must be provided with the following arguments:
 
jmxagent run.bat or run.sh script must be provided with the following arguments:
* agent - remote management agent name to connect to (org.eclipse.eilf.connectivity.framework.CrawlerController for the CrawlerController management agent)
+
* agent - remote management agent name to connect to (org.eclipse.smila.connectivity.framework.CrawlerController for the CrawlerController management agent)
 
<source lang="text">
 
<source lang="text">
Remote management agent is a bundle that provides service that implements org.eclipse.eilf.management.ManagementAgent interface.
+
Remote management agent is a bundle that provides service that implements org.eclipse.smila.management.ManagementAgent interface.
 
</source>
 
</source>
 
* cmd - command to execute, for example startCrawl;
 
* cmd - command to execute, for example startCrawl;
Line 37: Line 42:
 
For example:
 
For example:
 
<source lang="java">
 
<source lang="java">
run.bat -agent=org.eclipse.eilf.connectivity.framework.CrawlerController -cmd=startCrawl -dataSourceId=file
+
run.bat -agent=org.eclipse.smila.connectivity.framework.CrawlerController -cmd=startCrawl -dataSourceId=file
 
</source>
 
</source>
  

Latest revision as of 04:23, 15 October 2008

Description.

How to manage CrawlerController remotely

Bundle org.eclipse.smila.management.crawlercontroller allows remote management of the CrawlerController. Currently the following methods of the CrawlerController are offered for management:

- startCrawl(String dataSourceId),

- stopCrawl(String dataSourceId),

- getStatus(String dataSourceId)

- getActiveCrawls()


To activate remote JMX management SMILA application must be started with the following JVM arguments:

-Dcom.sun.management.jmxremote
-Dcom.sun.management.jmxremote.ssl=false
-Dcom.sun.management.jmxremote.authenticate=false
-Dcom.sun.management.jmxremote.port=9004

CrawlerController can be managed with any JMX agent, for example JConsole.

JMX agent application

JMX agent application (jmxagent) allows remote management of the CrawlerController and batch execution of the CrawlerController methods. Jmxagent is available as bundle of the SMILA project org.eclipse.smila.monitoring.jmxagent, but it will be also compiled into the jmxagent-folder of SMILA. It can be started as a java application in Eclipse, or from console with the appropriate run script from build directory (run.bat or run.sh). You can also check sample batch execution script startcrawl.sh or starcrawl.bat.


Configuring the JMX agent application

Using command line arguments

jmxagent run.bat or run.sh script must be provided with the following arguments:

  • agent - remote management agent name to connect to (org.eclipse.smila.connectivity.framework.CrawlerController for the CrawlerController management agent)
Remote management agent is a bundle that provides service that implements org.eclipse.smila.management.ManagementAgent interface.
  • cmd - command to execute, for example startCrawl;
  • dataSourceId - optional parameter, if dataSourceId is missing it's assumed that operation doesn't have any parameters.

For example:

run.bat -agent=org.eclipse.smila.connectivity.framework.CrawlerController -cmd=startCrawl -dataSourceId=file

In addition, following JMX configuration arguments can be provided (optionally):

  • host - JMX server host (default is localhost)
  • port - JMX server port number (default is 9004)

Using properties file.

JMX agent application can be also configured using configuration.properties file. By default it contains default values for host and port properties. Any other command line arguments described above can be placed into configuration.properties file too. Properties from this file will be overridden by the provided corresponding command line properties. The default values host=localhost and port=9004 will be used even if host or port was not specified neither in command line nor in properties file.