tags:

views:

130

answers:

1

I'm trying to get a better understanding of how endpoints work. I've read this and have learned that the services.config is "baked" into the swf at compile time. In that article he references the tokens...

<endpoint uri="http://myServer:{server.port}{context.root}/flex2gateway/" class="flex.messaging.endpoints.AMFEndpoint"/>

... where server.port, and context.root are the tokens. I guess what I'm wondering is what tokens are available to me, and if they act like variables can I set my own custom token?

Edit: We're moving to another development server soon. We have 2 main flex developers and when they check out projects from the repository we want their projects work work independently of each other... so I want to make sure the endpoint will get set correctly for each developers project location.

A: 

I would have though that, when compiled, the tokens would be hard coded into the app... this apparently is not the case, so using {server.name} worked for us.

Chris Klepeis
While context.root gets compiled into the app, server.name and server.port are JVM properties and do not get resolved until the server starts up.
HDave