Hi.
I write a component (Foo) with two properties. One string (name="AString", initial value="/dev/foo"), one unsigned (name="AnUnsigned", initial value=42).
I use the deployer to load the component.
In the xml conf of the deployer i try to change the values of the properties (AString="/dev/bar", AnUnsigned=24).
Here is the log of deployer-gnulinux -s deployment.xml -l Debug Test
8<----------------------------------------------------------------------------------
1 ressac@compas:~/work/projects/foo$ deployer-gnulinux -s deployment.xml -l Debug Test 2 0.002 [ Debug ][ExecutionEngine] Creating ExecutionEngine for Test 3 0.003 [ Info ][Thread] Creating Thread for scheduler: 0 4 0.003 [ Debug ][Activity] Created Posix thread 3077544816 5 0.003 [ Info ][Activity] Thread created with scheduler type '0', priority 0 and period 0. 6 0.004 [ Info ][deployer-gnulinux::main()] No plugins present in /usr/lib/rtt/gnulinux/plugins 7 0.004 [ Info ][DeploymentComponent::loadComponents] Loading 'deployment.xml'. 8 0.005 [ Info ][DeploymentComponent::loadComponents] Validating new configuration... 9 0.005 [ Debug ][DeploymentComponent::import] Importing libFoo 10 0.005 [ Debug ][DeploymentComponent::loadLibrary] Call with libFoo 11 0.005 [ Debug ][DeploymentComponent::loadLibrary] Succesfully loaded Foo 12 0.005 [ Info ][DeploymentComponent::loadLibrary] Loaded multi component library 'libFoo.so' 13 0.005 [ Debug ][DeploymentComponent::loadLibrary] Components: Foo::ComponentFoo 14 0.005 [ Debug ][DeploymentComponent::loadLibrary] libFoo.so: undefined symbol: createComponent 15 0.005 [ Debug ][DeploymentComponent::loadLibrary] libFoo.so: undefined symbol: loadRTTPlugin 16 0.005 [ Info ][DeploymentComponent::loadLibrary] Storing Foo 17 0.006 [ Debug ][updateProperty] updateProperties: created Property bool AutoStart. 18 0.006 [ Debug ][updateProperty] Found Property 'Test': update done. 19 0.006 [ Debug ][DeploymentComponent::loadComponent] Found factory for Component type Foo::ComponentFoo 20 0.006 [ Debug ][ExecutionEngine] Creating ExecutionEngine for Foo 21 0.006 [ Info ][Thread] Creating Thread for scheduler: 0 22 0.006 [ Debug ][Activity] Created Posix thread 3069152112 23 0.006 [ Info ][Activity] Thread created with scheduler type '0', priority 0 and period 0. 24 0.007 [ Info ][DeploymentComponent::loadComponent] Adding Foo as new peer: OK. 25 0.007 [ Debug ][updateProperty] updateProperties: created Property bool AutoConf. 26 0.007 [ Debug ][updateProperty] updateProperties: created Property bool AutoConnect. 27 0.007 [ Debug ][updateProperty] updateProperties: created Property bool AutoStart. 28 0.007 [ Debug ][updateProperty] updateProperties: created Property PropertyBag Properties. 29 0.007 [ Debug ][updateProperty] updateProperties: created Property string AString. 30 0.007 [ Debug ][updateProperty] Found Property 'Foo': update done. 31 0.007 [ Debug ][DeploymentComponent::configureComponents] updateProperties: updating Property string AString. 32 0.007 [ Info ][DeploymentComponent::configureComponents] Configured Properties of Foo from main configuration file. 33 0.007 [ Debug ][virtual bool Foo::ComponentFoo::configureHook()] enter 34 0.007 [ Debug ][virtual bool Foo::ComponentFoo::configureHook()] exit 35 0.007 [ Info ][DeploymentComponent::configureComponents] Configuration successful. 36 0.007 [ Info ][DeploymentComponent::startComponents] Startup successful. 37 0.007 [ Info ][deployer-gnulinux::main()] Successfully loaded, configured and started components from deployment.xml 38 0.007 [ Debug ][ExecutionEngine] Creating ExecutionEngine for TaskBrowser 39 0.008 [ Info ][Thread] Creating Thread for scheduler: 0 40 0.008 [ Debug ][Activity] Created Posix thread 3060759408 41 0.008 [ Info ][Activity] Thread created with scheduler type '0', priority 0 and period 0. 42 Switched to : Test 43 0.008 [ Info ][deployer-gnulinux::main()] Entering Task Test 44 45 This console reader allows you to browse and manipulate TaskContexts. 46 You can type in a command, event, method, expression or change variables. 47 (type 'help' for instructions) 48 TAB completion and HISTORY is available ('bash' like) 49 50 In Task Test[S]. (Status of last Command : none ) 51 (type 'ls' for context info) :ls Foo 52 53 Listing TaskContext Foo : 54 55 Configuration Properties: 56 string AString = /dev/bar (A string) 57 uint AnUnsigned = 42 (An unsigned) 58 59 Execution Interface: 60 Attributes : (none) 61 Methods : activate cleanup configure error getErrorCount getPeriod getWarningCount inFatalError inRunTimeError inRunTimeWarning isActive isConfigured isRunning resetEr 62 Commands : (none) 63 Events : (none) 64 65 Data Flow Ports: (none) 66 67 Task Objects: 68 this ( The interface of this TaskContext. ) 69 scripting ( Access to the Scripting interface. Use this object in order to load or query programs or state machines. ) 70 engine ( Access to the Execution Engine. Use this object in order to address programs or state machines which may or may not be loaded. ) 71 marshalling ( Read and write Properties to a file. ) 72 73 Peers : (none) 74 75 In Task Test[S]. (Status of last Command : none ) 76 (type 'ls' for context info) :8<----------------------------------------------------------------------------------
At line 29 it create a property "string", but no "uint" (neither "int"). Moreover the AnUnsigned property don't change.
It works if i use long or short.
My question is : where i find the list of possible type for properties (in the code or the doc) ?
My opinion is that the type could be the same as those we put in the component class.
Regards.
Paul.
The deployer doesn't initialise unsigned properties.
Hi Paul,
On Fri, Nov 13, 2009 at 15:13, <paul [dot] chavent [..] ...> wrote:
> Hi.
>
> I write a component (Foo) with two properties. One string (name="AString",
> initial value="/dev/foo"), one unsigned (name="AnUnsigned", initial
> value=42).
>
> I use the deployer to load the component.
>
> In the xml conf of the deployer i try to change the values of the properties
> (AString="/dev/bar", AnUnsigned=24).
>
> Here is the log of deployer-gnulinux -s deployment.xml -l Debug Test
...
> At line 29 it create a property "string",
> but no "uint" (neither "int"). Moreover the AnUnsigned property don't
> change.
Try ushort or ulong. If you used Xerces as an XML parser, it would
validate your file and report that int/uint is illegal.
>
> It works if i use long or short.
>
> My question is : where i find the list of possible type for properties (in
> the code or the doc) ?
The official ones are listed in doc/cpf.dtd But you're right there's a
gap in the documentation about this.
>
>
> My opinion is that the type could be the same as those we put in the
> component class.
The problem we have here is that we attracted a 'standard' property
file format that follows the language independent types found in IDL.
It doesn't know int nor 64bit ints (long long)
I wouldn't mind if we extended our parsers to understand uint/int/long
long/unsigned long long or at least warned when non-valid XML is
found, but do in the end what the user wants us to do and
apply/respect the corba IDL mappings, which are more broad than what
the DTD allows.
It's easy to fix and it's a recurring user problem.
Peter
The deployer doesn't initialise unsigned properties.
Hi.
I write a component (Foo) with two properties. One string (name="AString", initial value="/dev/foo"), one unsigned (name="AnUnsigned", initial value=42).
I use the deployer to load the component.
In the xml conf of the deployer i try to change the values of the properties (AString="/dev/bar", AnUnsigned=24).
Here is the log of deployer-gnulinux -s deployment.xml -l Debug Test
8<----------------------------------------------------------------------------------
1 ressac@compas:~/work/projects/foo$ deployer-gnulinux -s deployment.xml -l Debug Test
2 0.002 [ Debug ][ExecutionEngine] Creating ExecutionEngine for Test
3 0.003 [ Info ][Thread] Creating Thread for scheduler: 0
4 0.003 [ Debug ][Activity] Created Posix thread 3077544816
5 0.003 [ Info ][Activity] Thread created with scheduler type '0', priority 0 and period 0.
6 0.004 [ Info ][deployer-gnulinux::main()] No plugins present in /usr/lib/rtt/gnulinux/plugins
7 0.004 [ Info ][DeploymentComponent::loadComponents] Loading 'deployment.xml'.
8 0.005 [ Info ][DeploymentComponent::loadComponents] Validating new configuration...
9 0.005 [ Debug ][DeploymentComponent::import] Importing libFoo
10 0.005 [ Debug ][DeploymentComponent::loadLibrary] Call with libFoo
11 0.005 [ Debug ][DeploymentComponent::loadLibrary] Succesfully loaded Foo
12 0.005 [ Info ][DeploymentComponent::loadLibrary] Loaded multi component library 'libFoo.so'
13 0.005 [ Debug ][DeploymentComponent::loadLibrary] Components: Foo::ComponentFoo
14 0.005 [ Debug ][DeploymentComponent::loadLibrary] libFoo.so: undefined symbol: createComponent
15 0.005 [ Debug ][DeploymentComponent::loadLibrary] libFoo.so: undefined symbol: loadRTTPlugin
16 0.005 [ Info ][DeploymentComponent::loadLibrary] Storing Foo
17 0.006 [ Debug ][updateProperty] updateProperties: created Property bool AutoStart.
18 0.006 [ Debug ][updateProperty] Found Property 'Test': update done.
19 0.006 [ Debug ][DeploymentComponent::loadComponent] Found factory for Component type Foo::ComponentFoo
20 0.006 [ Debug ][ExecutionEngine] Creating ExecutionEngine for Foo
21 0.006 [ Info ][Thread] Creating Thread for scheduler: 0
22 0.006 [ Debug ][Activity] Created Posix thread 3069152112
23 0.006 [ Info ][Activity] Thread created with scheduler type '0', priority 0 and period 0.
24 0.007 [ Info ][DeploymentComponent::loadComponent] Adding Foo as new peer: OK.
25 0.007 [ Debug ][updateProperty] updateProperties: created Property bool AutoConf.
26 0.007 [ Debug ][updateProperty] updateProperties: created Property bool AutoConnect.
27 0.007 [ Debug ][updateProperty] updateProperties: created Property bool AutoStart.
28 0.007 [ Debug ][updateProperty] updateProperties: created Property PropertyBag Properties.
29 0.007 [ Debug ][updateProperty] updateProperties: created Property string AString.
30 0.007 [ Debug ][updateProperty] Found Property 'Foo': update done.
31 0.007 [ Debug ][DeploymentComponent::configureComponents] updateProperties: updating Property string AString.
32 0.007 [ Info ][DeploymentComponent::configureComponents] Configured Properties of Foo from main configuration file.
33 0.007 [ Debug ][virtual bool Foo::ComponentFoo::configureHook()] enter
34 0.007 [ Debug ][virtual bool Foo::ComponentFoo::configureHook()] exit
35 0.007 [ Info ][DeploymentComponent::configureComponents] Configuration successful.
36 0.007 [ Info ][DeploymentComponent::startComponents] Startup successful.
37 0.007 [ Info ][deployer-gnulinux::main()] Successfully loaded, configured and started components from deployment.xml
38 0.007 [ Debug ][ExecutionEngine] Creating ExecutionEngine for TaskBrowser
39 0.008 [ Info ][Thread] Creating Thread for scheduler: 0
40 0.008 [ Debug ][Activity] Created Posix thread 3060759408
41 0.008 [ Info ][Activity] Thread created with scheduler type '0', priority 0 and period 0.
42 Switched to : Test
43 0.008 [ Info ][deployer-gnulinux::main()] Entering Task Test
44
45 This console reader allows you to browse and manipulate TaskContexts.
46 You can type in a command, event, method, expression or change variables.
47 (type 'help' for instructions)
48 TAB completion and HISTORY is available ('bash' like)
49
50 In Task Test[S]. (Status of last Command : none )
51 (type 'ls' for context info) :ls Foo
52
53 Listing TaskContext Foo :
54
55 Configuration Properties:
56 string AString = /dev/bar (A string)
57 uint AnUnsigned = 42 (An unsigned)
58
59 Execution Interface:
60 Attributes : (none)
61 Methods : activate cleanup configure error getErrorCount getPeriod getWarningCount inFatalError inRunTimeError inRunTimeWarning isActive isConfigured isRunning resetEr
62 Commands : (none)
63 Events : (none)
64
65 Data Flow Ports: (none)
66
67 Task Objects:
68 this ( The interface of this TaskContext. )
69 scripting ( Access to the Scripting interface. Use this object in order to load or query programs or state machines. )
70 engine ( Access to the Execution Engine. Use this object in order to address programs or state machines which may or may not be loaded. )
71 marshalling ( Read and write Properties to a file. )
72
73 Peers : (none)
74
75 In Task Test[S]. (Status of last Command : none )
76 (type 'ls' for context info) :
8<----------------------------------------------------------------------------------
At line 29 it create a property "string", but no "uint" (neither "int"). Moreover the AnUnsigned property don't change.
It works if i use long or short.
My question is : where i find the list of possible type for properties (in the code or the doc) ?
My opinion is that the type could be the same as those we put in the component class.
Regards.
Paul.