vania-janet/multiturn-rag-retrieval-data huggingface dataset:
* ibmcloud is image-create my-image-from-volume --source-volume r006-c95c2317-6336-45b4-b67d-087312895a4e --deprecate-at "2023-03-01T00:45:00Z" --obsolete-at "2023-03-02T00:50:00Z"







 Command options 



* IMAGE_NAME: Name of the image.
* --file: The Cloud Object Store (COS) location of the image file, for example: cos://us-south/custom-image-vpc-bucket/customImage-0.qcow2.
* --os-name: Name of the operating system for this image.
* --encrypted-data-key: A base64-encoded, encrypted representation of the key that was used to encrypt the data for this image.
* --encryption-key: The CRN of the root key that was used to wrap the data key (which is ultimately represented as encrypted_data_key). Additionally, the root key is used to encrypt volumes created from this image (unless an alternate encryption_key is provided at volume creation).
* --source-volume: ID or name of the volume. The volume from which to create the image. The specified volume must originate from image. The volume's active and busy property value must be false, and the volume attached instance must be in stopped status.
* --encryption-key-volume: A reference to the root key to that is used to wrap the system-generated data encryption key for the image. If this property is not provided, the root key from source volume is used.
* --resource-group-id: ID of the resource group. This ID is mutually exclusive with --resource-group-name.
* --resource-group-name: Name of the resource group. This name is mutually exclusive with --resource-group-id.
* --deprecate-at: The deprecation date and time to set for this image.
Certification details and attestation reports (that is, ISO and SOC2) can be provided to the customer upon request.





 Technical and Organizational Measures 

Technical and Organizational Measures (TOMs) are employed by IBM Cloudant to ensure the security of Personal Data. IBM Cloudant holds externally audited certifications for the controls IBM Cloudant employs. Certification details and attestation reports (that is, ISO and SOC2) can be provided to the customer upon request.





 Service access to data 

IBM Cloudant operations and support staff have access to customer data and can access it during routine operations. This access is only done as required in order to operate and support the service. Access is also limited to a need to know basis and is logged, monitored, and audited.







 Deletion of data 



 Deleting a document 

When a document is deleted, the database creates a "tombstone." What the tombstone includes depends on how you delete it:



* If you make a DELETE call, the tombstone includes the _id, _rev, and _deleted fields.
* If you delete by updating the document with a _deleted: true field and add a PUT or POST request to it, the tombstone includes what you set in the document body. This practice can be useful in some circumstances, for example, when recording why a document was deleted in its tombstone.



For more information, see [Simple removal of "tombstone" documents](https://cloud.ibm.com/docs/Cloudant?topic=Cloudant-documentstombstone-documents).





 When is a deleted document removed? 

Compaction runs automatically and periodically removes old revisions (deleted or otherwise) from the database, by writing out only "leaf" revisions to a new file. IBM Cloudant keeps a history of _id and _rev to enable replication, but not old document bodies.

IBM Cloudant doesn't expose the CouchDB compaction API.

IBM Cloudant doesn't guarantee that a database is compacted in a specific time. Compaction is done as a background process across the storage tier. Databases are always being compacted. It isn't guaranteed that the data compacted is the data that you deleted or changed.
To see an example of how to install a package, check out the [IBM Cloud Object Storage package](https://cloud.ibm.com/docs/openwhisk?topic=openwhisk-pkg_obstorage). IBM Cloud® Object Storage is a service that allows users to store all types of files, such as images, videos, music, and text. To interact with the files, a Cloud-based datastore of key-value pairs is stored in a bucket. So, to use the [IBM Cloud Object Storage package](https://cloud.ibm.com/docs/openwhisk?topic=openwhisk-pkg_obstorage), you must first create an IBM Cloud Object Storage service instance, and then create a bucket. The bucket is used as an environment variable that is required to install this package.

After you create the service instance and bucket, you can install the package by using the following commands:



1. Clone the package repo.

git clone https://github.com/ibm-functions/package-cloud-object-storage.git
2. Navigate to the package directory that contains the manifest.yaml. In this example, the Node.js runtime version of the IBM Cloud Object Storage package is used.

cd package-cloud-object-storage/runtimes/nodejs
3. Deploy the package, using your bucket as an environment variable. You can give the package a custom name by using the PACKAGE_NAME environment variable.

PACKAGE_NAME=<custom_package_name> BUCKET=<bucket_name> ibmcloud fn deploy
It's most likely that PouchDB would be the replication controller in this case.

PouchDB is commonly used to create offline first apps. These apps collect data even when not connected to the internet, and then write data to IBM Cloudant when they come back online, giving their users an always on service.

Replication cannot always be required. If your application needs to store data and then write it to IBM Cloudant later, then replication isn't strictly speaking required. All that is required is that data is stored on the device, and bulk is written to IBM Cloudant when the connection is restored.

As replication is a one-way operation, if a primary-primary setup is required between two IBM Cloudant instances in different regions, then two replications in opposite directions are required.

Changes occurring on the London side are sent to Dallas, and vice versa.

More complex topologies are possible, with data that flows in a ring around a set IBM Cloudant service.

To summarize, IBM Cloudant replication is a mechanism for copying data from a source database to a target database.

Replications can be one-off or continuous and can optionally be filtered with a JavaScript function or IBM Cloudant Query selector and can be resumed from where a previous replication stopped.

That's the end of this part. The next part is called Partitioned databases.







 Partitioned databases video 

Learn how partitioned databases work in IBM Cloudant, how to assign documents to specific shards, and why partitioned databases improve performance, cost, and scalability.



* Partitioned databases video script

Welcome to the Introduction to IBM Cloudant course, an 17-part video series that gives you an overview of the IBM Cloudant database-as-a-service.

This video is part 15 - Partitioned database.

IBM Cloudant is a distributed database, which is a discussion that is coming up. Many storage nodes make up an IBM Cloudant service and a database's documents are distributed across the nodes in groups called shards. A single database is said to be sharded or divided into multiple pieces.

In a normal IBM Cloudant database, a document is allocated a shard algorithmically - effectively documents are distributed around the shards randomly.
* UI
* CLI







 Building a Static Website 

This tutorial shows how to [host a static website](https://cloud.ibm.com/docs/cloud-object-storage?topic=cloud-object-storage-static-website-options) on IBM Cloud® Object Storage, including creating a bucket, uploading content, and configuring your new website.

Hosting static websites with IBM Cloud Object Storage serves static content for public access giving users flexibility, ease of delivery, and high availability. This tutorial contains instructions for using [cURL](https://cloud.ibm.com/docs/cloud-object-storage?topic=cloud-object-storage-curl), the [AWS CLI](https://cloud.ibm.com/docs/cloud-object-storage?topic=cloud-object-storage-aws-cli), as well as the [Console](https://cloud.ibm.com/login). Choose your path for this tutorial by using the links for switching between the instructions above the title of this topic.



 The Scenario 

The scenario for this tutorial simplifies web hosting to its essentials in order to highlight the steps involved. While not every configuration option will be covered in this tutorial, correctly completing this tutorial results in web-accessible content.





 Before you start 

Ensure that you have what you need to start:



* An account for the IBM Cloud Platform
* An instance of IBM Cloud Object Storage
* Content in fixed form, like text (HTML would be perfect), and image files



Check that you have the access as appropriate to either the instance of IBM Cloud Object Storage you will be using or the proper [permissions](https://cloud.ibm.com/docs/cloud-object-storage?topic=cloud-object-storage-iam-bucket-permissions) for the buckets you will be using for this tutorial.
Full-text search No No Yes, requires separate installer or container. Yes 
 Partition queries No No Yes Yes 
 Shard splitting No No Yes Available as tool for IBM Ops. 
 Selector on changes feed No Yes Yes Yes 
 Rate limits No No No User-defined [provisioned throughput capacity](https://cloud.ibm.com/docs/Cloudant?topic=Cloudant-ibm-cloud-publicprovisioned-throughput-capacity) settings 
 Request size 4 GB (default) 4 GB (default) 4 GB (default) 11 MB 
 Attachment size 4 GB (default) 4 GB (default) 4 GB (default) 10 MB 
 Security auth [CouchDB Auth](https://docs.couchdb.org/en/stable/intro/security.html) [CouchDB Auth](https://docs.couchdb.org/en/stable/intro/security.html) [CouchDB Auth](https://docs.couchdb.org/en/stable/intro/security.html) [IBM Cloudant legacy auth with API Keys](https://cloud.ibm.com/docs/Cloudant?topic=Cloudant-work-with-your-accountauthorization), [IBM Cloud IAM](https://cloud.ibm.com/docs/Cloudant?topic=Cloudant-managing-access-for-cloudant), or [CouchDB Auth](https://docs.couchdb.org/en/stable/intro/security.html) 
 LDAP No No No No 



The CouchDB _show, _list, _update, and _rewrite functions were deprecated in Apache CouchDB 3.0. For more information, see [deprecated feature warnings](https://docs.couchdb.org/en/stable/whatsnew/3.0.htmldeprecated-feature-warnings).

As a result, these functions are no longer supported for IBM Cloudant. They do not appear in IBM Cloudant documentation, and while the APIs currently remain in service, their use is not recommended. The IBM Cloudant Support team no longer supports them.
IP allowlists apply to both the IBM Cloudant API and Dashboard, so be mindful to include any administrator IP addresses that need to access the IBM Cloudant Dashboard directly. 
 CORS Enable CORS support for specific domains by using the IBM Cloudant Dashboard or API. For more information, see the [CORS API documentation](https://cloud.ibm.com/apidocs/cloudantgetcorsinformation). 







 Protection against data loss or corruption 

IBM Cloudant has a number of features to help you maintain data quality and availability:



Table 2. IBM Cloudant data quality and availability features

 Feature Description 

 Redundant and durable data storage By default, IBM Cloudant saves to disk three copies of every document to three different nodes in a cluster. Saving the copies ensures that a working failover copy of your data is always available, regardless of failures. 
 Data Replication and export You can replicate your databases continuously between clusters in different data centers or Apache CouchDB. Another option is to export data from IBM Cloudant (in JSON format) to other locations or sources (such as your own data center) for added data redundancy.
import com.ibm.cloud.cloudant.v1.model.Document;
import com.ibm.cloud.cloudant.v1.model.GetDocumentOptions;

Cloudant service = Cloudant.newInstance();

GetDocumentOptions documentOptions =
new GetDocumentOptions.Builder()
.db("products")
.docId("small-appliances:1000042")
.build();

Document response =
service.getDocument(documentOptions).execute()
.getResult();

System.out.println(response);

from ibmcloudant.cloudant_v1 import CloudantV1

service = CloudantV1.new_instance()

response = service.get_document(
db='products',
doc_id='small-appliances:1000042'
).get_result()

print(response)

getDocumentOptions := service.NewGetDocumentOptions(
"products",
"small-appliances:1000042",
)

document, response, err := service.GetDocument(getDocumentOptions)
if err != nil {
panic(err)
}

b, _ := json.MarshalIndent(document, "", " ")
fmt.Println(string(b))

const { CloudantV1 } = require('@ibm-cloud/cloudant');

const service = CloudantV1.newInstance({});

service.getDocument({
db: 'products',
docId: 'small-appliances:1000042'
}).then(response => {
console.log(response.result);
});

The previous Go example requires the following import block:

import (
"encoding/json"
"fmt"
You can [set up periodic snapshots for your File Storage for Classic](https://cloud.ibm.com/docs/FileStorage?topic=FileStorage-snapshots), which is a read-only image that captures the state of the instance at a point in time. To store the snapshot, you must request snapshot space on your File Storage for Classic. Snapshots are stored on the existing storage instance within the same zone. You can restore data from a snapshot if a user accidentally removes important data from the volume.

Complete the following steps to create a snapshot for your volume.



1. [Log in to your account. If applicable, target the appropriate resource group. Set the context for your cluster.](https://cloud.ibm.com/docs/containers?topic=containers-access_cluster)
2. Log in to the ibmcloud sl CLI.

ibmcloud sl init
3. List existing PVs in your cluster.

kubectl get pv
4. Get the details for the PV for which you want to create snapshot space and note the volume ID, the size and the IOPS. The volume ID, the size and the IOPS can be found in the Labels section of your CLI output.

kubectl describe pv <pv_name>
5. Create the snapshot size for your existing volume with the parameters that you retrieved in the previous step.

ibmcloud sl file snapshot-order <volume_ID> --size <size> --tier <iops>
6. Wait for the snapshot size to create. The snapshot size is successfully provisioned when the **Snapshot Size (GB)**in your CLI output changes from 0 to the size that you ordered.

ibmcloud sl file volume-detail <volume_ID>
7. Create the snapshot for your volume and note the ID of the snapshot that is created for you.

ibmcloud sl file snapshot-create <volume_ID>
8. Verify that the snapshot is created successfully.
Specify the name or ID of the custom image to export by using the IMAGE variable. You can specify a name for the export job with NEW_NAME. You can also specify the file format for exporting the image, either qcow2 or vhd. The qcow2 format is the default file format and is the required format if the custom image is encrypted. Additionally, specify the IBM Cloud Object Storage BUCKET where you want to export the custom image.

ibmcloud is image-export-job-create IMAGE [--name NEW_NAME] [--format qcow2 | vhd] --bucket BUCKET

The following example exports a custom image with the ID of 72251a2e-d6c5-42b4-97b0-b5f8e8d1f479. The export job is named my-export-job. The file format for exporting the image is qcow2. The IBM Cloud Object Storage bucket where the image exported is named my-bucket.

ibmcloud is image-export-job-create 72251a2e-d6c5-42b4-97b0-b5f8e8d1f479 --name my-export-job --format qcow2 --bucket my-bucket

For more information, see [ibmcloud is image-export-job-create](https://cloud.ibm.com/docs/vpc?topic=vpc-infrastructure-cli-plugin-vpc-referenceimage-export-job-create) in the VPC CLI reference page.





 Exporting a custom image with the API 

You can export an IBM Cloud VPC custom image to IBM Cloud Object Storage by using the application programming interface (API).

To export a custom image by using the API, use [Create an image export job](https://cloud.ibm.com/apidocs/vpc/latestcreate_image_export_job).

For the$image_id variable, specify the ID of the custom image that you want to export. You can optionally specify a meaningful name for the image export job. In this example, the export job name is my-image-export.
To display the details for the IBM Cloud Object Storage service instance where your images are stored, click in the table row that is associated with the instance, in the Group, Location, Product, or Status columns, for example. Don't click the name of the service instance, which opens the Buckets page.
3. From the right panel, copy the GUID. For example, f7d4676f-f298-4cb3-8390-2fe258a5d6df.
4. Run the following command and replace $COS_INSTANCE_GUID with the GUID.



ibmcloud iam authorization-policy-create is cloud-object-storage Reader --source-resource-type image --target-service-instance-id $COS_INSTANCE_GUID

For more information about all of the parameters that are available for this command, see [ibmcloud iam authorization-policy-create](https://cloud.ibm.com/docs/cli?topic=cli-ibmcloud_commands_iamibmcloud_iam_authorization_policy_create).





 Granting access with the API 

To authorize a source service access to a target service, use the [IAM Policy Management API](https://cloud.ibm.com/apidocs/iam-policy-managementcreate-a-policy). See the following API example for Create a policy method with the type=authorization specified. All of the possible attributes are listed.

The supported attributes for creating an authorization policy depend on what each service supports. For more information about the supported attributes for each service, refer to the documentation for the services that you're using.

The example shows an authorization policy for the Image Service for VPC to access IBM Cloud Object Storage.

curl --location --request POST 'https://iam.cloud.ibm.com/v1/policies' --header 'Content-Type: application/json' --header 'Authorization: Bearer <iam token>' --data-raw '{
"type": "authorization",
"subjects": [
{
"attributes":
{
[ibm_cloud_env_var](https://cloud.ibm.com/docs-content/v1/content/63322f2f3a72050206eb05ba7f590fdcb741105c/cloud-object-storage/images/web-app-tutorial-016-env-variables.jpg)

Figure 6. Runtime Environment Variables defined for your app

Next, over at the Object Storage Portal for your service instance, add a bucket to contain your images. This scenario uses the bucket that is named web-images.







 Step 3: Customize your Node.js IBM Cloud Object Storage Image Gallery web Application 

Because this example uses an MVC architecture, adjusting the directory structure within your project to reflect this architecture is a convenience as well as a best practice. The directory structure has a views directory to contain the EJS view templates, a routes directory to contain the express routes, and a controllers directory as the place to put the controller logic. Place these items under a parent source directory named src (see Figure 7).

Zoom

![Directory structure](https://cloud.ibm.com/docs-content/v1/content/63322f2f3a72050206eb05ba7f590fdcb741105c/cloud-object-storage/images/web-app-tutorial-017-soure-code.jpg)

Figure 7. Source code structure for your app

Tip: The repo that you cloned earlier contain a directory that is named COS-WebGalleryEnd. Viewing the source code of the completed application in your preferred editor might be helpful as you follow the next steps. This is the version of your webapplication that is committed and deployed to IBM Cloud Platform when you complete this tutorial.



 Designing the app 

These are the two main tasks that a user should be able to do with the simple image gallery web application:

- Upload images from a web browser to the Object Storage bucket.
- View the images in the Object Storage bucket in a web browser.
--------------------







 ibmcloud is image-export-job-delete 

Delete one or more image export jobs.

ibmcloud is image-export-job-delete IMAGE (JOB1 JOB2 ...) [--output JSON] [-f, --force] [-q, --quiet]



 Command examples 



* ibmcloud is image-export-job-delete 72251a2e-d6c5-42b4-97b0-b5f8e8d1f479 6451a2e-d6c5-42b4-97b0-b5f8e8d1f479
* ibmcloud is image-export-job-delete my-image my-export-job







 Command options 



* IMAGE: ID or name of the image.
* JOB1: ID or name of the image export job.
* JOB2: ID or name of the image export job.
* --output: Specify output format, only JSON is supported. One of: JSON.
* --force, -f: Force the operation without confirmation.
* -q, --quiet: Suppress verbose output.



--------------------







 ibmcloud is image-deprecate 

Deprecate an image.

ibmcloud is image-deprecate IMAGE [--output JSON] [-q, --quiet]



 Command example 



* ibmcloud is image-deprecate my-image-from-volume-cli-do-not-delete







 Command options 



* IMAGE: ID or name of the image.
* --output: Specify output format, only JSON is supported. One of: JSON.
* -q, --quiet: Suppress verbose output.



--------------------







 ibmcloud is image-obsolete 

Obsolete an image
Connecting to IBM Cloud Object Storage 

Use the following information to learn how to connect to IBM Cloud® Object Storage from your virtual private cloud.



 What is IBM Cloud Object Storage? 

IBM Cloud® Object Storage is a web-scale platform that stores unstructured data. It provides reliability, security, availability, and disaster recovery without replication.

Information that is stored with IBM Cloud Object Storage is encrypted and dispersed across multiple geographic locations. It is accessible through an implementation of the S3 API. This service uses the distributed storage technologies that are provided by the IBM Cloud® Object Storage System.

Cloud Object Storage is available with three types of configurations for resiliency: Cross Region, Regional, and Single data center.



* Cross Region service provides higher durability and availability than using a single region, at the cost of slightly higher latency. This service is available today in the US, E.U., and A.P. areas.
* Regional service reverses the tradeoffs. It distributes objects across multiple availability zones within a single region. It is available in the US, E.U., and A.P. regions. If a region or zone is unavailable, the object store continues to function without impediment.
* Single data center service distributes objects across multiple machines within the same physical location. Check this document regularly for available regions.





 Cloud Object Storage direct endpoints for use with VPC 

To send a REST API request, you must set a target endpoint or a URL, and each Cloud Object Storage location must have its own set of URLs. Direct endpoints provide your servers with high-speed, direct connections to IBM Cloud services, which incur no added bandwidth costs. With the Cloud Object Storage direct endpoint, a VPC can connect to a Cloud Object Storage bucket located anywhere in the world.

You don't incur charges for traffic from your VPCs to all Cloud Object Storage endpoints that are listed in the following tables.



* A VPC client also has access to the Cloud Object Storage bucket over the public endpoint.