Skip to content

Commit

Permalink
Merge pull request #33 from oracle/release_2017-10-12
Browse files Browse the repository at this point in the history
Releasing version 1.3.8
  • Loading branch information
nathan-vu authored Oct 13, 2017
2 parents 795f7ab + c469172 commit 282219d
Show file tree
Hide file tree
Showing 63 changed files with 5,018 additions and 233 deletions.
21 changes: 21 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,27 @@ All notable changes to this project will be documented in this file.

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

====================
1.3.8 - 2017-10-12
====================

Deprecated
----------
* 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.

Added
-----
* Support for creating block volumes and specifying the size in GBs.
* Support in UploadManager for handling piped input.
* Support for adding and updating display names for captured instance serial console data.
* Support for VNIC source/destination checks.
* Support for new Database service features: VM DBs, Bring Your Own License, and Data Guard.
* Support for the FRA (eu-frankfurt-1) region.

Changed
-------
* The size of block volumes and volume backups is specified in GBs as well as MBs.

====================
1.3.7 - 2017-09-11
====================
Expand Down
22 changes: 22 additions & 0 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,28 @@ If you wish to run an individual test then you can run:
py.test -s tests/integ/test_launch_instance_tutorial.py
Specifying a config file
------------------------

By default, the tests will look for a config file at 'tests/resources/config'
and use the ``DEFAULT`` profile. You can change this with the ``--config-file``
and ``--config-profile`` options.

.. code-block:: sh
# Use a different config file, still using the DEFAULT profile
tox -- --config-file ~/.oci/config
# Using a different profile in the default config file
tox -- --config-profile IAD_PROFILE
Specifying environment variables
--------------------------------
In addition to a valid config file for your tenancy, the tests also require the following environment
variables to be set:

* ``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``.

Generating Documentation
========================
Sphinx is used for documentation. You can generate HTML locally with the following:
Expand Down
20 changes: 20 additions & 0 deletions docs/api/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,26 @@ Virtual Network
:undoc-members:
:imported-members:

==========
Database
==========

--------
Client
--------

.. autoclass:: oci.database.database_client.DatabaseClient
:members:

--------
Models
--------

.. automodule:: oci.database.models
:members:
:undoc-members:
:imported-members:

==========
Identity
==========
Expand Down
2 changes: 1 addition & 1 deletion docs/backward-compatibility.rst
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,4 @@ Backward Compatibility
~~~~~~~~~~~~~~~~~~~~~~
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``).

**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.
**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.
2 changes: 1 addition & 1 deletion docs/deprecation-notice.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@ Deprecation Notice
~~~~~~~~~~~~~~~~~~

.. warning::
This domain is deprecated and will be removed in March 2018.
This domain is deprecated and will no longer be maintained starting March 2018.

Please access the documentation through our new location `here <https://oracle-cloud-infrastructure-python-sdk.readthedocs.io/>`_.
2 changes: 1 addition & 1 deletion docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ This is the public Python SDK for Oracle Cloud Infrastructure. Python 2.7+ and
To get started, head over to the :ref:`installation instructions <install>` or see more examples in the
:ref:`quickstart <quickstart>` section.

**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``.
**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``.

.. toctree::
:hidden:
Expand Down
5 changes: 4 additions & 1 deletion docs/installation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -23,14 +23,17 @@ The Python SDK supports operations for the following services:
Prerequisites
===============

.. note::
The Python SDK uses the `cryptography.io`_ library, which has its own additional `build requirements`_. Ensure
that you satisfy those requirements prior to installing the Python SDK.

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

Expand Down
1 change: 1 addition & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ coverage==4.2
cryptography==1.8.2
flake8==3.0.4
httpsig_cffi==15.0.0
mock==2.0.0
pytest==3.0.2
pytest-catchlog==1.2.2
python-dateutil==2.5.3
Expand Down
2 changes: 1 addition & 1 deletion src/oci/core/blockstorage_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ def create_volume(self, create_volume_details, **kwargs):
"""
CreateVolume
Creates a new volume in the specified compartment. Volumes can be created in sizes ranging from
50 GB (51200 MB) to 2 TB (2097152 MB), in 1 GB (1024 MB) increments. By default, volumes are 1 TB (1048576 MB).
50 GB (51200 MB) to 16 TB (16777216 MB), in 1 GB (1024 MB) increments. By default, volumes are 1 TB (1048576 MB).
For general information about block volumes, see
`Overview of Block Volume Service`__.
Expand Down
80 changes: 76 additions & 4 deletions src/oci/core/compute_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,15 @@ def create_image(self, create_image_details, **kwargs):
def create_instance_console_connection(self, create_instance_console_connection_details, **kwargs):
"""
CreateInstanceConsoleConnection
Create a console connection for an instance.
Creates a new serial console connection to the specified instance.
Once the serial console connection has been created and is available,
you connect to the serial console using an SSH client.
The default number of enabled serial console connections per tenancy is 10.
For more information about serial console access, see `Accessing the Serial Console`__.
__ https://docs.us-phoenix-1.oraclecloud.com/Content/Compute/References/serialconsole.htm
:param CreateInstanceConsoleConnectionDetails create_instance_console_connection_details: (required)
Expand Down Expand Up @@ -395,7 +403,7 @@ def delete_image(self, image_id, **kwargs):
def delete_instance_console_connection(self, instance_console_connection_id, **kwargs):
"""
DeleteInstanceConsoleConnection
Delete the console connection for an instance
Deletes the specified serial console connection.
:param str instance_console_connection_id: (required)
Expand Down Expand Up @@ -447,6 +455,14 @@ def detach_vnic(self, vnic_attachment_id, **kwargs):
When you terminate an instance, all attached VNICs (primary
and secondary) are automatically detached and deleted.
**Important:** If the VNIC has a
:class:`PrivateIp` that is the
`target of a route rule`__,
deleting the VNIC causes that route rule to blackhole and the traffic
will be dropped.
__ https://docs.us-phoenix-1.oraclecloud.com/Content/Network/Tasks/managingroutetables.htm#privateip
:param str vnic_attachment_id: (required)
The OCID of the VNIC attachment.
Expand Down Expand Up @@ -784,7 +800,7 @@ def get_instance(self, instance_id, **kwargs):
def get_instance_console_connection(self, instance_console_connection_id, **kwargs):
"""
GetInstanceConsoleConnection
Get the details of an instance console connection
Gets the specified serial console connection's information.
:param str instance_console_connection_id: (required)
Expand Down Expand Up @@ -1230,7 +1246,11 @@ def list_images(self, compartment_id, **kwargs):
def list_instance_console_connections(self, compartment_id, **kwargs):
"""
ListInstanceConsoleConnections
Lists the console connections for the specified compartment or instance that have not been deleted.
Lists the serial console connections for the specified compartment or instance.
For more information about serial console access, see `Accessing the Serial Console`__.
__ https://docs.us-phoenix-1.oraclecloud.com/Content/Compute/References/serialconsole.htm
:param str compartment_id: (required)
Expand Down Expand Up @@ -1612,6 +1632,58 @@ def terminate_instance(self, instance_id, **kwargs):
path_params=path_params,
header_params=header_params)

def update_console_history(self, instance_console_history_id, update_console_history_details, **kwargs):
"""
UpdateConsoleHistory
Updates the specified console history metadata.
:param str instance_console_history_id: (required)
The OCID of the console history.
:param UpdateConsoleHistoryDetails update_console_history_details: (required)
Update instance fields
:param str if_match: (optional)
For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match`
parameter to the value of the etag from a previous GET or POST response for that resource. The resource
will be updated or deleted only if the etag you provide matches the resource's current etag value.
:return: A :class:`~oci.response.Response` object with data of type :class:`~oci.core.models.ConsoleHistory`
:rtype: :class:`~oci.response.Response`
"""
resource_path = "/instanceConsoleHistories/{instanceConsoleHistoryId}"
method = "PUT"

# Don't accept unknown kwargs
expected_kwargs = [
"if_match"
]
extra_kwargs = [key for key in six.iterkeys(kwargs) if key not in expected_kwargs]
if extra_kwargs:
raise ValueError(
"update_console_history got unknown kwargs: {!r}".format(extra_kwargs))

path_params = {
"instanceConsoleHistoryId": instance_console_history_id
}
path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}

header_params = {
"accept": "application/json",
"content-type": "application/json",
"if-match": kwargs.get("if_match", missing)
}
header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing}

return self.base_client.call_api(
resource_path=resource_path,
method=method,
path_params=path_params,
header_params=header_params,
body=update_console_history_details,
response_type="ConsoleHistory")

def update_image(self, image_id, update_image_details, **kwargs):
"""
UpdateImage
Expand Down
2 changes: 2 additions & 0 deletions src/oci/core/models/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@
from .tunnel_config import TunnelConfig
from .tunnel_status import TunnelStatus
from .udp_options import UdpOptions
from .update_console_history_details import UpdateConsoleHistoryDetails
from .update_cpe_details import UpdateCpeDetails
from .update_cross_connect_details import UpdateCrossConnectDetails
from .update_cross_connect_group_details import UpdateCrossConnectGroupDetails
Expand Down Expand Up @@ -171,6 +172,7 @@
"TunnelConfig": TunnelConfig,
"TunnelStatus": TunnelStatus,
"UdpOptions": UdpOptions,
"UpdateConsoleHistoryDetails": UpdateConsoleHistoryDetails,
"UpdateCpeDetails": UpdateCpeDetails,
"UpdateCrossConnectDetails": UpdateCrossConnectDetails,
"UpdateCrossConnectGroupDetails": UpdateCrossConnectGroupDetails,
Expand Down
27 changes: 27 additions & 0 deletions src/oci/core/models/capture_console_history_details.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,42 @@ class CaptureConsoleHistoryDetails(object):
def __init__(self):

self.swagger_types = {
'display_name': 'str',
'instance_id': 'str'
}

self.attribute_map = {
'display_name': 'displayName',
'instance_id': 'instanceId'
}

self._display_name = None
self._instance_id = None

@property
def display_name(self):
"""
Gets the display_name of this CaptureConsoleHistoryDetails.
A user-friendly name. Does not have to be unique, and it's changeable.
:return: The display_name of this CaptureConsoleHistoryDetails.
:rtype: str
"""
return self._display_name

@display_name.setter
def display_name(self, display_name):
"""
Sets the display_name of this CaptureConsoleHistoryDetails.
A user-friendly name. Does not have to be unique, and it's changeable.
:param display_name: The display_name of this CaptureConsoleHistoryDetails.
:type: str
"""
self._display_name = display_name

@property
def instance_id(self):
"""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ def __init__(self):
def instance_id(self):
"""
Gets the instance_id of this CreateInstanceConsoleConnectionDetails.
The host instance OCID
The OCID of the instance to create the serial console connection to.
:return: The instance_id of this CreateInstanceConsoleConnectionDetails.
Expand All @@ -38,7 +38,7 @@ def instance_id(self):
def instance_id(self, instance_id):
"""
Sets the instance_id of this CreateInstanceConsoleConnectionDetails.
The host instance OCID
The OCID of the instance to create the serial console connection to.
:param instance_id: The instance_id of this CreateInstanceConsoleConnectionDetails.
Expand All @@ -50,7 +50,7 @@ def instance_id(self, instance_id):
def public_key(self):
"""
Gets the public_key of this CreateInstanceConsoleConnectionDetails.
An ssh public key that will be used to authenticate the console connection.
The SSH public key used to authenticate the serial console connection.
:return: The public_key of this CreateInstanceConsoleConnectionDetails.
Expand All @@ -62,7 +62,7 @@ def public_key(self):
def public_key(self, public_key):
"""
Sets the public_key of this CreateInstanceConsoleConnectionDetails.
An ssh public key that will be used to authenticate the console connection.
The SSH public key used to authenticate the serial console connection.
:param public_key: The public_key of this CreateInstanceConsoleConnectionDetails.
Expand Down
Loading

0 comments on commit 282219d

Please sign in to comment.