如何使用c#访问Oracle Bare Metal Cloud中的Oracle Object存储。 我希望在.NET程序中运行c#中的类似代码:
static IAmazonS3 client;
using (client = new AmazonS3Client(Amazon.RegionEndpoint.USEast1))
{
GetObjectRequest request = new GetObjectRequest
{
BucketName = bucketName,
Key = keyName
};
using (GetObjectResponse response = client.GetObject(request))
{
string dest =
Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.Desktop),
keyName);
if (!File.Exists(dest))
{
response.WriteResponseStreamToFile(dest);
}
}
}
答案 0 :(得分:1)
请查看here,了解如何与C#中的Oracle Bare Metal Cloud Services REST API进行对话。可以非常轻松地修改此示例,以便与Object Storage服务进行通信。