diff options
author | William R. Otte <wotte@dre.vanderbilt.edu> | 2009-02-06 19:52:25 +0000 |
---|---|---|
committer | William R. Otte <wotte@dre.vanderbilt.edu> | 2009-02-06 19:52:25 +0000 |
commit | dad4cd7e92484124591bea382ae285dffbba9b40 (patch) | |
tree | 505a76be7c281b91f519440e62c5fc0c2247ea0c | |
parent | 25cc2866a794bb3015de2b952b6d9dced35b0074 (diff) | |
download | ATCD-dad4cd7e92484124591bea382ae285dffbba9b40.tar.gz |
ChangeLogTag: Fri Feb 6 19:51:02 UTC 2009 William R. Otte <wotte@dre.vanderbilt.edu>
-rw-r--r-- | flat/CIAO/ChangeLog | 28 | ||||
-rwxr-xr-x | flat/CIAO/DAnCE/bin/PythonDAnCE/generator/comp_impl.py | 4 | ||||
-rwxr-xr-x | flat/CIAO/DAnCE/bin/PythonDAnCE/generator/home_impl.py | 6 | ||||
-rwxr-xr-x | flat/CIAO/DAnCE/bin/generate_plan.py | 9 | ||||
-rw-r--r-- | flat/CIAO/examples/BasicSP/descriptors/BasicSP_Homed.cdp | 504 | ||||
-rwxr-xr-x | flat/CIAO/examples/BasicSP/descriptors/run_test.pl | 5 |
6 files changed, 543 insertions, 13 deletions
diff --git a/flat/CIAO/ChangeLog b/flat/CIAO/ChangeLog index 87ed281190b..f8d03321b40 100644 --- a/flat/CIAO/ChangeLog +++ b/flat/CIAO/ChangeLog @@ -1,19 +1,35 @@ +Fri Feb 6 19:51:02 UTC 2009 William R. Otte <wotte@dre.vanderbilt.edu> + + * DAnCE/bin/PythonDAnCE/generator/comp_impl.py: + * DAnCE/bin/PythonDAnCE/generator/home_impl.py: + * DAnCE/bin/generate_plan.py: + + Fixes to better handle namespaces components may be declared in. + + * examples/BasicSP/descriptors/run_test.pl: + + Will run plan specified on commad line. + + * examples/BasicSP/descriptors/BasicSP_Homed.cdp: + + Same as the _Unhomed plan, except all components are explicitly homed. + Fri Feb 6 19:36:03 UTC 2009 William R. Otte <wotte@dre.vanderbilt.edu> * examples/BasicSP/BMClosedED/BMClosedED_exec.cpp: * examples/BasicSP/BMDevice/BMDevice_exec.cpp: * examples/BasicSP/BMDisplay/BMDisplay_exec.cpp: * examples/BasicSP/EC/EC_exec.cpp: - + Raised the priority of logging messages so they would appear - without CIAO_LOG_LEVEL being set. - + without CIAO_LOG_LEVEL being set. + * examples/BasicSP/EC/controller.cpp: * examples/BasicSP/descriptors/BasicSP_Unhomed.cdp: * examples/BasicSP/descriptors/run_test.pl: - - Fixes necessary to make this test work. - + + Fixes necessary to make this test work. + Fri Feb 6 19:22:40 UTC 2009 William R. Otte <wotte@dre.vanderbilt.edu> * DAnCE/NodeApplication/NodeApplication_Impl.cpp: diff --git a/flat/CIAO/DAnCE/bin/PythonDAnCE/generator/comp_impl.py b/flat/CIAO/DAnCE/bin/PythonDAnCE/generator/comp_impl.py index 6c311bc56bc..eaf2ff52d68 100755 --- a/flat/CIAO/DAnCE/bin/PythonDAnCE/generator/comp_impl.py +++ b/flat/CIAO/DAnCE/bin/PythonDAnCE/generator/comp_impl.py @@ -17,7 +17,7 @@ def template (component_name) : <kind>tk_string</kind> </type> <value> - <string>create_Simple_${component_name}_Impl</string> + <string>create_${namespace}${component_name}_Impl</string> </value> </value> </execParameter> @@ -28,7 +28,7 @@ def template (component_name) : <kind>tk_string</kind> </type> <value> - <string>create_Simple_${component_name}_Servant</string> + <string>create_${namespace}${component_name}_Servant</string> </value> </value> </execParameter> diff --git a/flat/CIAO/DAnCE/bin/PythonDAnCE/generator/home_impl.py b/flat/CIAO/DAnCE/bin/PythonDAnCE/generator/home_impl.py index 18da2fc27b3..87c14a68070 100755 --- a/flat/CIAO/DAnCE/bin/PythonDAnCE/generator/home_impl.py +++ b/flat/CIAO/DAnCE/bin/PythonDAnCE/generator/home_impl.py @@ -1,7 +1,7 @@ from templet import stringfunction @stringfunction -def template (component_name) : +def template (component_name, namespace) : """ <implementation xmi:id="${component_name}HomeImplementation"> <name>${component_name}HomeImplementation</name> @@ -16,7 +16,7 @@ def template (component_name) : <kind>tk_string</kind> </type> <value> - <string>create_Simple_${component_name}Home_Impl</string> + <string>create_${namespace}${component_name}Home_Impl</string> </value> </value> </execParameter> @@ -27,7 +27,7 @@ def template (component_name) : <kind>tk_string</kind> </type> <value> - <string>create_Simple_${component_name}Home_Servant</string> + <string>create_${namespace}${component_name}Home_Servant</string> </value> </value> </execParameter> diff --git a/flat/CIAO/DAnCE/bin/generate_plan.py b/flat/CIAO/DAnCE/bin/generate_plan.py index 1dee2cbb708..15310877bec 100755 --- a/flat/CIAO/DAnCE/bin/generate_plan.py +++ b/flat/CIAO/DAnCE/bin/generate_plan.py @@ -21,6 +21,8 @@ def parse_args (): type="string", help="Homed component types to be included") parser.add_option ("-u", "--uuid", dest="uuid", action="store", type="string", help="UUID for the generated plan") + parser.add_option ("-n", "--namespace", dest="namespace", action="store", default="", + type="string", help="IDL namespace any components may be in") (options, arguments) = parser.parse_args () @@ -36,11 +38,14 @@ def main (): retval += generator.header.template (opts.uuid) artifacts = {} + + if opts.namespace != "": + opts.namespace += "_" #implementations if opts.homes is not None: for item in opts.homes: - retval += generator.home_impl.template (item) + retval += generator.home_impl.template (item, opts.namespace) artifacts[item] = 1 if opts.homed_components is not None: @@ -50,7 +55,7 @@ def main (): if opts.components is not None: for item in opts.components: - retval += generator.comp_impl.template (item) + retval += generator.comp_impl.template (item, opts.namespace) artifacts[item] = 1 #instances diff --git a/flat/CIAO/examples/BasicSP/descriptors/BasicSP_Homed.cdp b/flat/CIAO/examples/BasicSP/descriptors/BasicSP_Homed.cdp new file mode 100644 index 00000000000..81ac15e7fe5 --- /dev/null +++ b/flat/CIAO/examples/BasicSP/descriptors/BasicSP_Homed.cdp @@ -0,0 +1,504 @@ +<Deployment:DeploymentPlan + xmlns:Deployment="http://www.omg.org/Deployment" + xmlns:xmi="http://www.omg.org/XMI" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://www.omg.org/Deployment Deployment.xsd"> + <label>BasicSP_Homed</label> + <UUID>BasicSP_Homed</UUID> + <implementation xmi:id="ECHomeImplementation"> + <name>ECHomeImplementation</name> + <source/> + <artifact xmi:idref="EC_ExecArtifact" /> + <artifact xmi:idref="EC_SvntArtifact" /> + <execParameter> + <!-- entrypoint as exec parameter (see 10.6.1) --> + <name>home factory</name> + <value> + <type> + <kind>tk_string</kind> + </type> + <value> + <string>create_BasicSP_ECHome_Impl</string> + </value> + </value> + </execParameter> + <execParameter> + <name>edu.vanderbilt.dre.CIAO.ServantEntrypoint</name> + <value> + <type> + <kind>tk_string</kind> + </type> + <value> + <string>create_BasicSP_ECHome_Servant</string> + </value> + </value> + </execParameter> + <execParameter> + <name>edu.vanderbilt.dre.CIAO.ServantArtifact</name> + <value> + <type> + <kind>tk_string</kind> + </type> + <value> + <string>EC_svnt</string> + </value> + </value> + </execParameter> + <execParameter> + <name>edu.vanderbilt.dre.CIAO.ExecutorArtifact</name> + <value> + <type> + <kind>tk_string</kind> + </type> + <value> + <string>EC_exec</string> + </value> + </value> + </execParameter> + </implementation> + <implementation xmi:id="BMClosedEDHomeImplementation"> + <name>BMClosedEDHomeImplementation</name> + <source/> + <artifact xmi:idref="BMClosedED_ExecArtifact" /> + <artifact xmi:idref="BMClosedED_SvntArtifact" /> + <execParameter> + <!-- entrypoint as exec parameter (see 10.6.1) --> + <name>home factory</name> + <value> + <type> + <kind>tk_string</kind> + </type> + <value> + <string>create_BasicSP_BMClosedEDHome_Impl</string> + </value> + </value> + </execParameter> + <execParameter> + <name>edu.vanderbilt.dre.CIAO.ServantEntrypoint</name> + <value> + <type> + <kind>tk_string</kind> + </type> + <value> + <string>create_BasicSP_BMClosedEDHome_Servant</string> + </value> + </value> + </execParameter> + <execParameter> + <name>edu.vanderbilt.dre.CIAO.ServantArtifact</name> + <value> + <type> + <kind>tk_string</kind> + </type> + <value> + <string>BMClosedED_svnt</string> + </value> + </value> + </execParameter> + <execParameter> + <name>edu.vanderbilt.dre.CIAO.ExecutorArtifact</name> + <value> + <type> + <kind>tk_string</kind> + </type> + <value> + <string>BMClosedED_exec</string> + </value> + </value> + </execParameter> + </implementation> + <implementation xmi:id="BMDeviceHomeImplementation"> + <name>BMDeviceHomeImplementation</name> + <source/> + <artifact xmi:idref="BMDevice_ExecArtifact" /> + <artifact xmi:idref="BMDevice_SvntArtifact" /> + <execParameter> + <!-- entrypoint as exec parameter (see 10.6.1) --> + <name>home factory</name> + <value> + <type> + <kind>tk_string</kind> + </type> + <value> + <string>create_BasicSP_BMDeviceHome_Impl</string> + </value> + </value> + </execParameter> + <execParameter> + <name>edu.vanderbilt.dre.CIAO.ServantEntrypoint</name> + <value> + <type> + <kind>tk_string</kind> + </type> + <value> + <string>create_BasicSP_BMDeviceHome_Servant</string> + </value> + </value> + </execParameter> + <execParameter> + <name>edu.vanderbilt.dre.CIAO.ServantArtifact</name> + <value> + <type> + <kind>tk_string</kind> + </type> + <value> + <string>BMDevice_svnt</string> + </value> + </value> + </execParameter> + <execParameter> + <name>edu.vanderbilt.dre.CIAO.ExecutorArtifact</name> + <value> + <type> + <kind>tk_string</kind> + </type> + <value> + <string>BMDevice_exec</string> + </value> + </value> + </execParameter> + </implementation> + <implementation xmi:id="BMDisplayHomeImplementation"> + <name>BMDisplayHomeImplementation</name> + <source/> + <artifact xmi:idref="BMDisplay_ExecArtifact" /> + <artifact xmi:idref="BMDisplay_SvntArtifact" /> + <execParameter> + <!-- entrypoint as exec parameter (see 10.6.1) --> + <name>home factory</name> + <value> + <type> + <kind>tk_string</kind> + </type> + <value> + <string>create_BasicSP_BMDisplayHome_Impl</string> + </value> + </value> + </execParameter> + <execParameter> + <name>edu.vanderbilt.dre.CIAO.ServantEntrypoint</name> + <value> + <type> + <kind>tk_string</kind> + </type> + <value> + <string>create_BasicSP_BMDisplayHome_Servant</string> + </value> + </value> + </execParameter> + <execParameter> + <name>edu.vanderbilt.dre.CIAO.ServantArtifact</name> + <value> + <type> + <kind>tk_string</kind> + </type> + <value> + <string>BMDisplay_svnt</string> + </value> + </value> + </execParameter> + <execParameter> + <name>edu.vanderbilt.dre.CIAO.ExecutorArtifact</name> + <value> + <type> + <kind>tk_string</kind> + </type> + <value> + <string>BMDisplay_exec</string> + </value> + </value> + </execParameter> + </implementation> + <implementation xmi:id="ECComponentImplementation"> + <name>ECComponentImplementation</name> + <source/> + <artifact xmi:idref="EC_ExecArtifact" /> + <artifact xmi:idref="EC_SvntArtifact" /> + <artifact xmi:idref="EC_StubArtifact" /> + </implementation> + <implementation xmi:id="BMClosedEDComponentImplementation"> + <name>BMClosedEDComponentImplementation</name> + <source/> + <artifact xmi:idref="BMClosedED_ExecArtifact" /> + <artifact xmi:idref="BMClosedED_SvntArtifact" /> + <artifact xmi:idref="BMClosedED_StubArtifact" /> + </implementation> + <implementation xmi:id="BMDeviceComponentImplementation"> + <name>BMDeviceComponentImplementation</name> + <source/> + <artifact xmi:idref="BMDevice_ExecArtifact" /> + <artifact xmi:idref="BMDevice_SvntArtifact" /> + <artifact xmi:idref="BMDevice_StubArtifact" /> + </implementation> + <implementation xmi:id="BMDisplayComponentImplementation"> + <name>BMDisplayComponentImplementation</name> + <source/> + <artifact xmi:idref="BMDisplay_ExecArtifact" /> + <artifact xmi:idref="BMDisplay_SvntArtifact" /> + <artifact xmi:idref="BMDisplay_StubArtifact" /> + </implementation> + <instance xmi:id="ECHomeInstance"> + <name>ECHome</name> + <node>EC</node> + <!-- hostname --> + <source/> + <implementation xmi:idref="ECHomeImplementation" /> + </instance> + <instance xmi:id="BMClosedEDHomeInstance"> + <name>BMClosedEDHome</name> + <node>BMClosedED</node> + <!-- hostname --> + <source/> + <implementation xmi:idref="BMClosedEDHomeImplementation" /> + </instance> + <instance xmi:id="BMDeviceHomeInstance"> + <name>BMDeviceHome</name> + <node>BMDevice</node> + <!-- hostname --> + <source/> + <implementation xmi:idref="BMDeviceHomeImplementation" /> + </instance> + <instance xmi:id="BMDisplayHomeInstance"> + <name>BMDisplayHome</name> + <node>BMDisplay</node> + <!-- hostname --> + <source/> + <implementation xmi:idref="BMDisplayHomeImplementation" /> + </instance> + <instance xmi:id="ECComponentInstance"> + <name>ECComponent</name> + <node>EC</node> + <!-- hostname --> + <source/> + <implementation xmi:idref="ECComponentImplementation" /> + <configProperty> + <name>edu.vanderbilt.dre.DAnCE.ExplicitHome</name> + <value> + <type> + <kind>tk_string</kind> + </type> + <value> + <string>ECHome</string> + </value> + </value> + </configProperty> + <configProperty> + <name>edu.vanderbilt.dre.DAnCE.InstanceIOR</name> + <value> + <type> + <kind>tk_string</kind> + </type> + <value> + <string>rategen.ior</string> + </value> + </value> + </configProperty> + </instance> + <instance xmi:id="BMClosedEDComponentInstance"> + <name>BMClosedEDComponent</name> + <node>BMClosedED</node> + <!-- hostname --> + <source/> + <implementation xmi:idref="BMClosedEDComponentImplementation" /> + <configProperty> + <name>edu.vanderbilt.dre.DAnCE.ExplicitHome</name> + <value> + <type> + <kind>tk_string</kind> + </type> + <value> + <string>BMClosedEDHome</string> + </value> + </value> + </configProperty> + </instance> + <instance xmi:id="BMDeviceComponentInstance"> + <name>BMDeviceComponent</name> + <node>BMDevice</node> + <!-- hostname --> + <source/> + <implementation xmi:idref="BMDeviceComponentImplementation" /> + <configProperty> + <name>edu.vanderbilt.dre.DAnCE.ExplicitHome</name> + <value> + <type> + <kind>tk_string</kind> + </type> + <value> + <string>BMDeviceHome</string> + </value> + </value> + </configProperty> + </instance> + <instance xmi:id="BMDisplayComponentInstance"> + <name>BMDisplayComponent</name> + <node>BMDisplay</node> + <!-- hostname --> + <source/> + <implementation xmi:idref="BMDisplayComponentImplementation" /> + <configProperty> + <name>edu.vanderbilt.dre.DAnCE.ExplicitHome</name> + <value> + <type> + <kind>tk_string</kind> + </type> + <value> + <string>BMDisplayHome</string> + </value> + </value> + </configProperty> + </instance> + + <connection> + <name>datain_data_readBasicSP.ComponentImplementations.BasicSP.BasicSP.BMClosedEDBMDeviceComponentInstance</name> + <internalEndpoint> + <portName>datain</portName> + <provider>false</provider> + <kind>SimplexReceptacle</kind> + <instance xmi:idref="BMClosedEDComponentInstance" /> + </internalEndpoint> + <internalEndpoint> + <portName>data_read</portName> + <provider>true</provider> + <kind>Facet</kind> + <instance xmi:idref="BMDeviceComponentInstance" /> + </internalEndpoint> + </connection> + + <connection> + <name>comp_data_dataoutBMDisplayComponentInstanceBMDisplayComponentInstance</name> + <internalEndpoint> + <portName>comp_data</portName> + <provider>false</provider> + <kind>SimplexReceptacle</kind> + <instance xmi:idref="BMDisplayComponentInstance" /> + </internalEndpoint> + <internalEndpoint> + <portName>dataout</portName> + <provider>true</provider> + <kind>Facet</kind> + <instance xmi:idref="BMClosedEDComponentInstance" /> + </internalEndpoint> + </connection> + + <connection> + <name>timeout_timeoutECComponentInstanceBMDeviceComponentInstance</name> + <internalEndpoint> + <portName>timeout</portName> + <provider>false</provider> + <kind>EventPublisher</kind> + <instance xmi:idref="ECComponentInstance" /> + </internalEndpoint> + <internalEndpoint> + <portName>timeout</portName> + <provider>true</provider> + <kind>EventConsumer</kind> + <instance xmi:idref="BMDeviceComponentInstance" /> + </internalEndpoint> + </connection> + + <connection> + <name>data_available_in_availBMDeviceComponentInstanceBMDisplayComponentInstance</name> + <internalEndpoint> + <portName>data_available</portName> + <provider>false</provider> + <kind>EventPublisher</kind> + <instance xmi:idref="BMDeviceComponentInstance" /> + </internalEndpoint> + <internalEndpoint> + <portName>in_avail</portName> + <provider>true</provider> + <kind>EventConsumer</kind> + <instance xmi:idref="BMClosedEDComponentInstance" /> + </internalEndpoint> + </connection> + + <connection> + <name>out_avail_data_readyBMDisplayComponentInstanceBMDisplayComponentInstance</name> + <internalEndpoint> + <portName>out_avail</portName> + <provider>false</provider> + <kind>EventPublisher</kind> + <instance xmi:idref="BMClosedEDComponentInstance" /> + </internalEndpoint> + <internalEndpoint> + <portName>data_ready</portName> + <provider>true</provider> + <kind>EventConsumer</kind> + <instance xmi:idref="BMDisplayComponentInstance" /> + </internalEndpoint> + </connection> + + <artifact xmi:id="BMDisplay_ExecArtifact"> + <name>BMDisplay_exec</name> + <source/> + <node/> + <location>BMDisplay_exec</location> + </artifact> + <artifact xmi:id="BMDisplay_SvntArtifact"> + <name>BMDisplay_svnt</name> + <source/> + <node/> + <location>BMDisplay_svnt</location> + </artifact> + <artifact xmi:id="BMDisplay_StubArtifact"> + <name>BMDisplay_stub</name> + <source/> + <node/> + <location>BMDisplay_stub</location> + </artifact> + <artifact xmi:id="BMClosedED_ExecArtifact"> + <name>BMClosedED_exec</name> + <source/> + <node/> + <location>BMClosedED_exec</location> + </artifact> + <artifact xmi:id="BMClosedED_SvntArtifact"> + <name>BMClosedED_svnt</name> + <source/> + <node/> + <location>BMClosedED_svnt</location> + </artifact> + <artifact xmi:id="BMClosedED_StubArtifact"> + <name>BMClosedED_stub</name> + <source/> + <node/> + <location>BMClosedED_stub</location> + </artifact> + <artifact xmi:id="BMDevice_ExecArtifact"> + <name>BMDevice_exec</name> + <source/> + <node/> + <location>BMDevice_exec</location> + </artifact> + <artifact xmi:id="BMDevice_SvntArtifact"> + <name>BMDevice_svnt</name> + <source/> + <node/> + <location>BMDevice_svnt</location> + </artifact> + <artifact xmi:id="BMDevice_StubArtifact"> + <name>BMDevice_stub</name> + <source/> + <node/> + <location>BMDevice_stub</location> + </artifact> + <artifact xmi:id="EC_ExecArtifact"> + <name>EC_exec</name> + <source/> + <node/> + <location>EC_exec</location> + </artifact> + <artifact xmi:id="EC_SvntArtifact"> + <name>EC_svnt</name> + <source/> + <node/> + <location>EC_svnt</location> + </artifact> + <artifact xmi:id="EC_StubArtifact"> + <name>EC_stub</name> + <source/> + <node/> + <location>EC_stub</location> + </artifact> +</Deployment:DeploymentPlan>
\ No newline at end of file diff --git a/flat/CIAO/examples/BasicSP/descriptors/run_test.pl b/flat/CIAO/examples/BasicSP/descriptors/run_test.pl index 819f5a220ff..577f9d1432d 100755 --- a/flat/CIAO/examples/BasicSP/descriptors/run_test.pl +++ b/flat/CIAO/examples/BasicSP/descriptors/run_test.pl @@ -93,6 +93,11 @@ sub run_node_daemons { return 0; } +if ($#ARGV == 0) +{ + $cdp_file = $ARGV[0]; +} + delete_ior_files (); # Invoke naming service |