Code Search for Developers
 
 
  

runconfig_SF_app.html from SmartFrog at Krugle


Show runconfig_SF_app.html syntax highlighted

<html>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">

<head>
<meta HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=ISO-8859-1">
<meta HTTP-EQUIV="Content-Style-Type" CONTENT="text/css">
<meta name="GENERATOR" content="Microsoft FrontPage 5.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<link REL="STYLESHEET" HREF="../../book.css" CHARSET="ISO-8859-1" TYPE="text/css">
<title>Creating SmartFrog run configurations</title>
<style type="text/css">
<!--
.style1 {font-family: "Courier New", Courier, mono}
.style3 {font-family: "Courier New", Courier, mono; font-style: italic; }
.style4 {font-family: Arial, Helvetica, sans-serif}
-->
</style>
</head>

<body>

<h1>Creating SmartFrog run configurations</h1>

<a name="gendesc"></a>
<h2>General description</h2>

<p>In addition to the icons on the SmartFrog Eclipse plug-in's toolbar that allow you to start and stop the SmartFrog daemon and SmartFrog applications (as discussed in the <a href="test_SF_app.html">Testing a SmartFrog application</a> section), you can  create run configurations that also make it  easy for you to launch and debug your SmartFog Java applications. You specify a name for the configuration and define your runtime parameters and classpath specifications for the SmartFrog daemon or some other specific Java application just once. The specified configuration name becomes one of the options when  you select <strong>Run... </strong>or <strong>Debug...</strong> from the <strong>Run</strong> option on the menu bar allowing you to run your application in a single step. </p>

<a name="howto_startdaemon"></a>
<h2>How to create a run configuration to start the SmartFrog daemon</h2>
<h3>Purpose</h3>
<p>To create a run configuration to start the SmartFrog daemon.</p>
<h3>Procedure</h3>
<ol><li>To launch the run configurations dialog, on the SmartFrog Eclipse 
  plug-in menu bar, select <strong>Run</strong> &gt; <strong>Debug ...</strong>. 
  This dialog allows you to create, manage, and run configurations.
  <p><img src="../../images/run_SFd_new.gif"></p>
  </li>
  <li>In the left pane of the dialog page, 
  select <strong>Java Application</strong> 
  and click <strong>New</strong>. This launches a page where you can define
  various run specifications.
 
  </li>
  <li>On the <strong>Main</strong> tab, you must specify the name and main class for your configuration. The <strong>Project:</strong> field can be left blank. Since we are defining this 
  configuration to launch the SmartFrog daemon, in the <strong>Name:</strong> 
  field, we are entering <strong>sfDaemon</strong>. In the <strong>Main class:</strong> field, 
  specify <strong>org.smartfrog.SFSystem</strong> as the main class for the 
  SmartFrog daemon. Check the two Include boxes as shown in the screen shot below:
  <p><img src="../../images/run_SFd_main.gif"></p>
  Click <strong>Apply</strong>.
  </li>
  <li> On the <strong>Arguments</strong> tab, in <strong>VM arguments:</strong> field, you must specify the following:
<pre>
-Dorg.smartfrog.iniFile=<em>SFHOME</em>/bin/default.ini 
-Dorg.smartfrog.sfcore.processcompound.sfDefault.sfDefault=<em>SFHOME</em>/bin/default.sf 
-Dorg.smartfrog.sfcore.processcompound.sfProcessName=rootProcess
</pre>
    <p><img src="../../images/run_SFd_args.gif">
</p>
Note that you must supply the actual value for <span class="style3">SFHOME</span> as shown in the above screen shot. Click <strong>Apply</strong>.
</li>
  <li>On the <strong>Classpath</strong> tab, 
  select <strong>User Entries</strong> and 
  click <strong>Add External JARs...</strong>. 
  Browse to <span class="style1"><em>SFHOME</em>\lib\dist</span> 
  and select <span class="style1">smartfrog.jar</span> 
  and <span class="style1">sfServices.jar</span>.
  <p><img src="../../images/run_SFd_cp.gif" width="760" height="568"></p>
Click <strong>Apply</strong>.
</li>
  <li>On the <strong>Common</strong> tab, check <strong>Run</strong> and <strong>Debug</strong>. 
  Click <strong>Apply</strong> and <strong>Close</strong>. 
  <p><img src="../../images/run_SFd_common.gif" width="760" height="568"></p></li>
  <li>Now you can invoke the SmartFrog daemon by using this configuration definition. 
  Select <strong>Run</strong> &gt; <strong>Run...</strong> or 
  <strong>Run</strong> &gt; <strong>Debug...</strong> from the menu bar. 
  This brings up the Run or Debug dialog with the <strong>sfDaemon</strong> configuration displayed. 
  Select the <strong>sfDaemon</strong> configuration and click <strong>Run</strong> or <strong>Debug</strong> 
  depending on the dialog. The SmartFrog daemon is invoked. </li>
</ol>

<a name="howto_stopdaemon"></a>
<h2>How to create a run configuration to stop the SmartFrog daemon</h2>
<h3>Purpose</h3>
<p>To create a run configuration to stop the SmartFrog daemon.</p>
<h3>Procedure</h3>
<ol>
  <li>Follow steps 1 and 2 in the 
  <a href="#howto_startdaemon">How to create a run configuration to start the 
  SmartFrog daemon</a> section above. </li>
  <li>On the <strong>Main</strong> tab, you must specify the name and main class for your configuration. The <strong>Project:</strong> field can be left blank. Since we are defining this 
  configuration to stop the SmartFrog daemon, in the <strong>Name:</strong> 
  field, we are entering <strong>sfStopDaemon</strong>. In the <strong>Main class:</strong> field, 
  specify <strong>org.smartfrog.SFSystem</strong> as the main class for the 
  SmartFrog daemon. Check the two Include boxes and
  click <strong>Apply</strong>.
  </li>
  <li> 
  On the <strong>Arguments</strong> tab, in the <strong>Program arguments:</strong> field, you must specify the following:
  <pre>
  -a rootProcess:TERMINATE:::localhost: -e
  </pre> 
  <p>In the  <strong>VM arguments:</strong> field, you must specify the following: 
  <pre> 
-Dorg.smartfrog.iniFile=<em>SFHOME</em>/bin/default.ini 
-Dorg.smartfrog.sfcore.processcompound.sfProcessName=rootProcess
</pre>
    <p><img src="../../images/run_stopSFd_args.gif">
</p>
Click <strong>Apply</strong>.
</li>
  <li>On the <strong>Classpath</strong> tab, follow step 5 in the 
  <a href="#howto_startdaemon">How to create a run configuration to start the SmartFrog daemon</a> section above. </li>
  <li>On the <strong>Common</strong> tab, follow step 6 in the 
  <a href="#howto_startdaemon">How to create a run configuration to start the SmartFrog daemon</a> section above.</li>
  <li>Now you can stop the SmartFrog daemon by using this configuration definition. Select <strong>Run</strong> &gt; <strong>Run...</strong> or <strong>Run</strong> &gt; <strong>Debug...</strong> from the menu bar. This brings up the Run or Debug dialog with the <strong>sfStopDaemon</strong> configuration displayed. Select the <strong>sfStopDaemon</strong> configuration and click <strong>Run</strong> or <strong>Debug</strong> depending on the dialog. The SmartFrog daemon is stopped. </li>
</ol>

<a name="howto_startapp"></a>
<h2>How to create a run configuration to start the SmartFrog application</h2>
<h3>Purpose</h3>
<p>To create a run configuration to start the SmartFrog application.</p>
<h3>Procedure</h3>
<ol>
  <li>Follow steps 1 and 2 in the 
  <a href="#howto_startdaemon">How to create a run configuration to start the 
  SmartFrog daemon</a> section above. </li>
  <li>On the <strong>Main</strong> tab, you must specify the name and main class for your configuration. The <strong>Project:</strong> field can be left blank. Since we are defining this 
  configuration to start a SmartFrog application process, in the <strong>Name:</strong> 
  field, we are entering <strong>sfStart</strong>. In the <strong>Main class:</strong> field, 
  specify <strong>org.smartfrog.SFSystem</strong> as the main class for the 
  SmartFrog application. Check the two Include boxes and click <strong>Apply</strong>.  </li>
  <li> 
  On the <strong>Arguments</strong> tab, in the <strong>Program arguments:</strong> field, you must specify the following: 
  <pre>
  -a CounterProcess:DEPLOY:${resource_name}::localhost: -e 
  </pre> 
  <p>Please note that 
  <span class="style1">CounterProcess</span> 
  in this example is the process name of your SmartFrog application, and <span class="style1">${resource_name}</span> is a variable that will be replaced with the name of the description file you have selected in the GUI before starting the application.</p>
  <p>In the <strong>VM arguments:</strong> field, you must specify the following:
  <pre> 
-Dorg.smartfrog.iniFile=<em>SFHOME</em>/bin/default.ini</pre>
    <p>Click <strong>Apply</strong>.
</p>
</li>
  <li>On the <strong>Classpath</strong> tab, follow step 5 in the 
  <a href="#howto_startdaemon">How to create a run configuration to start the SmartFrog daemon</a> section above. </li>
  <li>On the <strong>Common</strong> tab, follow step 6 in the 
  <a href="#howto_startdaemon">How to create a run configuration to start the SmartFrog daemon</a> section above.</li>
  <li>Now you can start the SmartFrog application process by using this configuration definition. Select <strong>Run</strong> &gt; <strong>Run...</strong> or <strong>Run</strong> &gt; <strong>Debug...</strong> from the menu bar. This brings up the Run or Debug dialog with the <strong>sfStart</strong> configuration displayed. Select the <strong>sfStart</strong> configuration and click <strong>Run</strong> or <strong>Debug</strong> depending on the dialog. The SmartFrog application process is launched.</li>
</ol>
<a name="howto_stopapp"></a>
<h2>How to create a run configuration to stop the SmartFrog application</h2>
<h3>Purpose</h3>
<p>To create a run configuration to stop the SmartFrog application.</p>
<h3>Procedure</h3>
<ol>
  <li>Follow steps 1 and 2 in the 
  <a href="#howto_startdaemon">How to create a run configuration to start the 
  SmartFrog daemon</a> section above. </li>
  <li>On the <strong>Main</strong> tab, you must specify the name and main class for your configuration. The <strong>Project:</strong> field can be left blank. Since we are defining this 
  configuration to stop a SmartFrog application process, in the <strong>Name:</strong> 
  field, we are entering <strong>sfStop</strong>. In the <strong>Main class:</strong> field, 
  specify <strong>org.smartfrog.SFSystem</strong> as the main class for the 
  SmartFrog application. Check the two Include boxes and click <strong>Apply</strong>.
  </li>
  <li> 
  On the <strong>Arguments</strong> tab, in the <strong>Program arguments:</strong> field, 
  you must specify the following:
  <pre>
  -a CounterProcess:TERMINATE:::localhost: -e 
  </pre>
  <p>Please note that <span class="style1">CounterProcess</span> 
  in this example is the process name of your SmartFrog application.</p>
  <p>In the <strong>VM arguments:</strong> field, you must specify the following:
  <pre> 
-Dorg.smartfrog.iniFile=<em>SFHOME</em>/bin/default.ini</pre>
  <p>Click <strong>Apply</strong>.</p>
  </li>
  <li>On the <strong>Classpath</strong> tab, follow step 5 in the 
  <a href="#howto_startdaemon">How to create a run configuration to start the SmartFrog daemon</a> section above. </li>
  <li>On the <strong>Common</strong> tab, follow step 6 in the 
  <a href="#howto_startdaemon">How to create a run configuration to start the SmartFrog daemon</a> section above.</li>
  <li>Now you can stop the SmartFrog application process by using this configuration definition. Select <strong>Run</strong> &gt; <strong>Run...</strong> or <strong>Run</strong> &gt; <strong>Debug...</strong> from the menu bar. This brings up the Run or Debug dialog with the <strong>sfStop</strong> configuration displayed. Select the <strong>sfStop</strong> configuration and click <strong>Run</strong> or <strong>Debug</strong> depending on the dialog. The SmartFrog application process is stopped.</li>
</ol>

<a name="howto_startparse"></a>
<h2>How to create a run configuration to start the SmartFrog parser </h2>
<h3>Purpose</h3>
<p>To create a run configuration to start the SmartFrog parser <span class="style4"><SPAN lang=EN-GB style="FONT-SIZE: 10pt">to parse</SPAN> <SPAN lang=EN-GB style="FONT-SIZE: 10pt">a</SPAN><FONT size=2><SPAN lang=EN-GB style="FONT-SIZE: 10pt"> selected SF file to verify </SPAN></FONT><SPAN lang=EN-GB style="FONT-SIZE: 10pt">that </SPAN><FONT size=2><SPAN lang=EN-GB style="FONT-SIZE: 10pt"> the description is correct</SPAN></FONT>.</span></p>
<h3>Procedure</h3>
<ol>
  <li>Follow steps 1 and 2 in the 
  <a href="#howto_startdaemon">How to create a run configuration to start the 
  SmartFrog daemon</a> section above. </li>
  <li>On the <strong>Main</strong> tab, you must specify the name and main class for your configuration. The <strong>Project:</strong> field can be left blank. Since we are defining this 
  configuration to start the SmartFrog parser, in the <strong>Name:</strong> 
  field, we are entering <strong>sfParse</strong>. In the <strong>Main class:</strong> field, 
  specify <strong>org.smartfrog.SFParse</strong> as the main class for the 
  SmartFrog parser. Check the two Include boxes and click <strong>Apply</strong>.
  </li>
  <li> On the <strong>Arguments</strong> tab, in the <strong>Program arguments:</strong> field, you must specify the following:
    <pre>
  -v ${resource_name} 
    </pre>
	<p>Please note that <span class="style1">${resource_name}</span> 
  is a variable that will be replaced with the name of the description file you have selected in the GUI before starting the parser. </p>
	<p>In the <strong>VM arguments:</strong> field, you must specify the following:
    <pre> 
-Dorg.smartfrog.iniFile=<em>SFHOME</em>/bin/default.ini</pre>
    <p>Click <strong>Apply</strong>.</p>
  </li>
  <li>On the <strong>Classpath</strong> tab, follow step 5 in the 
  <a href="#howto_startdaemon">How to create a run configuration to start the SmartFrog daemon</a> section above. </li>
  <li>On the <strong>Common</strong> tab, follow step 6 in the 
  <a href="#howto_startdaemon">How to create a run configuration to start the SmartFrog daemon</a> section above.</li>
  <li>Now you can start the SmartFrog parser by using this configuration definition. Select <strong>Run</strong> &gt; <strong>Run...</strong> or <strong>Run</strong> &gt; <strong>Debug...</strong> from the menu bar. This brings up the Run or Debug dialog with the <strong>sfParse</strong> configuration displayed. Select the <strong>sfParse</strong> configuration and click <strong>Run</strong> or <strong>Debug</strong> depending on the dialog. The SmartFrog parser is launched.</li>
</ol>
<a name="sum"></a>
<h2>Summary</h2>

<p>In the SmartFrog Eclipse plug-in,  you can define run configurations that allow 
you to run and debug your SmartFrog applications easily by creating shortcuts 
for these configurations when you select the <strong>Run</strong> option on the menu bar. </p>


<p><img border="0" src="../../images/ngrelt.gif" alt="Related tasks" width="159" height="27" /></p>
<ul>
<li>
<a href="create_SF_project.html">Creating a SmartFrog project</a>
</li>
<li>
<a href="create_SF_desc.html">Creating a SmartFrog description file</a>
</li>
<li>
<a href="create_SF_java.html">Creating a Java component file with SmartFrog interfaces</a>
</li>
<li><a href="test_SF_app.html">Testing a SmartFrog application</a></li>
<li>
  <a href="../tasks/spec_diff_install.html">Specifying SmartFrog properties</a></li>
</ul>
<p><img border="0" src="../../images/ngrelc.gif" alt="Related concepts" width="159" height="27" /></p>
<ul>
<li>
<a href="../concepts/concepts.html">SmartFrog introduction</a></li>
<li><a href="../concepts/concepts_goals.html">SmartFrog goals
  </a>
</li>
<li>
<a href="../concepts/concepts_approach.html"> SmartFrog approach
</a>
</li>
<li>
<a href="../concepts/concepts_framework.html">
SmartFrog framework</a></li>
</ul>
<p><img src="../../images/ngrelr.gif" alt="Related reference" width="159" height="27" /></p>
<ul><li><a href="http://www.hpl.hp.com/research/smartfrog/">SmartFrog Web site</a> </li>
<li> <a href=
"http://www.smartfrog.org/manuals/current/sfReference.pdf"> SmartFrog Reference Manual</a> </li>
<li> <a href=
"http://www.smartfrog.org/manuals/current/sfUserManual.pdf"> SmartFrog User Manual</a> </li>
<li> <a href=
"http://www.smartfrog.org/manuals/current/SFGuiManual.pdf"> SmartFrog GUI Quick Reference Guide (Draft)</a> </li>
<li> <a href=
"http://www.smartfrog.org/manuals/current/sfWorkflow.pdf"> SmartFrog Work Flow Manual (Draft)</a> </li>
<li> <a href=
"http://www.smartfrog.org/manuals/current/sfDynamicWebServerExample.pdf"> SmartFrog Dynamic Web Server Example</a></li>
<li> <a href="http://eclipse.org">Eclipse Web site</a></li>
</ul>

<p>
<a href="http://eclipse.org">Eclipse Web site</a> </p>

<p><img src="../../images/hp_copyright.gif" width="314" height="32"></p>

</body>

</html>




See more files for this project here

SmartFrog

SmartFrog (Smart Framework for Object Groups) is a framework for configuring and automatically activating distributed applications. \r\nThe SmartFrog framework is released under LGPL license.\r\nMore info at: www.smartfrog.org

Project homepage: http://sourceforge.net/projects/smartfrog
Programming language(s): Java,XML
License: other

  SF_desc_example.txt
  SF_java_example.txt
  create_SF_desc.html
  create_SF_java.html
  create_SF_project.html
  runconfig_SF_app.html
  spec_diff_install.html
  test_SF_app.html