Skip to content
Permalink
Browse files

feat: add support for v1 (#15)

  • Loading branch information
busunkim96 committed Mar 6, 2020
1 parent bbc389e commit cc973912f40166c2574caad5a8266eddff6ae7a6
Showing with 5,682 additions and 3,740 deletions.
  1. +0 −1 .kokoro/build.sh
  2. +15 −0 .kokoro/publish-docs.sh
  3. +15 −0 .kokoro/release.sh
  4. +1 −1 CONTRIBUTING.rst
  5. +1 −1 docs/conf.py
  6. +6 −0 docs/gapic/v1/api.rst
  7. +5 −0 docs/gapic/v1/types.rst
  8. +11 −3 docs/index.rst
  9. +1 −1 google/__init__.py
  10. +1 −1 google/cloud/__init__.py
  11. +4 −4 google/cloud/secretmanager.py
  12. +43 −0 google/cloud/secretmanager_v1/__init__.py
  13. 0 google/cloud/secretmanager_v1/gapic/__init__.py
  14. +39 −0 google/cloud/secretmanager_v1/gapic/enums.py
  15. +1,435 −0 google/cloud/secretmanager_v1/gapic/secret_manager_service_client.py
  16. +98 −0 google/cloud/secretmanager_v1/gapic/secret_manager_service_client_config.py
  17. 0 google/cloud/secretmanager_v1/gapic/transports/__init__.py
  18. +330 −0 google/cloud/secretmanager_v1/gapic/transports/secret_manager_service_grpc_transport.py
  19. 0 google/cloud/secretmanager_v1/proto/__init__.py
  20. +779 −0 google/cloud/secretmanager_v1/proto/resources_pb2.py
  21. +17 −0 google/cloud/secretmanager_v1/proto/resources_pb2_grpc.py
  22. +1,546 −0 google/cloud/secretmanager_v1/proto/service_pb2.py
  23. +355 −0 google/cloud/secretmanager_v1/proto/service_pb2_grpc.py
  24. +59 −0 google/cloud/secretmanager_v1/types.py
  25. +12 −1 google/cloud/secretmanager_v1beta1/__init__.py
  26. +3 −3 google/cloud/secretmanager_v1beta1/gapic/enums.py
  27. +16 −16 google/cloud/secretmanager_v1beta1/gapic/secret_manager_service_client.py
  28. +6 −6 google/cloud/secretmanager_v1beta1/gapic/transports/secret_manager_service_grpc_transport.py
  29. +49 −47 google/cloud/secretmanager_v1beta1/proto/resources_pb2.py
  30. +87 −87 google/cloud/secretmanager_v1beta1/proto/service_pb2.py
  31. +1 −1 google/cloud/secretmanager_v1beta1/types.py
  32. +2 −1 noxfile.py
  33. +22 −3,542 synth.metadata
  34. +48 −23 synth.py
  35. +674 −0 tests/unit/gapic/v1/test_secret_manager_service_client_v1.py
  36. +1 −1 tests/unit/gapic/v1beta1/test_secret_manager_service_client_v1beta1.py
@@ -1,5 +1,4 @@
#!/bin/bash

# Copyright 2018 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
@@ -1,3 +1,18 @@
#!/bin/bash
# Copyright 2020 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

#!/bin/bash

set -eo pipefail
@@ -1,3 +1,18 @@
#!/bin/bash
# Copyright 2020 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

#!/bin/bash

set -eo pipefail
@@ -143,7 +143,7 @@ Running System Tests
- To run system tests, you can execute::

$ nox -s system-3.7
$ nox -s system-2.7
$ nox -s system-2.7

.. note::

@@ -20,7 +20,7 @@
# documentation root, use os.path.abspath to make it absolute, like shown here.
sys.path.insert(0, os.path.abspath(".."))

__version__ = "0.1.0"
__version__ = ""

# -- General configuration ------------------------------------------------

@@ -0,0 +1,6 @@
Client for Secret Manager API
=============================

.. automodule:: google.cloud.secretmanager_v1
:members:
:inherited-members:
@@ -0,0 +1,5 @@
Types for Secret Manager API Client
===================================

.. automodule:: google.cloud.secretmanager_v1.types
:members:
@@ -1,7 +1,15 @@
.. include:: README.rst

Api Reference
-------------
v1 Api Reference
----------------
.. toctree::
:maxdepth: 2

gapic/v1/api
gapic/v1/types

v1beta1 Api Reference
---------------------
.. toctree::
:maxdepth: 2

@@ -13,4 +21,4 @@ Changelog
.. toctree::
:maxdepth: 2

changelog
changelog
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
#
# Copyright 2019 Google LLC
# Copyright 2020 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
#
# Copyright 2019 Google LLC
# Copyright 2020 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
#
# Copyright 2019 Google LLC
# Copyright 2020 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
@@ -17,9 +17,9 @@

from __future__ import absolute_import

from google.cloud.secretmanager_v1beta1 import SecretManagerServiceClient
from google.cloud.secretmanager_v1beta1 import enums
from google.cloud.secretmanager_v1beta1 import types
from google.cloud.secretmanager_v1 import SecretManagerServiceClient
from google.cloud.secretmanager_v1 import enums
from google.cloud.secretmanager_v1 import types


__all__ = ("enums", "types", "SecretManagerServiceClient")
@@ -0,0 +1,43 @@
# -*- coding: utf-8 -*-
#
# Copyright 2020 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.


from __future__ import absolute_import
import sys
import warnings

from google.cloud.secretmanager_v1 import types
from google.cloud.secretmanager_v1.gapic import enums
from google.cloud.secretmanager_v1.gapic import secret_manager_service_client


if sys.version_info[:2] == (2, 7):
message = (
"A future version of this library will drop support for Python 2.7."
"More details about Python 2 support for Google Cloud Client Libraries"
"can be found at https://cloud.google.com/python/docs/python2-sunset/"
)
warnings.warn(message, DeprecationWarning)


class SecretManagerServiceClient(
secret_manager_service_client.SecretManagerServiceClient
):
__doc__ = secret_manager_service_client.SecretManagerServiceClient.__doc__
enums = enums


__all__ = ("enums", "types", "SecretManagerServiceClient")
No changes.
@@ -0,0 +1,39 @@
# -*- coding: utf-8 -*-
#
# Copyright 2020 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

"""Wrappers for protocol buffer enum types."""

import enum


class SecretVersion(object):
class State(enum.IntEnum):
"""
The state of a ``SecretVersion``, indicating if it can be accessed.
Attributes:
STATE_UNSPECIFIED (int): Not specified. This value is unused and invalid.
ENABLED (int): The ``SecretVersion`` may be accessed.
DISABLED (int): The ``SecretVersion`` may not be accessed, but the secret data is
still available and can be placed back into the ``ENABLED`` state.
DESTROYED (int): The ``SecretVersion`` is destroyed and the secret data is no longer
stored. A version may not leave this state once entered.
"""

STATE_UNSPECIFIED = 0
ENABLED = 1
DISABLED = 2
DESTROYED = 3

0 comments on commit cc97391

Please sign in to comment.
You can’t perform that action at this time.