Hello to all,
Let's say i have to move some files (not known in advance) from one
known VirtualMachine host to another known VirtualMachine host and
then reverse, by the reverse action i dont know the VirtualMachine ip
that i'll post back the files as the Physical Machine that will host
it, is down for some time,thus the ip of the VM i want to send back
the files will change so as soon as the physical machine is up again,
Given this code:
MoveFiles extends Compound{
sfClass "....MoveFiles"
files [...] ; // <--Is there a way to define dynamically the
number and values of the files?? Obviously i should use the
sfResolve() method to insert the values i want, but i don't know if
smartfrog supports this kind of dynamically definition and action.
ActionMoveFiles extends Prim{
sfClass "...DotheMovement"
files LAZY PARENT:files??// <-- is this right?
because i do want to use them inside this component
fromIP "someKnownIP";
toIP "someKnownIP";
}
// TimePeriod where the physical machine goes down
ReverseActionMoveFiles extends Prim{
fromIP "someknownIP"
toIP "notKnownIP"; // here the "toIP" changes
but i dont know the value for some time...is there a way to stuck the
execution here as soon as the IP get its value?Should i do it inside
the sfPing() function by pinging the physical mahcine that will host
he VM ip??
sfClass "PingPhysicalMachine" //<-- A good tactic
would be to override sfPing by just making a plain pinging on the
physical host,but how often this will take action??
}
}
I do know the ordering of actions that's sfdeploy then sfStart and so
on every component, but what if i want to stuck on
reverseActionMoveFiles(at the sfPing() function of it) since i
eventually know the ip of the VirtualHost that i am going to transfer
the files by pinging the PhysicalHost let's say every 15 seconds as
you said the other time.
Then once the PhysicalHost is up, an API call would be enough to know
the ip of the New VirtualMachine...
Thanks,
Danos
----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.
------------------------------------------------------------------------------
Introducing Performance Central, a new site from SourceForge and
AppDynamics. Performance Central is your source for news, insights,
analysis and resources for efficient Application Performance Management.
Visit us today!
http://pubads.g.doubleclick.net/gampad/clk?id=48897511&iu=/4140/ostg.clktrk
_______________________________________________
Smartfrog-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/smartfrog-users