Thanks for your quick response.
Let me inform you what i need to do.
Firstly, i want to define an attribute called IP inside my main .sf file.
very ip i want to know on run time.
sequence ... {
of value is a problem to me.
The 3rd and 4th solutions are sounding very attractive to me.
components(for example the second one) can obtain it.
Post by Goldsack, PatrickDanos,
TBD won't work - that will throw an error when you parse as TBD
means that this has to be replaced in the usage (by extension).
At what point to you know the value of the IP address? I assume that
you do not know it at time of creating the specification since
otherwise you would include it.
1) If you know it when you start the daemon (for example the IP
address of the local host), you could pass it as a java property and
set the "ip" attribute to a "PROPERTY" value (see the documentation
for details). This can be done in a start-up script on the command
line that starts the daemon, in a properties file (I forget the
name, but it is in the documentation), or programmatically by
setting the java property in the code before processing the .sf file.
You can do the same with environmental variables using ENVPROPERTY
2) If you know it at the time you parse the .sf file, you could set
it in you code after the parse, and before the resolution phases.
This is not possible if you are simply using the standard start
script which do not have the opportunity to interject code in
between the parse and phase resolutions.
3) One of the components that gets started as part of the deployment
posts the value it obtains to the ip attribute, and all other
components obtain it by derefencing attributes that are LAZY links
to that posted attribute.
4) write yourself a smartfrog function that obtains the IP address
in whatever way required, and make the attribute a function invocation
If none of these help, give more details of exactly what you need to
do and I will come up with some other options!
Patrick
-----Original Message-----
Sent: 13 August 2013 12:00
Subject: [Smartfrog-users] TBD_ip_address
Hello to all,
Is there a way to define an IP on runtime?
I though the usage of defining an attribute like ip TBA; But how am
i going to resolve it then?
thanks,
danos
----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.
------------------------------------------------------------------------------
Get 100% visibility into Java/.NET code with AppDynamics Lite!
It's a free troubleshooting tool designed for production.
Get down to code-level detail for bottlenecks, with <2% overhead.
Download for free and get started troubleshooting in minutes.
http://pubads.g.doubleclick.net/gampad/clk?id=48897031&iu=/4140/ostg.clktrk
_______________________________________________
Smartfrog-users mailing list
https://lists.sourceforge.net/lists/listinfo/smartfrog-users