aboutsummaryrefslogtreecommitdiffstats
path: root/moonv4/moon_utilities
diff options
context:
space:
mode:
authorasteroide <thomas.duval@orange.com>2017-06-12 18:58:36 +0200
committerasteroide <thomas.duval@orange.com>2017-06-12 18:58:36 +0200
commitbcdb69dff50307d4be869b1af78b830d012e298c (patch)
tree6014823691d88fd2c0fa77d058662fc0fdff330a /moonv4/moon_utilities
parent7103ad80b6a1a25d9542c644f8e584194d489a11 (diff)
Update default method in call
Change-Id: I608e7728285a6fe48b1837bbabc6317ccf405404
Diffstat (limited to 'moonv4/moon_utilities')
-rw-r--r--moonv4/moon_utilities/moon_utilities/security_functions.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/moonv4/moon_utilities/moon_utilities/security_functions.py b/moonv4/moon_utilities/moon_utilities/security_functions.py
index c8ae094b..57baeebb 100644
--- a/moonv4/moon_utilities/moon_utilities/security_functions.py
+++ b/moonv4/moon_utilities/moon_utilities/security_functions.py
@@ -176,7 +176,7 @@ def notify(request_id, container_id, payload, event_type="authz"):
__n_notifier.critical(ctxt, event_type, payload=payload)
-def call(endpoint, ctx=None, method="get_status", **kwargs):
+def call(endpoint, ctx=None, method="route", **kwargs):
if not ctx:
ctx = dict()
if endpoint not in __targets:
@@ -193,7 +193,9 @@ def call(endpoint, ctx=None, method="get_status", **kwargs):
else:
client = __targets[endpoint]["client"]["internal"]
LOG.info("Calling {} on {}...".format(method, endpoint))
- return client.call(ctx, method, **kwargs)
+ result = copy.deepcopy(client.call(ctx, method, **kwargs))
+ del client
+ return result
class Context: