new features and bug fixes to DeploymentComponent

Hi everybody.

I have made several improvements (well, I guess they are) to DeploymentComponent. I am looking forward for the feedback of the community.
I removed a couple of bugs and made changes aiming to improved the Deployment Component.

First I tell you the philosophy of the changes:

1) You want to load and unload components easily and several times. For example, you have a producer and 2 consumers. You may want to stop both the consumers but NOT the producer.
2) Very ofter you do testing and you notice a bug; you correct it and you upload the new file on the robot to test again. In our example, you want to:
- kickOut one of the two consumers (consumer_A),
- overwrite the dynamic library (consumer_A.so),
- reload the library and the consumer
- start the comsumer_A again.
- of course you want to do this WITHOUT shutting down the producer and/or consumer_B.

So, summarizing, these are the main changes I have made:

A) some more functions to kickOut a single component or the components that were launched by an XML file.
B) bug correction: you have to check that there aren't duplicated items in the vector ConnectionData, otherwise you will get a false in configureComponents and you will not be able to startComponents.
C) it is much better to remove the element of the map "comps" in the function unloadComponentImpl(cit) (written by Peter), otherwise it is a mess!
D) BIG CHANGE: You can reload dynamic libraries in run-time. If you are asked to import a dynamic library that was already loaded you can close and reopen such library (in this way you can apply a change in case you have overwritten the file.so), but ONLY if there isn't any instance allocated whom Component Type was loaded from this file (actually, I don't know what would happen otherwise, but it sounds safer). For this reason I need to have changed the vector LoadedLibs and I store the type of a component in ComponentData.
E) in configureComponents() if you try to configure a peer that is already configures and works correctly, just give a warning, but don't force to return a false.

let me know what you think about the changes.

new features and bug fixes to DeploymentComponent

At 15:34 4/11/2008, faconti [..] ... wrote:
>Hi everybody.
>
>I have made several improvements (well, I guess they are) to
>DeploymentComponent. I am looking forward for the feedback of the community.
>I removed a couple of bugs and made changes aiming to improved the
>Deployment Component.
>
>First I tell you the philosophy of the changes:
>
>1) You want to load and unload components easily and several times.
>For example, you have a producer and 2 consumers. You may want to
>stop both the consumers but NOT the producer.
>2) Very ofter you do testing and you notice a bug; you correct it
>and you upload the new file on the robot to test again. In our
>example, you want to:
>- kickOut one of the two consumers (consumer_A),
>- overwrite the dynamic library (consumer_A.so),
>- reload the library and the consumer
>- start the comsumer_A again.
>- of course you want to do this WITHOUT shutting down the producer
>and/or consumer_B.
>
>So, summarizing, these are the main changes I have made:
>
>A) some more functions to kickOut a single component or the
>components that were launched by an XML file.
>B) bug correction: you have to check that there aren't duplicated
>items in the vector ConnectionData, otherwise you will get a false
>in configureComponents and you will not be able to startComponents.
>C) it is much better to remove the element of the map "comps" in the
>function unloadComponentImpl(cit) (written by Peter), otherwise it is a mess!

So do your patches require my patch ?

>D) BIG CHANGE: You can reload dynamic libraries in run-time. If you
>are asked to import a dynamic library that was already loaded you
>can close and reopen such library (in this way you can apply a
>change in case you have overwritten the file.so), but ONLY if there
>isn't any instance allocated whom Component Type was loaded from
>this file (actually, I don't know what would happen otherwise, but
>it sounds safer). For this reason I need to have changed the vector
>LoadedLibs and I store the type of a component in ComponentData.

Cool!

>E) in configureComponents() if you try to configure a peer that is
>already configures and works correctly, just give a warning, but
>don't force to return a false.

As I mailed before, this is ok for me, the current implementation
is/was way to strict.

>let me know what you think about the changes.

Thanks for contributing, I believe your patches made a big usability
improvement for rapid testing.

Peter

new features and bug fixes to DeploymentComponent

[...]
>> let me know what you think about the changes.
>
> Thanks for contributing, I believe your patches made a big usability
> improvement for rapid testing.
>
Thanks from my side too! :-) This functionality is not just good for rapid
testing, but also for updating running systems that should not be rebooted!

One question: how platform-independent are the patches...?

Herman

new features and bug fixes to DeploymentComponent


On Sat, Nov 15, 2008 at 7:10 PM, Herman Bruyninckx <Herman [dot] Bruyninckx [..] ...> wrote:



[...]


let me know what you think about the changes.



Thanks for contributing, I believe your patches made a big usability

improvement for rapid testing.


Thanks from my side too! :-) This functionality is not just good for rapid

testing, but also for updating running systems that should not be rebooted!



One question: how platform-independent are the patches...?



Herman



Herman,

honestly I can't tell you. I will do more testing to check it out.