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

Introducing the IBM Blockchain Network

 

While many financial institutions have explored, Bitcoin, the most well-established blockchain implementation for more the last couple years, the use of cryptocurrency has proven limited in scope and scalability.

However, Blockchain, the backend technology behind Bitcoin, has shown a lot of promise and several large companies including, IBM, are throwing their weight behind.  Fundamental units of blockchain are the transactions, where two parties exchange information.  The data is subsequently, verified and validated, whereby it is reviewed whether one party owns the respective rights for these transactions.

Blockchain Peer Network - 1

IBM Blockchain is based on Hyperledger Fabric from the Linux Foundation.  Hyperledger, an open source collaborative effort to advance cross-industry blockchain technologies, is hosted by The Linux Foundation®. IBM provides blockchain solutions and services leveraging Hyperledger technologies, including Hyperledger Fabric and Hyperledger Composer. For more see https://www.ibm.com/blockchain/hyperledger.html

IBM is already working on applying blockchain in the finance and logistics industries. It’s now working to use it to help food industry improve traceability by providing the businesses with a shared store of information that they can trust regarding the provenance and destination of ingredients.

To accomplish this, IBM is collaborating with a consortium of food manufacturing and distribution giants including Nestle, Tyson Foods, Dole, McCormick, Walmart and Kroger to identify new uses for blockchain technologies in the supply chain.   For more information checkout the article by Peter Sayer, “IBM wants to make blockchain good enough to eat”,.

In addition, IBM has recently launched an enterprise blockchain platform as part of its range of cloud services. The IBM Blockchain Platform is currently the only fully integrated enterprise-ready blockchain platform designed to accelerate the development, governance, and operation of a multi-institution business network.

The IBM Blockchain Platform is currently the only fully integrated enterprise-ready blockchain platform designed to accelerate the development, governance, and operation of a multi-institution business network.

·  Based on Hyperledger Fabric V1 runtime optimized for enterprise requirements

·  Specialized compute for security, performance and resilience

·  Delivered via the IBM Cloud on a global footprint with 24×7 Integrated Support

·  Full lifecycle tooling to speed activation and management of  your network

 IBM Blockchain Network

Businesses that want to roll their own blockchain can access IBM’s array of developer tools, including the Hyperledger Composer framework for mapping business processes to code.

For more details checkout:

  1. The IBM Blockchain Platform, https://www.ibm.com/blockchain/platform/
  2. Peter Sayer, “IBM wants to make blockchain good enough to eat”, Aug 23rd 2017, retrieved 9-23-2017, http://www.cio.in/news/ibm-wants-make-blockchain-good-enough-eat
  3. IBM Blockchain, http://www.techrepublic.com/article/can-ibm-bring-bitcoins-blockchain-technology-to-mainstream-business/
  4. Dr. Thomas Kaltofen, “5 Points how Blockchain will change our lives in a revolutionary way”, retrieved 9-24-2017, https://ict.swisscom.ch/2017/06/5-points-how-blockchain-will-change-our-lives-in-a-revolutionary-way/

Blockchain Explained

There has been a lot of hype surrounding technologies such as blockchain and cognitive computing. In the case of Blockchain this buzz is well deserved as it has the potential to revolutionize the way business is done on the Internet.
As blockchain strategies gain traction and the technology matures, organizations are becoming increasingly aware of the fundamental way that business transactions will change. However, many people still have a hard time pinning down exactly what it is and how implementing can help businesses be more successful. In this blog, our goal is to provide a brief overview of the Blockchain technology, provide a couple examples of how it has been applied and provide you with several links to learn more information.
So what is the problem with how we do it today
Let’s start of by first framing the problem with most traditional business networks. First and foremost, no business operates in a vacuum. Each participant must keep their own ledger and asset transfers between businesses are slow, inefficient, and costly.
For example, lets’ take the example of a Car Leasing Business Network, as shown below. Without blockchain, this is how the business network would look like:

Note for more details on the entire case study, checkout https://www.altoros.com/blog/the-difference-with-blockchain/

In the traditional scenario  you can clearly see the severe deficit of trust caused by the inefficiencies in record keeping and the ability of back actors to influences outcomes to benefit themselves.

we can already see several concerns such as:

  1. Multiple ledgers – making it difficult to figure out who owns what and when ownership gets transferred.
  2. This is EXPENSIVE and INEFFICIENT – due to duplication by almost every network participant along with adding several layers intermediaries adding costs to the services.
  3. Slow updates – As each participant has its own ledger, real-time synchronization isn’t possible
  4. Error-prone updates – Each participant has to rely on its own business processes to update their ledger and as there is NO central authority this will lead to errors.

Enter Blockchain

Simply put, the Blockchain is a shared version of the truth for anything that can be captured in a digital format (e.g., stocks, music, e-book, contracts, securities, titles, etc.).  The Blockchain relies on a digital ledger that maintains an ever growing list of data records, which are decentralized and tamper proof.

The best know example of this new database technology is Bitcoin. Here are a few of the possible applications of this new technology.

Another great example for the application of blockchain is real estate property around the world:

Imagine the number of legal documents that should be used that way. Instead of passing them to each other, losing track of versions, and not being in sync with the other version, why can’t *all* business documents become shared instead of transferred back and forth? So many types of legal contracts would be ideal for that kind of workflow.You don’t need a blockchain to share documents, but the shared documents analogy is a powerful one.”

William Mougayar, Venture advisor, 4x entrepreneur,
marketer, strategist andblockchain specialist

Now if we take a look at our Car Leading example with blockchain involved, this is how the network would look like

The car leasing network gets some benefits with blockchain:

Shared ledger. The ledger is now an append-only distributed system of record shared across all participants in the business network.

Smart contracts. Smart contracts are business terms embedded in transaction databases and executed with transactions.

Consensus. All participants in the business network agree to network verified transactions.

In addition these benefits, the process has

  1. Shared records but administered in a centralized way
  2. Permissions. Viewing permissions are defined for each participant in the business network to ensure privacy.
  3. Efficiency. Transaction times and data synchronization is reduced from days to near real time. Overhead and intermediary cost reductions.
  4. Reduced risk. Risk of tampering and fraud is reduced with transaction certifications and signatures.

Summary

In the next post we will deep a little deeper into the how Blockchain works. IBM is a recognized leader in making blockchain real for business. We are helping many hundreds of clients on their blockchain journeys. Here are some additional links

References

“What is Blockchain Technology? A Step-by-Step Guide For Beginners”, retrieved 9-16-2017,      https://blockgeeks.com/guides/what-is-blockchain-technology/

#ibm-blockchain

Public vs Private – blockchains advantages and disadvantages

Recently one of my clients asked me my perspective on the advantages of public verses private blockchains.

Blockchain - benefits

This led to an extended discussion on several key topics –

  • Autonomy
  • Transparency
  • Security
  • Availability
  • Transaction speed
  • to name a few.

Afterwards, I did some additional  research and ran across a good blog, by Altabel Group’s Blog,  on the topic that I wanted to share.

Now everyone is talking about bitcoin, blockchains, its impact on the world economy, etc.. We can find lots of articles on the internet telling us when blockchain first appeared, the way blockchain works, its perspectives for the future. In my article I tried to look deeper and analyze different types of blockchains, their advantages and […]

via Differences and advantages of public and private blockchains — Altabel Group’s Blog

#blockchain-cloud-ibm-hyperledger

7 Habits of a Successful Scaled Agile Adoption

Agility is not an initiative, it is a movement and a journey that can transform any organization so that it has the ability to navigate complexity with clarity of purpose and speed to achieve the best outcomes. Like Lean thinking, Agile involves a cultural change that helps to eliminate unnecessary processes and artificial boundaries to help focus our energy on what matters most to our clients.

Last week I delivered several workshops at the 2016 Interconnect conference focused on adopting Agile DevOps practices. While preparing for this conference I had the opportunity re-read book “The 7 Habits of Highly Effective People”, by Stephan R. Covey and was struck by the similarities between the principles in his book and those of found in lean / agile development.

In this book the 7 habits, provided the reader with excellence guidance to better manage themselves and their environment. Required reading when I first began my career these 7 habits, listed below, have already helped millions of people improve their effectiveness and better the quality of their life.

  • Habit 1: Be Proactive
  • Habit 2: Begin with the end in mind
  • Habit 3: Put first things first
  • Habit 4: Think win/win
  • Habit 5: Seek first to understand, then to be understood
  • Habit 6: Synergize
  • Habit 7: Sharpen the saw

Likewise, the 7-Habits for a Successful Scaled Agile Adoption using IBM CLM will provide a set of practices to improve the effectiveness of your agile adoption by assisting you with creating a culture in which the values of sustainable predictable development, individual self-management and rapid product innovation are possible.

For example Habit 2 “Began with the end in Mind”

Scaled Agile Framework (SAFe) focused developing a Vision and Roadmap for the product prior to conducting Release and Sprint Planning (actually they refer to it as PI planning)

7 Habit - Slide 2

These tactics give the agile teams with the opportunity to plot their course at a high-level to assure they’re going in the right direction.

The details of these 7 habits, listed above, have been provided in the following presentation

http://www.slideshare.net/rfeggins/slideshelf

 

Getting started with Node.js and IBM Bluemix – Here is a good intro tutorial

Recently had the opportunity to run through a good Node.js tutorial on IBM Bluemix.

The sample application demonstrates how to build a simple sentiment analysis app using Node.js and a couple modules.  It takes a keyword, or hashtag, connects to Twitter to find matching tweets, and runs those tweets through a “sentiment analysis” module to produce a sentiment score.  ou will learn how to clone project, push changes to your Git repository and quickly deploy the app to Bluemix, see the complete tutorial on IBM Bluemix

You will learn how to clone project, push changes to your Git repository and quickly deploy the app to Bluemix, see the complete tutorial on IBM Bluemix Clone, edit, and deploy an app,

Here is a link to  the IBM Bluemix tutorial.  The instructions had me fork the project to create an on instance and IBM DevOps services automatically added to a git repo hosted on IBM Bluemix as well as connected to an initial deployment pipeline to help me get started.

Bluemix-Sentiment-Analysis-App.png

You can play with an instance of the application running at http://simplesentimentanalysis.mybluemix.net/