Hello community,

here is the log from the commit of package azure-cli-cosmosdb for 
openSUSE:Factory checked in at 2019-05-22 10:59:40
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/azure-cli-cosmosdb (Old)
 and      /work/SRC/openSUSE:Factory/.azure-cli-cosmosdb.new.5148 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "azure-cli-cosmosdb"

Wed May 22 10:59:40 2019 rev:5 rq:696829 version:0.2.7

Changes:
--------
--- /work/SRC/openSUSE:Factory/azure-cli-cosmosdb/azure-cli-cosmosdb.changes    
2018-10-15 10:45:04.063285923 +0200
+++ 
/work/SRC/openSUSE:Factory/.azure-cli-cosmosdb.new.5148/azure-cli-cosmosdb.changes
  2019-05-22 10:59:42.754791111 +0200
@@ -1,0 +2,16 @@
+Tue Apr 16 14:11:57 UTC 2019 - John Paul Adrian Glaubitz 
<adrian.glaub...@suse.com>
+
+- New upstream release
+  + Version 0.2.7
+  + For detailed information about changes see the
+    HISTORY.txt file provided with this package
+- Bump minimum version for Python Azure SDK namespace
+  packages to 3.0.0 in BuildRequires and Requires
+- Remove python3-devel package from BuildRequires
+- Remove unzip package from BuildRequires
+- Run fdupes to hardlink duplicate files
+  + Add fdupes to BuildRequires
+  + Add %fdupes invocation to %install
+- Update Requires from setup.py
+
+-------------------------------------------------------------------

Old:
----
  azure-cli-cosmosdb-0.2.1.tar.gz

New:
----
  azure-cli-cosmosdb-0.2.7.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ azure-cli-cosmosdb.spec ++++++
--- /var/tmp/diff_new_pack.PVpspp/_old  2019-05-22 10:59:43.490790158 +0200
+++ /var/tmp/diff_new_pack.PVpspp/_new  2019-05-22 10:59:43.490790158 +0200
@@ -1,7 +1,7 @@
 #
 # spec file for package azure-cli-cosmosdb
 #
-# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -17,7 +17,7 @@
 
 
 Name:           azure-cli-cosmosdb
-Version:        0.2.1
+Version:        0.2.7
 Release:        0
 Summary:        Microsoft Azure CLI 'cosmosdb' Command Module
 License:        MIT
@@ -27,15 +27,14 @@
 Source1:        LICENSE.txt
 BuildRequires:  azure-cli-command-modules-nspkg
 BuildRequires:  azure-cli-nspkg
-BuildRequires:  python3-azure-nspkg
-BuildRequires:  python3-devel
+BuildRequires:  fdupes
+BuildRequires:  python3-azure-nspkg >= 3.0.0
 BuildRequires:  python3-setuptools
-BuildRequires:  unzip
 Requires:       azure-cli-command-modules-nspkg
 Requires:       azure-cli-core
 Requires:       azure-cli-nspkg
-Requires:       python3-azure-mgmt-cosmosdb >= 0.4.0
-Requires:       python3-azure-nspkg
+Requires:       python3-azure-mgmt-cosmosdb >= 0.5.2
+Requires:       python3-azure-nspkg >= 3.0.0
 Requires:       python3-pydocumentdb >= 2.0.1
 Conflicts:      azure-cli < 2.0.0
 
@@ -56,6 +55,7 @@
 
 %install
 python3 setup.py install --root=%{buildroot} --prefix=%{_prefix} 
--install-lib=%{python3_sitelib}
+%python_expand %fdupes %{buildroot}%{$python_sitelib}
 rm -rf %{buildroot}%{python3_sitelib}/azure/cli/command_modules/__init__.*
 rm -rf %{buildroot}%{python3_sitelib}/azure/cli/command_modules/__pycache__
 rm -rf %{buildroot}%{python3_sitelib}/azure/cli/__init__.*

++++++ azure-cli-cosmosdb-0.2.1.tar.gz -> azure-cli-cosmosdb-0.2.7.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/azure-cli-cosmosdb-0.2.1/HISTORY.rst 
new/azure-cli-cosmosdb-0.2.7/HISTORY.rst
--- old/azure-cli-cosmosdb-0.2.1/HISTORY.rst    2018-08-23 01:07:57.000000000 
+0200
+++ new/azure-cli-cosmosdb-0.2.7/HISTORY.rst    2019-01-11 05:42:07.000000000 
+0100
@@ -3,6 +3,30 @@
 Release History
 ===============
 
+0.2.7
++++++
+* Added support for creating database with shared throughput
+
+0.2.6 
++++++ 
+* Added support for updating account from multi-master to single-master
+
+0.2.5
++++++
+* Use latest azure-mgmt-cosmosdb pypi package (0.5.2)
+
+0.2.4
++++++
+* Minor fixes.
+
+0.2.3
++++++
+* Minor fixes.
+
+0.2.2
++++++
+* `cosmosdb create`: Add `--enable-multiple-write-locations` support.
+
 0.2.1
 +++++
 * Minor fixes
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/azure-cli-cosmosdb-0.2.1/PKG-INFO 
new/azure-cli-cosmosdb-0.2.7/PKG-INFO
--- old/azure-cli-cosmosdb-0.2.1/PKG-INFO       2018-08-23 01:09:45.000000000 
+0200
+++ new/azure-cli-cosmosdb-0.2.7/PKG-INFO       2019-01-11 05:42:28.000000000 
+0100
@@ -1,6 +1,6 @@
 Metadata-Version: 1.1
 Name: azure-cli-cosmosdb
-Version: 0.2.1
+Version: 0.2.7
 Summary: Microsoft Azure Command-Line Tools Cosmos DB Command Module
 Home-page: https://github.com/Azure/azure-cli
 Author: Microsoft Corporation
@@ -20,6 +20,30 @@
         Release History
         ===============
         
+        0.2.7
+        +++++
+        * Added support for creating database with shared throughput
+        
+        0.2.6 
+        +++++ 
+        * Added support for updating account from multi-master to single-master
+        
+        0.2.5
+        +++++
+        * Use latest azure-mgmt-cosmosdb pypi package (0.5.2)
+        
+        0.2.4
+        +++++
+        * Minor fixes.
+        
+        0.2.3
+        +++++
+        * Minor fixes.
+        
+        0.2.2
+        +++++
+        * `cosmosdb create`: Add `--enable-multiple-write-locations` support.
+        
         0.2.1
         +++++
         * Minor fixes
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/azure-cli-cosmosdb-0.2.1/azure/cli/command_modules/cosmosdb/_client_factory.py
 
new/azure-cli-cosmosdb-0.2.7/azure/cli/command_modules/cosmosdb/_client_factory.py
--- 
old/azure-cli-cosmosdb-0.2.1/azure/cli/command_modules/cosmosdb/_client_factory.py
  2018-08-23 01:07:57.000000000 +0200
+++ 
new/azure-cli-cosmosdb-0.2.7/azure/cli/command_modules/cosmosdb/_client_factory.py
  2019-01-11 05:42:07.000000000 +0100
@@ -14,7 +14,7 @@
 logger = get_logger(__name__)
 
 
-NO_CREDENTIALS_ERROR_MESSAGE = """
+MISSING_CREDENTIALS_ERROR_MESSAGE = """
 No credentials specified to access Cosmos DB service. Please provide any of 
the following:
     (1) resource group name and account name
     (2) account name and key
@@ -54,8 +54,11 @@
             database_account = 
cf_cosmosdb(cli_ctx).database_accounts.get(resource_group, name)
             url_connection = database_account.document_endpoint
 
+        if name and not url_connection:
+            url_connection = 'https://{}.documents.azure.com:443'.format(name)
+
         if not key and not url_connection:
-            raise CLIError(NO_CREDENTIALS_ERROR_MESSAGE)
+            raise CLIError(MISSING_CREDENTIALS_ERROR_MESSAGE)
         auth = {'masterKey': key}
         client = document_client.DocumentClient(url_connection=url_connection, 
auth=auth)
     except Exception as ex:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/azure-cli-cosmosdb-0.2.1/azure/cli/command_modules/cosmosdb/_params.py 
new/azure-cli-cosmosdb-0.2.7/azure/cli/command_modules/cosmosdb/_params.py
--- old/azure-cli-cosmosdb-0.2.1/azure/cli/command_modules/cosmosdb/_params.py  
2018-08-23 01:07:57.000000000 +0200
+++ new/azure-cli-cosmosdb-0.2.7/azure/cli/command_modules/cosmosdb/_params.py  
2019-01-11 05:42:07.000000000 +0100
@@ -38,6 +38,7 @@
             c.argument('capabilities', nargs='+', 
validator=validate_capabilities, help='set custom capabilities on the Cosmos DB 
database account.')
             c.argument('enable_virtual_network', 
arg_type=get_three_state_flag(), help='Enables virtual network on the Cosmos DB 
database account')
             c.argument('virtual_network_rules', nargs='+', 
validator=validate_virtual_network_rules, help='ACL\'s for virtual network')
+            c.argument('enable_multiple_write_locations', 
arg_type=get_three_state_flag(), help="Enable Multiple Write Locations")
 
     with self.argument_context('cosmosdb regenerate-key') as c:
         c.argument('key_kind', arg_type=get_enum_type(KeyKind))
@@ -47,7 +48,10 @@
 
     with self.argument_context('cosmosdb collection') as c:
         c.argument('collection_id', options_list=['--collection-name', '-c'], 
help='Collection Name')
-        c.argument('throughput', type=int, help='Offer Throughput')
+        c.argument('throughput', type=int, help='Offer Throughput (RU/s)')
         c.argument('partition_key_path', help='Partition Key Path, e.g., 
\'/properties/name\'')
         c.argument('indexing_policy', type=shell_safe_json_parse, 
completer=FilesCompleter(), help='Indexing Policy, you can enter it as a string 
or as a file, e.g., --indexing-policy @policy-file.json)')
         c.argument('default_ttl', type=int, help='Default TTL')
+
+    with self.argument_context('cosmosdb database') as c:
+        c.argument('throughput', type=int, help='Offer Throughput (RU/s)')
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/azure-cli-cosmosdb-0.2.1/azure/cli/command_modules/cosmosdb/custom.py 
new/azure-cli-cosmosdb-0.2.7/azure/cli/command_modules/cosmosdb/custom.py
--- old/azure-cli-cosmosdb-0.2.1/azure/cli/command_modules/cosmosdb/custom.py   
2018-08-23 01:07:57.000000000 +0200
+++ new/azure-cli-cosmosdb-0.2.7/azure/cli/command_modules/cosmosdb/custom.py   
2019-01-11 05:42:07.000000000 +0100
@@ -51,7 +51,8 @@
                         enable_automatic_failover=None,
                         capabilities=None,
                         enable_virtual_network=None,
-                        virtual_network_rules=None):
+                        virtual_network_rules=None,
+                        enable_multiple_write_locations=None):
     """Create a new Azure Cosmos DB database account."""
     consistency_policy = None
     if default_consistency_level is not None:
@@ -78,7 +79,8 @@
         is_virtual_network_filter_enabled=enable_virtual_network,
         enable_automatic_failover=enable_automatic_failover,
         capabilities=capabilities,
-        virtual_network_rules=virtual_network_rules)
+        virtual_network_rules=virtual_network_rules,
+        enable_multiple_write_locations=enable_multiple_write_locations)
 
     async_docdb_create = client.create_or_update(resource_group_name, 
account_name, params)
     docdb_account = async_docdb_create.result()
@@ -86,6 +88,7 @@
     return docdb_account
 
 
+# pylint: disable=too-many-branches
 def cli_cosmosdb_update(client,
                         resource_group_name,
                         account_name,
@@ -98,7 +101,8 @@
                         enable_automatic_failover=None,
                         capabilities=None,
                         enable_virtual_network=None,
-                        virtual_network_rules=None):
+                        virtual_network_rules=None,
+                        enable_multiple_write_locations=None):
     """Update an existing Azure Cosmos DB database account. """
     existing = client.get(resource_group_name, account_name)
 
@@ -112,7 +116,8 @@
                 ip_range_filter is not None or \
                 enable_automatic_failover is not None or \
                 enable_virtual_network is not None or \
-                virtual_network_rules is not None:
+                virtual_network_rules is not None or \
+                enable_multiple_write_locations is not None:
             raise CLIError("Cannot set capabilities and update properties at 
the same time. {0}".format(locations))
 
         else:
@@ -131,7 +136,8 @@
                 ip_range_filter is None and \
                 enable_automatic_failover is None and \
                 enable_virtual_network is None and \
-                virtual_network_rules is None:
+                virtual_network_rules is None and \
+                enable_multiple_write_locations is None:
             async_docdb_create = client.patch(resource_group_name, 
account_name, tags=tags, capabilities=capabilities)
             docdb_account = async_docdb_create.result()
             docdb_account = client.get(resource_group_name, account_name)
@@ -180,6 +186,14 @@
     if tags is None:
         tags = existing.tags
 
+    if enable_multiple_write_locations is None:
+        enable_multiple_write_locations = 
existing.enable_multiple_write_locations
+    elif enable_multiple_write_locations != 
existing.enable_multiple_write_locations and \
+            enable_multiple_write_locations:
+        raise CLIError("Cannot convert account from single master to multi 
master")
+    elif enable_multiple_write_locations != 
existing.enable_multiple_write_locations:
+        logger.warning("Updating the account from multi master to single 
master will take 24 hours to complete.")
+
     params = DatabaseAccountCreateUpdateParameters(
         location=existing.location,
         locations=locations,
@@ -190,7 +204,8 @@
         enable_automatic_failover=enable_automatic_failover,
         capabilities=existing.capabilities,
         is_virtual_network_filter_enabled=enable_virtual_network,
-        virtual_network_rules=virtual_network_rules)
+        virtual_network_rules=virtual_network_rules,
+        enable_multiple_write_locations=enable_multiple_write_locations)
 
     async_docdb_create = client.create_or_update(resource_group_name, 
account_name, params)
     docdb_account = async_docdb_create.result()
@@ -241,9 +256,9 @@
     return list(client.ReadDatabases())
 
 
-def cli_cosmosdb_database_create(client, database_id):
+def cli_cosmosdb_database_create(client, database_id, throughput=None):
     """Creates an Azure Cosmos DB database """
-    return client.CreateDatabase({'id': database_id})
+    return client.CreateDatabase({'id': database_id}, {'offerThroughput': 
throughput})
 
 
 def cli_cosmosdb_database_delete(client, database_id):
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/azure-cli-cosmosdb-0.2.1/azure_cli_cosmosdb.egg-info/PKG-INFO 
new/azure-cli-cosmosdb-0.2.7/azure_cli_cosmosdb.egg-info/PKG-INFO
--- old/azure-cli-cosmosdb-0.2.1/azure_cli_cosmosdb.egg-info/PKG-INFO   
2018-08-23 01:09:45.000000000 +0200
+++ new/azure-cli-cosmosdb-0.2.7/azure_cli_cosmosdb.egg-info/PKG-INFO   
2019-01-11 05:42:28.000000000 +0100
@@ -1,6 +1,6 @@
 Metadata-Version: 1.1
 Name: azure-cli-cosmosdb
-Version: 0.2.1
+Version: 0.2.7
 Summary: Microsoft Azure Command-Line Tools Cosmos DB Command Module
 Home-page: https://github.com/Azure/azure-cli
 Author: Microsoft Corporation
@@ -20,6 +20,30 @@
         Release History
         ===============
         
+        0.2.7
+        +++++
+        * Added support for creating database with shared throughput
+        
+        0.2.6 
+        +++++ 
+        * Added support for updating account from multi-master to single-master
+        
+        0.2.5
+        +++++
+        * Use latest azure-mgmt-cosmosdb pypi package (0.5.2)
+        
+        0.2.4
+        +++++
+        * Minor fixes.
+        
+        0.2.3
+        +++++
+        * Minor fixes.
+        
+        0.2.2
+        +++++
+        * `cosmosdb create`: Add `--enable-multiple-write-locations` support.
+        
         0.2.1
         +++++
         * Minor fixes
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/azure-cli-cosmosdb-0.2.1/azure_cli_cosmosdb.egg-info/requires.txt 
new/azure-cli-cosmosdb-0.2.7/azure_cli_cosmosdb.egg-info/requires.txt
--- old/azure-cli-cosmosdb-0.2.1/azure_cli_cosmosdb.egg-info/requires.txt       
2018-08-23 01:09:45.000000000 +0200
+++ new/azure-cli-cosmosdb-0.2.7/azure_cli_cosmosdb.egg-info/requires.txt       
2019-01-11 05:42:28.000000000 +0100
@@ -1,3 +1,3 @@
-azure-mgmt-cosmosdb==0.4.0
+azure-mgmt-cosmosdb==0.5.2
 azure-cli-core
 pydocumentdb>=2.0.1
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/azure-cli-cosmosdb-0.2.1/setup.py 
new/azure-cli-cosmosdb-0.2.7/setup.py
--- old/azure-cli-cosmosdb-0.2.1/setup.py       2018-08-23 01:07:57.000000000 
+0200
+++ new/azure-cli-cosmosdb-0.2.7/setup.py       2019-01-11 05:42:07.000000000 
+0100
@@ -16,7 +16,7 @@
     cmdclass = {}
 
 
-VERSION = "0.2.1"
+VERSION = "0.2.7"
 # The full list of classifiers is available at
 # https://pypi.python.org/pypi?%3Aaction=list_classifiers
 CLASSIFIERS = [
@@ -34,7 +34,7 @@
 
 DEPENDENCIES = [
 
-    'azure-mgmt-cosmosdb==0.4.0',
+    'azure-mgmt-cosmosdb==0.5.2',
     'azure-cli-core',
     'pydocumentdb>=2.0.1'
 ]


Reply via email to