Skip to content

Commit 282219d

Browse files
authored
Merge pull request #33 from oracle/release_2017-10-12
Releasing version 1.3.8
2 parents 795f7ab + c469172 commit 282219d

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

63 files changed

+5018
-233
lines changed

CHANGELOG.rst

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,27 @@ All notable changes to this project will be documented in this file.
44

55
The format is based on `Keep a Changelog <http://keepachangelog.com/>`_.
66

7+
====================
8+
1.3.8 - 2017-10-12
9+
====================
10+
11+
Deprecated
12+
----------
13+
* Creating block volumes and specifying the size in MBs is deprecated. Instead, the new size_in_gbs field should be used to specify the volume size in GBs.
14+
15+
Added
16+
-----
17+
* Support for creating block volumes and specifying the size in GBs.
18+
* Support in UploadManager for handling piped input.
19+
* Support for adding and updating display names for captured instance serial console data.
20+
* Support for VNIC source/destination checks.
21+
* Support for new Database service features: VM DBs, Bring Your Own License, and Data Guard.
22+
* Support for the FRA (eu-frankfurt-1) region.
23+
24+
Changed
25+
-------
26+
* The size of block volumes and volume backups is specified in GBs as well as MBs.
27+
728
====================
829
1.3.7 - 2017-09-11
930
====================

README.rst

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,28 @@ If you wish to run an individual test then you can run:
8686
8787
py.test -s tests/integ/test_launch_instance_tutorial.py
8888
89+
Specifying a config file
90+
------------------------
91+
92+
By default, the tests will look for a config file at 'tests/resources/config'
93+
and use the ``DEFAULT`` profile. You can change this with the ``--config-file``
94+
and ``--config-profile`` options.
95+
96+
.. code-block:: sh
97+
98+
# Use a different config file, still using the DEFAULT profile
99+
tox -- --config-file ~/.oci/config
100+
101+
# Using a different profile in the default config file
102+
tox -- --config-profile IAD_PROFILE
103+
104+
Specifying environment variables
105+
--------------------------------
106+
In addition to a valid config file for your tenancy, the tests also require the following environment
107+
variables to be set:
108+
109+
* ``OCI_PYSDK_PUBLIC_SSH_KEY_FILE``: path to a public SSH key (.pub file) that will be given access to the instance launched in ``test_launch_instance_tutorial.py``.
110+
89111
Generating Documentation
90112
========================
91113
Sphinx is used for documentation. You can generate HTML locally with the following:

docs/api/index.rst

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,26 @@ Virtual Network
4949
:undoc-members:
5050
:imported-members:
5151

52+
==========
53+
Database
54+
==========
55+
56+
--------
57+
Client
58+
--------
59+
60+
.. autoclass:: oci.database.database_client.DatabaseClient
61+
:members:
62+
63+
--------
64+
Models
65+
--------
66+
67+
.. automodule:: oci.database.models
68+
:members:
69+
:undoc-members:
70+
:imported-members:
71+
5272
==========
5373
Identity
5474
==========

docs/backward-compatibility.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,4 +13,4 @@ Backward Compatibility
1313
~~~~~~~~~~~~~~~~~~~~~~
1414
The top level namespace / package name for the Python SDK has been changed from ``oraclebmc`` to ``oci``, so all of the documentation now references ``oci``. If you are using the ``oraclebmc`` package you should continue to reference ``oraclebmc`` in your code and when interpreting the documentation you should replace ``oci`` with ``oraclebmc`` (i.e. if there is a class defined in the docs as ``oci.base_client.BaseClient`` in the oraclebmc package this class will be called ``oraclebmc.base_client.BaseClient``).
1515

16-
**Note**: The ``oraclebmc`` package is deprecated and will be removed in March 2018. Please upgrade to the ``oci`` package to avoid interruption at that time.
16+
**Note**: The ``oraclebmc`` package is deprecated and will no longer be maintained starting March 2018. Please upgrade to the ``oci`` package to avoid interruption at that time.

docs/deprecation-notice.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,6 @@ Deprecation Notice
44
~~~~~~~~~~~~~~~~~~
55

66
.. warning::
7-
This domain is deprecated and will be removed in March 2018.
7+
This domain is deprecated and will no longer be maintained starting March 2018.
88

99
Please access the documentation through our new location `here <https://oracle-cloud-infrastructure-python-sdk.readthedocs.io/>`_.

docs/index.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ This is the public Python SDK for Oracle Cloud Infrastructure. Python 2.7+ and
3636
To get started, head over to the :ref:`installation instructions <install>` or see more examples in the
3737
:ref:`quickstart <quickstart>` section.
3838

39-
**Note**: The ``oraclebmc`` package is deprecated and will be removed in March 2018. Please check the :ref:`Backward Compatibility <backward-compatibility>` section if you are using ``oraclebmc``.
39+
**Note**: The ``oraclebmc`` package is deprecated and will no longer be maintained starting March 2018. Please check the :ref:`Backward Compatibility <backward-compatibility>` section if you are using ``oraclebmc``.
4040

4141
.. toctree::
4242
:hidden:

docs/installation.rst

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,14 +23,17 @@ The Python SDK supports operations for the following services:
2323
Prerequisites
2424
===============
2525

26+
.. note::
27+
The Python SDK uses the `cryptography.io`_ library, which has its own additional `build requirements`_. Ensure
28+
that you satisfy those requirements prior to installing the Python SDK.
29+
2630
* An Oracle Cloud Infrastructure account
2731
* A user created in that account, in a group with a policy that grants the desired permissions.
2832
This can be a user for yourself, or another person/system that needs to call the API.
2933
For an example of how to set up a new user, group, compartment, and policy, see
3034
`Adding Users`_ in the Getting Started Guide. For a list of other typical
3135
Oracle Cloud Infrastructure policies, see `Common Policies`_ in the User Guide.
3236
* Python version 2.7.5 or 3.5 or later, running on Mac, Windows, or Linux.
33-
* The Python SDK uses the `cryptography.io`_ library, which has its own additional `build requirements`_.
3437
* A keypair used for signing API requests, with the public key uploaded to Oracle. Only the user calling
3538
the API should be in possession of the private key. (For more information, see `Configuring the SDK`_.)
3639

requirements.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ coverage==4.2
44
cryptography==1.8.2
55
flake8==3.0.4
66
httpsig_cffi==15.0.0
7+
mock==2.0.0
78
pytest==3.0.2
89
pytest-catchlog==1.2.2
910
python-dateutil==2.5.3

src/oci/core/blockstorage_client.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ def create_volume(self, create_volume_details, **kwargs):
3030
"""
3131
CreateVolume
3232
Creates a new volume in the specified compartment. Volumes can be created in sizes ranging from
33-
50 GB (51200 MB) to 2 TB (2097152 MB), in 1 GB (1024 MB) increments. By default, volumes are 1 TB (1048576 MB).
33+
50 GB (51200 MB) to 16 TB (16777216 MB), in 1 GB (1024 MB) increments. By default, volumes are 1 TB (1048576 MB).
3434
For general information about block volumes, see
3535
`Overview of Block Volume Service`__.
3636

src/oci/core/compute_client.py

Lines changed: 76 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -256,7 +256,15 @@ def create_image(self, create_image_details, **kwargs):
256256
def create_instance_console_connection(self, create_instance_console_connection_details, **kwargs):
257257
"""
258258
CreateInstanceConsoleConnection
259-
Create a console connection for an instance.
259+
Creates a new serial console connection to the specified instance.
260+
Once the serial console connection has been created and is available,
261+
you connect to the serial console using an SSH client.
262+
263+
The default number of enabled serial console connections per tenancy is 10.
264+
265+
For more information about serial console access, see `Accessing the Serial Console`__.
266+
267+
__ https://docs.us-phoenix-1.oraclecloud.com/Content/Compute/References/serialconsole.htm
260268
261269
262270
:param CreateInstanceConsoleConnectionDetails create_instance_console_connection_details: (required)
@@ -395,7 +403,7 @@ def delete_image(self, image_id, **kwargs):
395403
def delete_instance_console_connection(self, instance_console_connection_id, **kwargs):
396404
"""
397405
DeleteInstanceConsoleConnection
398-
Delete the console connection for an instance
406+
Deletes the specified serial console connection.
399407
400408
401409
:param str instance_console_connection_id: (required)
@@ -447,6 +455,14 @@ def detach_vnic(self, vnic_attachment_id, **kwargs):
447455
When you terminate an instance, all attached VNICs (primary
448456
and secondary) are automatically detached and deleted.
449457
458+
**Important:** If the VNIC has a
459+
:class:`PrivateIp` that is the
460+
`target of a route rule`__,
461+
deleting the VNIC causes that route rule to blackhole and the traffic
462+
will be dropped.
463+
464+
__ https://docs.us-phoenix-1.oraclecloud.com/Content/Network/Tasks/managingroutetables.htm#privateip
465+
450466
451467
:param str vnic_attachment_id: (required)
452468
The OCID of the VNIC attachment.
@@ -784,7 +800,7 @@ def get_instance(self, instance_id, **kwargs):
784800
def get_instance_console_connection(self, instance_console_connection_id, **kwargs):
785801
"""
786802
GetInstanceConsoleConnection
787-
Get the details of an instance console connection
803+
Gets the specified serial console connection's information.
788804
789805
790806
:param str instance_console_connection_id: (required)
@@ -1230,7 +1246,11 @@ def list_images(self, compartment_id, **kwargs):
12301246
def list_instance_console_connections(self, compartment_id, **kwargs):
12311247
"""
12321248
ListInstanceConsoleConnections
1233-
Lists the console connections for the specified compartment or instance that have not been deleted.
1249+
Lists the serial console connections for the specified compartment or instance.
1250+
1251+
For more information about serial console access, see `Accessing the Serial Console`__.
1252+
1253+
__ https://docs.us-phoenix-1.oraclecloud.com/Content/Compute/References/serialconsole.htm
12341254
12351255
12361256
:param str compartment_id: (required)
@@ -1612,6 +1632,58 @@ def terminate_instance(self, instance_id, **kwargs):
16121632
path_params=path_params,
16131633
header_params=header_params)
16141634

1635+
def update_console_history(self, instance_console_history_id, update_console_history_details, **kwargs):
1636+
"""
1637+
UpdateConsoleHistory
1638+
Updates the specified console history metadata.
1639+
1640+
1641+
:param str instance_console_history_id: (required)
1642+
The OCID of the console history.
1643+
1644+
:param UpdateConsoleHistoryDetails update_console_history_details: (required)
1645+
Update instance fields
1646+
1647+
:param str if_match: (optional)
1648+
For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match`
1649+
parameter to the value of the etag from a previous GET or POST response for that resource. The resource
1650+
will be updated or deleted only if the etag you provide matches the resource's current etag value.
1651+
1652+
:return: A :class:`~oci.response.Response` object with data of type :class:`~oci.core.models.ConsoleHistory`
1653+
:rtype: :class:`~oci.response.Response`
1654+
"""
1655+
resource_path = "/instanceConsoleHistories/{instanceConsoleHistoryId}"
1656+
method = "PUT"
1657+
1658+
# Don't accept unknown kwargs
1659+
expected_kwargs = [
1660+
"if_match"
1661+
]
1662+
extra_kwargs = [key for key in six.iterkeys(kwargs) if key not in expected_kwargs]
1663+
if extra_kwargs:
1664+
raise ValueError(
1665+
"update_console_history got unknown kwargs: {!r}".format(extra_kwargs))
1666+
1667+
path_params = {
1668+
"instanceConsoleHistoryId": instance_console_history_id
1669+
}
1670+
path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
1671+
1672+
header_params = {
1673+
"accept": "application/json",
1674+
"content-type": "application/json",
1675+
"if-match": kwargs.get("if_match", missing)
1676+
}
1677+
header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing}
1678+
1679+
return self.base_client.call_api(
1680+
resource_path=resource_path,
1681+
method=method,
1682+
path_params=path_params,
1683+
header_params=header_params,
1684+
body=update_console_history_details,
1685+
response_type="ConsoleHistory")
1686+
16151687
def update_image(self, image_id, update_image_details, **kwargs):
16161688
"""
16171689
UpdateImage

0 commit comments

Comments
 (0)