Multi-part blog on microservices tutorials

This blog focuses on continuous delivery and test automation for the deployment of cloud native and hybrid applications.

Using IBM Garage approach we will show you how to implement some of the recommended “good” practices using a variety of cloud environment and deployment typologies

Outline

  • Prerequisites
  • Run the App locally

Prerequisites

To complete this quick start tutorial:

Download the sample

In a terminal window, run the following command to clone the sample app repository to your local machine.

   $ git clone https://github.com/

You use this terminal window to run all the commands in this quickstart.

Change to the directory that contains the sample code.

    $ cd nodejs-docs-hello-world

Run the app locally

Run the application locally by opening a terminal window and using the npm start script to launch the built in Node.js HTTP server.

npm start

Open a web browser, and navigate to the sample app at http://localhost:1337.

You see the Hello World message from the sample app displayed in the page.

 

DRAFT CONTENT

Has Jenkins become the default Continuous Integration (CI) tool for Microservices.

Here are some “good” practices for working with the Jenkins Pipeline

  1. Do: Use the right set of plugins
  2. Do: Pipeline as code
  3. Do: Divide work into a stage
  4. Do: All material work within a node
  5. Do: Work you can within a parallel step
  6. Do: Acquire nodes within parallel steps
  7. Do: Create inputs for automated or manual approvals
  8. Don’t: Use input within a node block
  9. Do: Wrap your inputs in a timeout
  10. Don’t: Set environment variables with env global variable
  11. Do: Prefer stashing files to archiving

Reference:

  1. Redbook on Creating Applications in IBM Bluemix Using the Microservices Approach
  2. Konrad Ohms, “Best practices for developing and organizing multi-stage app deployments in Bluemix”, written December 10, 2015, https://www.ibm.com/blogs/bluemix/2015/12/best-practices-for-multistage-app-deployments-in-bluemix/
  3. “Top 10 Best Practices for Jenkins Pipeline Plugin”, written 27 Jun 2016, retrieved 9-27-2017, https://www.cloudbees.com/blog/top-10-best-practices-jenkins-pipeline-plugin

 

 

Advertisements

Is Blockchain Technology the perfect for Supply Chain Management challenges?

Many businesses understand that being able to manage their supply chain is vital to their success. Nevertheless many of these companies still struggle with their supply chain due to lack of visibly, the difficulty of obtaining accurate data in real-time, and the logistical problems associated of getting the right inventory to where it needs to be when it needs to be there.

To attempt to solve some of these challenges, many innovators are turning to blockchain technology with its smart contracts, immutable ledger and greater transparency. As Chris O’Connor stated in his recent article on “Driving industry advancements with Watson IoT and Blockchain”

“Traditionally, supply chain transactions are completed manually, creating delays and a higher risk for recording error, which can cause differences between what was recorded and what was loaded. By digitizing this process using blockchain and Watson IoT, the relevant information is captured directly from the sensors placed on the trucks, and entered onto the blockchain, creating a single, shared repository that all authorized participants can access and which can only be altered with consensus from all parties.” [1] – Chris Connor

Blockchain technology is all about providing an immutable distributed public general ledger where transactions are recorded and tracked. This makes it much easier to get real-time updates and to see what’s happening every step of the way.

In another article from the Harvard Business Review, Michael J. Casey and Pindar Wong observed that blockchain — an online globally distributed general ledger that keeps track of transactions via online “smart contracts” — will produce “dynamic demand chains in place of rigid supply chains, resulting in more efficient resource use for all.[2]”

As one of my Medical Device Supply Chain colleges observed recently “Pinpointing issues can be difficult when you have multiple suppliers across multiple states and countries, it can be hard to keep track of everything.”

With blockchain, the members of the network can see what’s going on as it happens. The inherit transparency of blockchain helps keep all those involved accountable for their end of the bargain. It’s a great way to get the whole picture, as well as drill down to individual aspects of the supply chain.

Smart Contracts and Using Blockchain Supply Management

Another reason why blockchain technology is so useful in supply chain management scenarios has to do with the smart contracts. With smart contacts, all the interested parties can see the terms of the agreement that enforce themselves.

To move forward with accepting changes to the smart contract, certain expectations have to be met. When the world state meet those expectations, the contracts can be fulfilled

Shared ledger consists of two data structures

The distributed replication of IBM Blockchain enables the business partners to access and supply IoT data without the need for central control and management. All business partners can verify each transaction, preventing disputes and ensuring each partner is held accountable for their roles in the overall transaction.

Leveraging blockchain for your IoT data opens up new ways of automating business processes among your partners without setting up an expensive centralized IT infrastructure.

Finally as the use of internet of things (IoT) devices and sensors becomes more and more commonplace, tracking the location and status (e.g., fitness, freshness, viability) is becoming easier.   With its new blockchain integration, the IBM Watson IoT platform is enabling IoT devices to send data from these “things” to a private blockchain network where the transaction can be added to the shared ledger with tamper-resistant records.

IoT-WatsonIoT-Blockchain-BusinessNetwork

In an upcoming post, I will dive deeper into how define, build and deploy blockchain applications using a combination of Blockchain, IBM Watson and IoT devices to solve some real world supply chain challenges.

For additional reading check out the following:

  1. Michael J. Casey and Pindar Wong, Global Supply Chains Are About to Get Better, Thanks to Blockchain, https://hbr.org/2017/03/global-supply-chains-are-about-to-get-better-thanks-to-blockchain
  2. Chris O’Connor, “Driving industry advancements with Watson IoT and Blockchain,” written July 19, 2017, https://www.ibm.com/blogs/internet-of-things/iot-blockchain-industry-advancements/
  3. Joe McKendrick, Why Blockchain May Be Your Next Supply Chain, retrieved 10-11-2017, https://www.forbes.com/sites/joemckendrick/2017/04/21/why-blockchain-may-be-your-next-supply-chain/#7162bac713cf

Walmart and 9 Food Giants Team Up on IBM Blockchain Plans

While blockchain technology is fairly, IBM has already helped several customers achieve success. Many financial organizations have already launched their own blockchain initiatives.

For instance, the diamond insurer, Everledger, has used blockchain to digitally store the provenance of diamonds to minimize and prevent everything from fraud to conflict stones. There are over 1.2 million diamonds on their blockchain today, which may save insurers up to $50B annually. ([1]).  However there are several areas where the use of blockchain are just now being explored.

For example, IBM partnered with Walmart, Nestle, Unilever and other food giants to trace food contamination with blockchain and thereby improve food safety.

Full coverage