vania-janet/multiturn-rag-retrieval-data huggingface dataset:
* Java smart contracts must use fabric-chaincode-shim at v1.4.6 or later (if deploying on a peer that uses a Fabric 1.4.x image; peers that use a Fabric 2.x image do not require a shim), as this version is the first version that includes support for Java 11.
* For an example of a Java smart contract, see the [Basic asset transfer smart contract](https://github.com/hyperledger/fabric-samples/tree/master/asset-transfer-basic/chaincode-java).



If you are using Windows, you also must ensure the following:



* Docker for Windows is configured to use Linux containers (by default).
* You installed the C++ Build Tools for Windows from [windows-build-tools](https://github.com/felixrieseberg/windows-build-toolswindows-build-tools).
* You installed [OpenSSL v1.0.2](https://www.openssl.org/community/binaries.html) if you are working with smart contracts that use Fabric v1.4 dependencies and want to run the generated functional tests.



* Install the normal version, not the version marked as "light".
* Install the Win64 version into C:\OpenSSL-Win64 on 64-bit systems.





If you installed Node and npm by using a manager such as 'nvm' or 'nodenv', you need to set the default or global version. You can then restart VS Code for the version to be detected by the Prerequisites page.





 Step one: Guided tutorials in VS Code 

Attention! The IBM Blockchain Platform Extension for VS Code (VS Code extension) referenced throughout the documentation is an open-source project which is no longer active, and therefore not officially supported by IBM. Refer to the [alternatives to the VS Code extension](https://github.com/IBM-Blockchain/blockchain-vscode-extension/issues/3159).

The IBM Blockchain Platform Developer Tooling includes guided tutorials to help you get started.
The IBM Cloud® Container Registry is required for this scenario.

Before you begin



* Set up your [Code Engine CLI](https://cloud.ibm.com/docs/codeengine?topic=codeengine-install-cli) environment.
* [Create and work with a project](https://cloud.ibm.com/docs/codeengine?topic=codeengine-manage-project).



Before you work with local source, make sure that your source is in an accessible location on your local workstation.

This example uses the https://github.com/IBM/CodeEngine samples; in particular, the helloworld sample.



1. Download the https://github.com/IBM/CodeEngine sample source to your local workstation with the following command.

git clone https://github.com/IBM/CodeEngine
2. Change to the CodeEnginehelloworld directory.
3. From the CodeEnginehelloworld directory, create and deploy the myapp-local app, which uses an image that is built from the CodeEnginehelloworld source on your local workstation. This command automatically builds and pushes the image to a Container Registry namespace in your account. If you do not have an existing Container Registry namespace, Code Engine automatically creates one for you.

ibmcloud ce application create --name myapp-local --build-source .

The . indicates the build source is located in your current working directory.

Example output

Creating application 'myapp-local'...
Packaging files to upload from source path '.'...
Submitting build run 'myapp-local-run-220414-171750199'...
Creating image 'private.us.icr.io/ce--abcde-glxo4kabcde/app-myapp-local:220414-2117-rdaga'...
Waiting for build run to complete...
Build run status: 'Running'
Build run completed successfully.
Alternatively, if you are using an SDK, [obtain an IAM API key](https://cloud.ibm.com/iam/apikeys) and set the client options by using environment variables.

export CD_TOOLCHAIN_AUTH_TYPE=iam && export CD_TOOLCHAIN_APIKEY={iam_api_key} && export CD_TOOLCHAIN_URL={base_url}
2. [Look up the ID of the toolchain](https://cloud.ibm.com/apidocs/toolchainlist-toolchains) in which you want to create your tool integration.
3. [Look up the tool_type_id value](https://cloud.ibm.com/docs/ContinuousDelivery?topic=ContinuousDelivery-integrations&interface=uiintegrations) that corresponds to the tool integration that you want to add.
4. Add the tool integration within the targeted toolchain.



* Curl
* Java
* Node
* Python
* Go



curl -X POST --location --header "Authorization: Bearer {iam_token}" --header "Accept: application/json" --header "Content-Type: application/json" --data '{ "name": "{tool_name}", "tool_type_id": "{tool_type_id}", "parameters": {tool_parameters} }' "{base_url}/toolchains/{toolchain_id}/tools"

import com.ibm.cloud.continuous_delivery.cd_toolchain.v2.CdToolchain;
import com.ibm.cloud.continuous_delivery.cd_toolchain.v2.model.;
...
CdToolchain toolchainService = CdToolchain.newInstance();
CreateToolOptions createToolOptions = new CreateToolOptions.Builder()
.name({tool_name})
.parameters({tool_parameters})
This will include the sample applications and runmqsc.
* Once downloaded, unpack the bundle into a location of your choosing.
* Make a note of the full path to the bin directory, the location of which will depend upon where you chose to unpack the bundle. This path will be referenced as <PATH_TO_BIN_DIR> for the rest of this task.
* Make a note of the full path to the directory containing the sample applications. This path will be referenced as <PATH_TO_SAMPLE_BIN_DIR> for the rest of this task.



* For Windows, this will be the bin directory unpacked in the previous step, the location of which will depend upon where you chose to unpack the bundle.
* For Linux, this will be the samp/bin directory unpacked in the previous step, the location of which will depend upon where you chose to unpack the bundle.





Mac users will need to also download the macos toolkit, which can be found [here](https://www14.software.ibm.com/cgi-bin/weblap/lap.pl?popup=Y&li_formnum=L-APIG-CAUEQC&accepted_url=https://public.dhe.ibm.com/ibmdl/export/pub/software/websphere/messaging/mqdev/mactoolkit/9.3.0.0-IBM-MQ-DevToolkit-MacX64.pkg)





4. Follow the steps to [gather credentials and certificates for your queue managers](https://cloud.ibm.com/docs/services/mqcloud?topic=mqcloud-mqoc_configure_chl_sslusing-the-mq-on-cloud-service-console-to-gather-credentials-and-certificates) and [create a keystore in a PKCS12 format](https://cloud.ibm.com/docs/mqcloud?topic=mqcloud-mqoc_configure_chl_sslmqoc_chl_ssl_keystore)







 Connecting to your remote queue managers
Alternatively, if you are using an SDK, [obtain an IAM API key](https://cloud.ibm.com/iam/apikeys) and set the client options by using environment variables.

export CD_TOOLCHAIN_AUTH_TYPE=iam && export CD_TOOLCHAIN_APIKEY={iam_api_key} && export CD_TOOLCHAIN_URL={base_url}
2. [Look up the ID of the toolchain](https://cloud.ibm.com/apidocs/toolchainlist-toolchains) in which you want to create your tool integration.
3. [Look up the tool_type_id value](https://cloud.ibm.com/docs/ContinuousDelivery?topic=ContinuousDelivery-integrations&interface=apiintegrations) that corresponds to the tool integration that you want to add.
4. Add the tool integration within the targeted toolchain.



* Curl
* Java
* Node
* Python
* Go



curl -X POST --location --header "Authorization: Bearer {iam_token}" --header "Accept: application/json" --header "Content-Type: application/json" --data '{ "name": "{tool_name}", "tool_type_id": "{tool_type_id}", "parameters": {tool_parameters} }' "{base_url}/toolchains/{toolchain_id}/tools"

import com.ibm.cloud.continuous_delivery.cd_toolchain.v2.CdToolchain;
import com.ibm.cloud.continuous_delivery.cd_toolchain.v2.model.;
...
CdToolchain toolchainService = CdToolchain.newInstance();
CreateToolOptions createToolOptions = new CreateToolOptions.Builder()
.name({tool_name})
.parameters({tool_parameters})
If you don't have a toolchain, select a template to [create a toolchain](https://cloud.ibm.com/devops/create). Depending on the template that you use, different fields might be available. Review the default field values and if needed, change those settings.
2. If you have a toolchain and are adding this tool integration to it, from the IBM Cloud console, click the menu icon ![hamburger icon](https://cloud.ibm.com/docs-content/v1/content/562806c0b18119f4d21cb66f5ae6d051634b4a16/ContinuousDelivery/images/icon_hamburger.svg) and select DevOps. On the [Toolchains page](https://cloud.ibm.com/devops/toolchains), click the toolchain to open its Overview page. Alternatively, on your app's Overview page, on the Continuous delivery card, click View toolchain. Then, click Overview.
3. Add the Delivery Pipeline integration to your toolchain:

a. Click Add tool.

b. In the Tool Integrations section, click Delivery Pipeline.
4. Specify a name for your new pipeline.
5. Select Tekton to create a Tekton Delivery Pipeline. This type of pipeline provides a dashboard that you can use to view the output of Tekton pipeline runs on a defined Kubernetes cluster, with support for configuring the pipeline definitions repos, the pipeline triggers, where the pipeline runs, and simple secrets.
6. If you plan to use your pipeline to deploy a user interface, select the Show apps in the View app menu checkbox. All of the apps that your pipeline creates are shown in the View App list on the toolchain's Overview page.
7. Click Create Integration to add the Delivery Pipeline to your toolchain.





 Configuring a Delivery Pipeline for Tekton by using the console 



1.
The name of the subscription must be unique within your project.
2. Run [ibmcloud ce app list](https://cloud.ibm.com/docs/codeengine?topic=codeengine-clicli-application-list) or [ibmcloud ce job list](https://cloud.ibm.com/docs/codeengine?topic=codeengine-clicli-job-list) to make sure that your destination app or job exists. If the app or job doesn't exist, create the application with the [ibmcloud ce app create](https://cloud.ibm.com/docs/codeengine?topic=codeengine-clicli-application-create) command or create the job with the [ibmcloud ce job create](https://cloud.ibm.com/docs/codeengine?topic=codeengine-clicli-job-create) command.
3. Try the solutions in [Why does my Object Storage subscription never become ready?](https://cloud.ibm.com/docs/codeengine?topic=codeengine-ts-cossub-notready)
Alternatively, if you are using an SDK, [obtain an IAM API key](https://cloud.ibm.com/iam/apikeys) and set the client options by using environment variables.

export CD_TOOLCHAIN_AUTH_TYPE=iam && export CD_TOOLCHAIN_APIKEY={iam_api_key} && export CD_TOOLCHAIN_URL={base_url}
2. [Look up the ID of the toolchain](https://cloud.ibm.com/apidocs/toolchainlist-toolchains) in which you want to create your tool integration.
3. [Look up the tool_type_id value](https://cloud.ibm.com/docs/ContinuousDelivery?topic=ContinuousDelivery-integrations&interface=terraformintegrations) that corresponds to the tool integration that you want to add.
4. Add the tool integration within the targeted toolchain.



* Curl
* Java
* Node
* Python
* Go



curl -X POST --location --header "Authorization: Bearer {iam_token}" --header "Accept: application/json" --header "Content-Type: application/json" --data '{ "name": "{tool_name}", "tool_type_id": "{tool_type_id}", "parameters": {tool_parameters} }' "{base_url}/toolchains/{toolchain_id}/tools"

import com.ibm.cloud.continuous_delivery.cd_toolchain.v2.CdToolchain;
import com.ibm.cloud.continuous_delivery.cd_toolchain.v2.model.;
...
CdToolchain toolchainService = CdToolchain.newInstance();
CreateToolOptions createToolOptions = new CreateToolOptions.Builder()
.name({tool_name})
.parameters({tool_parameters})
* [Creating a configuration in the API](https://cloud.ibm.com/docs/satellite?topic=satellite-storage-ibm-system-storage-block-csi-driveribm-system-storage-block-csi-driver-config-create-api)
* [Creating a storage assignment in the console](https://cloud.ibm.com/docs/satellite?topic=satellite-storage-ibm-system-storage-block-csi-driverstorage-ibm-system-storage-block-csi-driver-include-assignment-create-console)
* [Creating an assignment in the CLI](https://cloud.ibm.com/docs/satellite?topic=satellite-storage-ibm-system-storage-block-csi-driverstorage-ibm-system-storage-block-csi-driver-include-assignment-create-cli)
* [Creating a storage assignment in the API](https://cloud.ibm.com/docs/satellite?topic=satellite-storage-ibm-system-storage-block-csi-driverstorage-ibm-system-storage-block-csi-driver-include-assignment-create-api)
* [Deploying an app that uses Block Storage for Classic](https://cloud.ibm.com/docs/satellite?topic=satellite-storage-ibm-system-storage-block-csi-driverstorage-block-csi-app-deploy)
* [Parameter reference](https://cloud.ibm.com/docs/satellite?topic=satellite-storage-ibm-system-storage-block-csi-driveribm-system-storage-block-csi-driver-parameter-reference)



* [1.4.0 parameter reference](https://cloud.ibm.com/docs/satellite?topic=satellite-storage-ibm-system-storage-block-csi-driveribm-system-storage-block-csi-driver-1.4.0-parameters)
You will not need to do this on smart contracts that are written in Java or Node.js, nor for smart contracts written and packaged using the 2.0 package. See [Vendoring smart contracts](https://cloud.ibm.com/docs/blockchain?topic=blockchain-ibp-console-smart-contracts-v14ibp-console-smart-contracts-write-package-vendor) for details.

When you are ready to install and instantiate your smart contract to the IBM Blockchain platform, the smart contract must be packaged into .cds format. For more information, see [Packaging smart contracts](https://cloud.ibm.com/docs/blockchain?topic=blockchain-develop-vscodepackaging-a-smart-contract). Alternatively, you can use peer CLI commands to build the package. For v1.4.x commands, see [1.4.x peer CLI commands](https://hyperledger-fabric.readthedocs.io/en/release-1.4/commands/peerchaincode.htmlpeer-chaincode-package).



 Vendoring smart contracts 

If your smart contract uses the [fabric-chaincode-go](https://github.com/hyperledger/fabric-chaincode-go/tree/main/shim) shim or the [Go contract-api](https://github.com/hyperledger/fabric-contract-api-go) you need to repackage the smart contract before it can be installed on a peer that is running a Fabric v2.x image.

Why is vendoring the shim required?

In Fabric v1.4.x, the Go chaincode shim and protocol buffers (protos) were included with the Fabric distribution and were included in the Go chaincode runtime in the IBM Blockchain Platform.
Compile the Composer source code into a JSON file.



* JavaScript

compose demo.js > demo.json
* Python

pycompose demo.py > demo.json



3. Deploy the code to Cloud Functions. Include the -w flag to overwrite any existing deployment that is named demo.



* JavaScript

deploy demo demo.json -w
* Python

pydeploy demo demo.json -w



4. Execute the composition in the same way you [invoke other actions](https://cloud.ibm.com/docs/openwhisk?topic=openwhisk-triggers) in Cloud Functions.

ibmcloud fn action invoke demo



Cloud Functions executes the code that you deployed as a special action. For more information, see the documentation on [conductor actions](https://github.com/apache/openwhisk/blob/master/docs/conductors.md).





 Extending sequences with Composer 

With Apache OpenWhisk, you can chain functions together in a sequence, where the output of one action becomes the input to another action.



 Sequences without Composer 

You can chain together two functions that are named action1 and action2 in Cloud Functions:

ibmcloud fn action create --sequence mysequence action1 action2

The result of this command is a function that is called mysequence, which is a composite of action1 and action2. You can use mysequence in the same manner as any function in OpenWhisk.





 Sequences with Composer 

In Composer, you can specify richer sequences by using source code rather than the command line.



 For JavaScript 

const composer = require('@ibm-functions/composer')

module.exports = composer.seq('action1', 'action2')





 For Python 

import composer

def main():
return composer.sequence('action1', 'action2')

Zoom

![Sequence with two actions.]
curl -X POST https://api.us-south.ae.cloud.ibm.com/v3/analytics_engines/<GUID of Analytic Engine>/spark_applications --header "Authorization: Bearer $TOKEN" -H "content-type: application/json" -d @listTablesExample.json





 Apache Spark Data Engine integration 

For self-hosted Apache Spark installations use the following instructions.



1. Ensure that [Stocator](https://github.com/CODAIT/stocator) is installed according to the instructions provided.
2. Download the Hive-compatible client with the provided [instructions](https://cloud.ibm.com/docs/sql-query?topic=sql-query-hive_metastorehive_compatible_client).
3. Either download the [provided convenience libraries](https://cloud.ibm.com/docs/sql-query?topic=sql-query-hive_metastoreconvenience_libraries) or, in case you don't want to use them, set the following settings in SparkContext yourself:

spark = SparkSession.builder.appName('Python-App') 
.config("spark.sql.pyspark.jvmStacktrace.enabled", True) 
.config("spark.hive.metastore.truststore.path", "file:///opt/ibm/jdk/jre/lib/security/cacerts") 
 to access IBM Cloud Object Storage ensure that stocator is available
.config("fs.cos.impl", "com.ibm.stocator.fs.ObjectStoreFileSystem") 
.config("fs.stocator.scheme.list", "cos") 
.config("fs.stocator.cos.impl", "com.ibm.stocator.fs.cos.COSAPIClient") 
.config("fs.stocator.cos.scheme", "cos")
[hamburger icon](https://cloud.ibm.com/docs-content/v1/content/562806c0b18119f4d21cb66f5ae6d051634b4a16/ContinuousDelivery/images/icon_hamburger.svg) and select DevOps. On the Toolchains page, click the toolchain to open its Overview page. Alternatively, on your app's Overview page, on the Continuous delivery card, click View toolchain. Then, click Overview.

a. Click Add tool.

b. In the Tool Integrations section, click Event Notifications.
2. Type the name that you want to display for this tool integration on the Event Notifications card in your toolchain. This name is used to identify the tool integration in your toolchain.
3. Select the Event Notifications instance to connect the toolchain to.
4. Click Create Integration to add the Event Notifications tool integration to your toolchain.
5. On your Toolchain's Overview page, on the IBM Cloud tools card, click Event Notifications.



For more information about how to configure Event Notifications by using the API or Terraform, see [Enabling notifications](https://cloud.ibm.com/docs/ContinuousDelivery?topic=ContinuousDelivery-event-notifications-cd&interface=api&code=curlevent-notifications-enable-cd).



 Configuring Event Notifications by using the API 

The Event Notifications tool integration supports the following configuration parameters that you can use with the [Toolchain HTTP API and SDKs](https://cloud.ibm.com/apidocs/toolchain) when you [create](https://cloud.ibm.com/apidocs/toolchaincreate-tool), [read](https://cloud.ibm.com/apidocs/toolchainget-tool-by-id), and [update](https://cloud.ibm.com/apidocs/toolchainupdate-tool) tool integrations.
[hamburger icon](https://cloud.ibm.com/docs-content/v1/content/562806c0b18119f4d21cb66f5ae6d051634b4a16/ContinuousDelivery/images/icon_hamburger.svg) and select DevOps. On the Toolchains page, click the toolchain to open its Overview page. Alternatively, on your app's Overview page, on the Continuous delivery card, click View toolchain. Then, click Overview.

a. Click Add tool.

b. In the Tool Integrations section, click Event Notifications.
2. Type the name that you want to display for this tool integration on the Event Notifications card in your toolchain. This name is used to identify the tool integration in your toolchain.
3. Select the Event Notifications instance to connect the toolchain to.
4. Click Create Integration to add the Event Notifications tool integration to your toolchain.
5. On your Toolchain's Overview page, on the IBM Cloud tools card, click Event Notifications.







 Connecting to Event Notifications with the API 

You can add the Event Notifications tool integration to your toolchain by using the API.



1. [Obtain an IAM bearer token](https://cloud.ibm.com/apidocs/toolchainauthentication). Alternatively, if you are using an SDK, [obtain an IAM API key](https://cloud.ibm.com/iam/apikeys) and set the client options by using environment variables.

export CD_TOOLCHAIN_AUTH_TYPE=iam && export CD_TOOLCHAIN_APIKEY={iam_api_key} && export CD_TOOLCHAIN_URL={base_url}
2. [Look up the ID of the toolchain](https://cloud.ibm.com/apidocs/toolchainlist-toolchains) in which you want to create your tool integration.
3.
A new Finder window opens with the contents of the disk image.

If the Finder window does not open, double-click the macos_dsdriver icon on your desktop. 2. In the Finder window, double-click the installDSDriver.sh file.

The driver package is installed in the default location: /Applications/dsdriver.
* For updates to your existing driver package installation



1. Back up current configuration files:



a. Go the Applications/dsdriver/cfg folder.

b. Copy the following files to a different folder:

db2cli.ini

db2dsdriver.cfg



2. Remove the currently installed driver package by right-clicking the dsdriver folder and selecting Move to Trash.
3. Install the new driver package as described in the preceding For a new installation section:



a. Mount the disk image by double-clicking the macos_dsdriver.dmg file. b. In the Finder window, double-click the installDSDriver.sh file. 4. Restore the configuration files:

Copy the db2cli.ini and db2dsdriver.cfg files that you saved from Step 1 to the /Applications/dsdriver/cfg folder.







 What's next? 

To be able to connect your local applications or client tools to your Db2 Warehouse on Cloud database, [configure your local environment](https://cloud.ibm.com/docs/Db2whc?topic=Db2whc-dr_pkgcfg_loc_env).







 Installing the driver package on Windows 

You can install the Db2 Warehouse on Cloud driver package on Windows by using the installer.



 Prerequisites 

Before attempting to connect to your Db2 Warehouse on Cloud database, verify that you have the [prerequisites](https://cloud.ibm.com/docs/Db2whc/connecting?topic=Db2whc-connect_ovprereqs).





 Procedure 



1. Run the downloaded executable file as an administrator.
Figure 9. Kubernetes secure app toolchain summary





 Step 5: Explore your new toolchain 

After you create your toolchain, it shows each of the tool integrations that are part of the toolchain in a diagram.



 Explore the pipelines 

You can explore the pipelines to understand the toolchain flow and the different operations that run within each pipeline. The toolchain that you just created contains three pipelines:



* Pull request pipeline: Runs when a developer merges changes from their development branch to the master branch, or to any other branch in the repo. The pull request pipeline runs the Unit Test and Static Scans on the Application Source Code.
* Continuous integration pipeline: Runs when you merge a change into the master branch of the Application Source Code repo. The continuous integration pipeline runs the Unit Test, Code Coverage, and Static Scans on the Application Source Code, CIS check, and Bill Of Materials (BOM) check. The continuous delivery pipeline also generates the binary build artifacts and uploads them to the IBM Cloud® Kubernetes Service, as configured in the toolchain. And the continuous integration pipeline generates the metadata of the build artifacts and stores it in the Inventory repo.
* Continuous deployment pipeline: Deploys build artifacts to the deployment environment. The pipeline verifies the successful deployment of the app by running the health check. You must manually trigger this pipeline after the continuous integration pipeline successfully completes. Depending on the deployment strategy that you selected, more triggers are added to the continuous delivery pipeline.







 Run the pull request and continuous integration pipelines 

To start the pull request pipeline, create a merge request in your app repo:



1. On the Toolchain's Overview page, on the Repositories card, click the compliance-app-<timestamp> app repo.
2. From the master repo, create a branch.
3. Update some code in the sample node app or readme file and save these changes.
4. Submit the merge request.
5. On the Toolchain's Overview page, on the Repositories card, click the pr-pipeline repo to start the pull request pipeline.