Commit 2c25811f by nadeemshahzad

added retries to ec2.py

parent 62a6a06b
...@@ -118,6 +118,7 @@ from boto import ec2 ...@@ -118,6 +118,7 @@ from boto import ec2
from boto import rds from boto import rds
from boto import route53 from boto import route53
import ConfigParser import ConfigParser
import traceback
try: try:
import json import json
...@@ -612,5 +613,11 @@ class Ec2Inventory(object): ...@@ -612,5 +613,11 @@ class Ec2Inventory(object):
# Run the script # Run the script
Ec2Inventory() RETRIES = 3
for _ in xrange(RETRIES):
try:
Ec2Inventory()
break
except Exception:
traceback.print_exc()
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment