Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions testsuites/CBLTester/upgrade_tests/test_cbl_upgrade.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@ def test_upgrade_cbl(params_from_base_suite_setup):
connection_url = "couchbases://{}?ssl=no_verify".format(cbs_ip)
else:
connection_url = "couchbase://{}".format(cbs_ip)
print("\ncluster url: ", connection_url)
sdk_client = get_cluster(connection_url, cbs_bucket)
log_info("Creating primary index for {}".format(cbs_bucket))
n1ql_query = "create primary index index1 on `{}`".format(cbs_bucket)
Expand Down
13 changes: 10 additions & 3 deletions utilities/cluster_config_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,16 @@ def write(self, fp):
def get_cluster(url, bucket_name):
timeout_options = ClusterTimeoutOptions(kv_timeout=timedelta(seconds=180), query_timeout=timedelta(seconds=300),
config_total_timeout=timedelta(seconds=600))
options = ClusterOptions(PasswordAuthenticator("Administrator", "password"), timeout_options=timeout_options)
cluster = Cluster(url, options)
cluster = cluster.bucket(bucket_name)
try:
options = ClusterOptions(PasswordAuthenticator("Administrator", "password"), timeout_options=timeout_options)
cluster = Cluster(url, options)
cluster = cluster.bucket(bucket_name)
except Exception as e:
if e:
print("\nHere is error: ", str(e))
print("\nbucket name: ", bucket_name)
print("\nurl: ", url)
print("\noptions: ", options)
return cluster.default_collection()


Expand Down