Skip to content

Commit

Permalink
Added CosmosDB warning: Use CosmosDbPartitionedStorage instead. (#2104)
Browse files Browse the repository at this point in the history
* Added CosmosDB warning

* CosmosDBStorage black

---------

Co-authored-by: Tracy Boehrer <trboehre@microsoft.com>
  • Loading branch information
tracyboehrer and Tracy Boehrer committed Apr 30, 2024
1 parent 10e4332 commit 74ec755
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
from typing import Dict, List
from threading import Semaphore
import json
import warnings
from jsonpickle.pickler import Pickler
from jsonpickle.unpickler import Unpickler
import azure.cosmos.cosmos_client as cosmos_client # pylint: disable=no-name-in-module,import-error
Expand Down Expand Up @@ -107,6 +108,9 @@ def __init__(
:param config:
"""
super(CosmosDbStorage, self).__init__()
warnings.warn(
"CosmosDbStorage is obsolete. Use CosmosDbPartitionedStorage instead."
)
self.config = config
self.client = client or cosmos_client.CosmosClient(
self.config.endpoint, {"masterKey": self.config.masterkey}
Expand Down

0 comments on commit 74ec755

Please sign in to comment.