Connecting to my own Hyperledger Fabric instance - ibp-vscode-extension

I am new to IBM Blockchain Platform VSCode Extension and using IBM Blockchain Platform Extension Version: 0.3.2 and Visual Studio Code version: 1.32.3.
In this extension there is a feature "Connecting to your own Hyperledger Fabric instance". I tried this by using the command "Add Gateway" in VSCode. I have provided connection profile, cert and private key. It successfully connected and showing only channel name under "FABRIC GATEWAYS". No peers are showing. But now my question is, how to install and initiate smart contract using the extension? Nothing is showing under "LOCAL FABRIC OPS" which was showing when I connect to pre-configured local fabric instance. Please help me to understand.

It's not possible to install chaincode or instantiate chaincode on an external network (ie one that isn't managed by the vscode plugin itself), although as you have already discovered you can connect a gateway to it to test your running chaincode. So you can perform an install/instantiate on your external network then use the plugin to interact with it.
If the network provided by the plugin isn't suitable for you to use for your local testing then I would suggest raising an issue at
https://github.com/IBM-Blockchain/blockchain-vscode-extension/issues
describing why the in built network isn't suitable and what sort of inbuilt network would be suitable.

Related

How can I use a hyperledger fabric network in IBM Blockchain Platform?

I am trying to get a locally hosted Hyperledger Fabric network (the test-network from Fabric itself) connected via the vscode plugin "IBM Blockchain Platform". I have been able to extract the wallet (added under "wallet" in vscode) and connection.json (added under "gateway" in vscode), but I still need to add the network itself (under "environments").
I can click the plus icon to add an environment, but I need to provide "node JSON files" to connect to it. I don't know what this is, and I can't find information on which format this is.
For the wallet and the gateway I can export them from the plugin to see what the desired format is, but for environments this is not possible.
Can someone tell me what format these "node JSON files" need to be in?
The node json format information can be accessed through the extension README, here

ibm cloud for integration Telemetry Enable

I am using ibm cloud pak for integration version 3.0.0.
I deployed an MQ instance into my Openshift Cluster.
when I check my new created instance information it says: "telemetry not supported"
But I want my instance to support MQTT protocol.
is there anything I am missing? what can I do? thanks
I think it's not installed by default, which means that to install it you will need to customise the container.
You will need to clone the IBM MQ Container - https://github.com/ibm-messaging/mq-container
and ask for MQTT to be installed by changing the line
export genmqpkg_incmqxr=0
to
export genmqpkg_incmqxr=1
in the file install-mq.sh. Then follow the build instructions to create the container image.

How do I deploy .BNA file on IBM cloud blockchain 2.0 resource?

I am trying to set up a rest API that is connected to an IBM blockchain resource. I have developed a model file, logic file, and acl file.
I have it all packed up in a nice tidy .BNA, and now i would like to deploy it to a channel of my IBM cloud blockchain 2.0 resource, running on a free kubernetes cluster.
Everything on the cloud blockchain resource is set up perfectly, and all orgs, peers, orderers, msps, and CAs are set up correctly. The channel is set up properly, and has nodes and an MSP connected. I have all the admin cred .jsons
The channel only accepts smart contract files, so I tried repackaging the files (logic.js, permissions.acl, and model.cto) by putting them in a contract folder, and using the IBM Blockchain vsCode plugin to package them as a smart contract, but trying to install on the IBM cloud crashes the browser.
I am thinking maybe I have to remote connect into the IBM kubernetes cluster that the blockchain resource is sitting on, and use the hyperledger composer CLI to install the .BNA
Seems very unintuitive, but thats the one thing I can think to try while I wait for this question to get answered.
I expected to just be able to install the .BNA as a smart contract, like a .cds.
In August 2018, IBM announced that we are no longer investing in Hyperledger Composer, and instead focusing 100% on Hyperledger Fabric. As a result, IBM Blockchain Platform v2.0 will not provide any support or tooling around Hyperledger Composer.
The good news is that we've significantly invested in the programming model (APIs and SDKs) used to write smart contracts and applications in Fabric v1.4, and we've also released some great developer tooling in the form of an extension for Visual Studio Code: https://marketplace.visualstudio.com/items?itemName=IBMBlockchain.ibm-blockchain-platform
The extension offers an extensive set of capabilities for writing smart contracts - with tooling for creating new projects, packaging them, deploying them, testing them, and debugging them - all from within one of the most popular IDEs around.
To get started - just install Visual Studio Code, and then the IBM Blockchain Platform extension (there are a few prereqs, check the README first). After that, you will be presented with a homepage that links you to tutorials and samples to help you get started.
For the first one, I can't really suggest a solution. At best, try installing and using the composer CLI and the latest version to make the bna file. Composer playground isn't maintained as well imo.
For the second part, in the connection.json file and docker there will be a bunch of IP addresses that look something like localhost:7040 and so on for the CA, orderer, org and peer. You will need to replace these using the IPs given by IBM. The examples on github that demonstrate integration are to do with nodejs SDK and not composer, however you can refer to https://github.com/IBM-Blockchain/vehicle-manufacture to get the idea.
This link is the only I could find for Hyperledger Composer and IBM platform.
(comments were getting too long to fit)

Why does IBM API Connect run differently in Bluemix than locally?

I just set up my local environment to use IBM API Connect and it gives me "extra options" to make the database. Now i'm using IBM API Connect inside IBM Bluemix and it doesn't have those "extra options" :/ I'd like to use it from IBM Bluemix to start migrating to the cloud, thanks in advance.
(I said this in a comment, but it should be an answer...)
The APIC Designer, which you run locally, helps define your models and connections, you then deploy that to Bluemix. You don't edit it on Bluemix itself.
The Local Developer toolkit gets installed on your computer for modeling and creating the api's through Strongloop or Kitura. After you have created your api's to run and publish them, bluemix publix cloud is used where you get a free developer portal and Node.js runtime environment for running your applications/micro-services.

Can Bluemix environment be replicated on developer laptops?

Can Bluemix environment with Liberty be replicated on developer laptops for offline development? Will I be able to run Bluemix local with Openstack on a quad core i5?
You can run Cloud Foundry in a VM on your laptop using bosh-lite. You could also install the open source Liberty buildpack into this local CF with the buildpack dependencies cached giving you an environment that could work offline.
The Bluemix services will not be available to you though, if you are offline, so the answer really depends on what services you need. You could reasonably set up some kind of local database but many of the services would just be unavailable.
I am not sure what exact your requirement is. IBM Liberty profile can be setup with Eclipse and you can create a server in local to test your java/JEE code. This is very simple, you need to install liberty plugin in Eclipse and create a server. See documentations in IBM web site.
See this url if it helps.. you can integrate BlueMix server to your Ecplise IDE
https://console.ng.bluemix.net/docs/manageapps/eclipsetools/eclipsetools.html