(This message has been automatically imported from the retired mailing list)
forgive my bad english, i mean the authorization which server will recieve
the json
On Sun, Dec 7, 2014 at 5:54 PM, Dariusz Suchojad dsuch@zato.io wrote:
On 07/12/14 06:20, Rafed Ramzi wrote:
if i want to post to other services isn’t that mean i have to hard code
it manually?
I’m not sure what you mean by ‘it’ in ‘hard code it manually’?
–
Dariusz Suchojad
https://zato.io
ESB, SOA, REST, APIs and cloud integrations in Python
On 07/12/14 12:24, Rafed Ramzi wrote:
i mean the authorization which server will recieve the json
You can simply do it in a loop, like so:
targets = [‘B’, ‘C’, ‘D’]
for target in targets:
self.outgoing.plain_http.get(target).conn.get(self.cid, req)
The ‘targets’ list can be stored in a Redis set and that will let you
get the freshest set of targets without hardcoding them anywhere:
targets = self.kvdb.conn.smembers(‘my-targets’)
for target in targets:
self.outgoing.plain_http.get(target).conn.get(self.cid, req)
On 07/12/14 12:24, Rafed Ramzi wrote:
i mean the authorization which server will recieve the json
You can simply do it in a loop, like so:
targets = [‘B’, ‘C’, ‘D’]
for target in targets:
self.outgoing.plain_http.get(target).conn.get(self.cid, req)
The ‘targets’ list can be stored in a Redis set and that will let you
get the freshest set of targets without hardcoding them anywhere:
targets = self.kvdb.conn.smembers(‘my-targets’)
for target in targets:
self.outgoing.plain_http.get(target).conn.get(self.cid, req)