Oracle Cloud Infrastructure SDK for Java
About
oci-java-sdk provides an SDK for Java that you can use to manage your Oracle Cloud Infrastructure resources.
The project is open source and maintained by Oracle Corp. The home page for the project is here.
Installation
For basic set up, see Getting Started.
For details on compatibility, advanced configurations, and add-ons, see Configuration.
Examples
Examples can be found here.
You may run any example by invoking the exec:java
goal and passing appropriate values for exec.mainClass
and .exec.arguments
properties, for example: ObjectStorageGetBucketExample
class requires 3 arguments which are OCID of the compartment, name of bucket, name of object. This example class can be executed as follows:
mvn -am -pl bmc-examples exec:java -Dexec.mainClass=ObjectStorageGetBucketExample \
-Dexec.arguments=compartment_ocid,bucket_name,object_name
Where compartment_id
, bucket_name
, and object_name
should be substituted with appropriate values according to your setup.
Documentation
Full documentation, including prerequisites, installation, and configuration instructions, is available here.
API reference can be found here.
Help
For details on contributions, questions, or feedback, see Contact Us.
Changes
See CHANGELOG.
Contributing
oci-java-sdk is an open source project. See CONTRIBUTING for details.
Oracle gratefully acknowledges the contributions to oci-java-sdk that have been made by the community.
Known Issues
You can find information on any known issues with the SDK here and under the “Issues” tab of this GitHub repository.
Potential data corruption issue with OCI Java SDK on binary data upload with RefreshableOnNotAuthenticatedProvider
Details: When using version 1.25.1 or earlier of the OCI Java SDK clients that upload streams of data (for example ObjectStorageClient
or FunctionsInvokeClient
), either synchronously and asynchronously, and you use a RefreshableOnNotAuthenticatedProvider
(for example, for Resource Principals or Instance Principals) you may be affected by silent data corruption.
Workaround: Update the OCI Java SDK client to version 1.25.2 or later. For more information about this issue and workarounds, see Potential data corruption issue for OCI Java SDK on binary data upload with RefreshableOnNotAuthenticatedProvider
.
Direct link to this issue: Potential data corruption issue with OCI Java SDK on binary data upload with RefreshableOnNotAuthenticatedProvider
License
Copyright (c) 2016, 2020, Oracle and/or its affiliates. All rights reserved. This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.
See LICENSE for more details.