Skip to content
Snippets Groups Projects
Commit 651e2ce8 authored by Lluis Gifre Renom's avatar Lluis Gifre Renom
Browse files

Compute:

- removed unneeded sleep method
parent 756da240
No related branches found
No related tags found
2 merge requests!54Release 2.0.0,!4Compute component:
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
# See the License for the specific language governing permissions and # See the License for the specific language governing permissions and
# limitations under the License. # limitations under the License.
import logging, random, time import logging
from typing import Dict, Optional, Union from typing import Dict, Optional, Union
from flask import request from flask import request
from flask.json import jsonify from flask.json import jsonify
...@@ -152,7 +152,6 @@ def process_list_site_network_access( ...@@ -152,7 +152,6 @@ def process_list_site_network_access(
msg = 'Something went wrong Updating VPN {:s}' msg = 'Something went wrong Updating VPN {:s}'
LOGGER.exception(msg.format(grpc_message_to_json_string(sna_request))) LOGGER.exception(msg.format(grpc_message_to_json_string(sna_request)))
errors.append({'error': str(e)}) errors.append({'error': str(e)})
time.sleep(random.random() / 10.0)
response = jsonify(errors) response = jsonify(errors)
response.status_code = HTTP_NOCONTENT if len(errors) == 0 else HTTP_SERVERERROR response.status_code = HTTP_NOCONTENT if len(errors) == 0 else HTTP_SERVERERROR
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment