Oracle Blockchain Platform is a preassembled PaaS solution that enables businesses to quickly deploy and manage blockchain networks. It includes all necessary components such as compute, storage, containers, identity services, and event management, along with an intuitive console for easy administration. Built on Hyperledger Fabric, Oracle enhances this open-source framework with automated provisioning, multi-cloud and hybrid network support, and seamless integration with Oracle Cloud Infrastructure. The platform offers robust security features, including encryption for data in transit and at rest, cyberattack protection, and comprehensive transaction auditing.

Designed for enterprise-grade applications, Oracle Blockchain Platform simplifies integration with business systems through REST APIs and plug-and-play adapters for ERP, SCM, HCM, and other Oracle and third-party applications. It provides Blockchain App Builder for easy smart contract development and tokenization, along with a highly available, resilient infrastructure that ensures continuous operation, automated monitoring, and self-recovery. With zero-downtime updates and built-in security monitoring, Oracle Blockchain Platform delivers a scalable, secure, and efficient environment for blockchain-powered business solutions.

To develop Novocoin within Oracle Blockchain Platform, we leverage the Blockchain App Builder for Oracle Blockchain Platform extension in Visual Studio Code. This tool allows us to automate code generation, eliminating the need to manually write every line of our smart contract. First, we install the extension in VS Code, then create a new specification called Novocoin in the Specifications Panel, where we define its properties as an internal, non-tradeable token designed to reward employees within the company.

Visual Studio Code displaying a Go controller file for Oracle Blockchain Platform smart contract development.

A Go-based smart contract controller file for Novochain, part of Oracle Blockchain Platform, open in Visual Studio Code. The code manages identity wallets and blockchain version tracking.

Once the specification is set up, we move to the Generation Panel, where Oracle does all the heavy lifting and automatically generates the necessary code in Go. This includes essential functions to manage the token, such as creation, updates, and administration within the corporate ecosystem. Instead of coding from scratch, we get a functional implementation ready to be customized and integrated into our time-tracking application.

To maintain control over the Novocoin deployment lifecycle on Oracle Blockchain Platform, we’ve introduced the GetNovocoinVersion function, which returns the current implementation version. This allows developers and administrators to track and verify the deployed version, ensuring compatibility across system components and facilitating seamless upgrades. By exposing this method, we gain a simple yet effective way to query versioning directly from the blockchain, avoiding manual checks and potential inconsistencies in distributed environments.

Copy to Clipboard

Within the scaffolding generated by Oracle Blockchain Platform, the most critical part resides in the controller, specifically in the file:

src/controller/Novochain.controller.go

This file contains the core functions that govern the lifecycle of Novocoin, defining how it is initialized, updated, and minted once deployed on the blockchain. The key functions include:

  • InitializeNovocoinToken → Handles the initial setup of Novocoin, ensuring the token is properly registered on the blockchain.

  • UpdateNovocoinToken → Allows for modifications and updates to the token’s metadata or parameters as needed.

  • IssueTokens (or minting function) → Responsible for minting new Novocoin tokens, effectively adding them to the system once the chaincode is deployed.

Visual Studio Code displaying Go smart contract development for Oracle Blockchain Platform, with a context menu open for packaging.

A Go-based smart contract controller file for Novochain, shown in Visual Studio Code. The code handles token issuance and minting functions. A context menu is open, showing deployment options.

To deploy Novocoin directly on our platform in Oracle Cloud, we follow a few key steps.

First, we package and deploy the chaincode. In Visual Studio Code, using the Oracle Blockchain Platform panel, we select Novochain and choose the “Package” option. This prepares the chaincode for deployment. Once packaged, we go to our cloud platform

Novoshore dashboard displaying blockchain network status

Novoshore dashboard showcasing blockchain network health and activity metrics, including channels, peers, and node performance.

The easiest way to install it is by using the quick deployment option in the Chaincode menu.

Oracle Blockchain Platform interface for deploying chaincode with Quick and Advanced options.

Oracle Blockchain Platform’s “Deploy Chaincode” feature offering Quick and Advanced Deployment options for seamless chaincode management.

Oracle Blockchain Platform automatically generates a REST layer that allows us to interact with our smart contract without dealing with blockchain transactions manually. This REST API exposes all the functions from our Novochain.controller.go file, enabling seamless interaction with Novocoin.

Oracle Blockchain Platform nodes summary

Oracle Blockchain Platform nodes summary displaying details of peers, orderers, CA, and REST Proxy configurations.

Once deployed, we can call various REST endpoints to manage Novocoin. Additionally, we can use Visual Studio Code to generate a Postman collection, which helps simplify API testing and interaction.

Visual Studio Code interface showing the Novocoin controller file with options to generate a Postman collection for API testing

Visual Studio Code integration with Oracle Blockchain Platform, highlighting the option to generate Postman collections for smart contract API testing.

We can see how different requests have been generated in Postman for each function within our Controller, allowing us to test each operation individually. This helps us verify that all API functionalities are correctly implemented and responding as expected.

Visual Studio Code interface showing Novocoin controller file with an option to generate Postman collections for API testing.

Visual Studio Code integration with Oracle Blockchain Platform, enabling automated Postman collection generation for smart contract API testing.

To check that everything has been set up correctly, we will call the CheckVersion function from the Controller API, which returns the current blockchain version. Using the Postman collection we previously generated, we will make a GET request to http://localhost:<PORT>/CheckVersion. If everything is working properly, we should receive the response: "Blockchain version check: Test version 1.0"

Postman interface showing a POST request to Oracle Blockchain Platform's API for the "CheckVersion" function, with a successful JSON response displaying blockchain version details.

POST request in Postman querying the blockchain version on Oracle Blockchain Platform, returning a success message and version metadata.

With all this set up, our blockchain is now ready to work with. In future articles, we will explore how to send tokens, interact with smart contracts, and perform transactions, making our blockchain a fully functional ecosystem.

For more information, please visit our company website. Stay updated and feel free to reach out for support or contributions!