Friday, 23 June 2017

IBM Business Process Manager 8.5.7 Cumulative Fix 2017-06 Released


Update to IBM BPM V8.5.7 Cumulative Fix 2017.06 to experience all of the highlights, such as these added abilities and improvements:

IBM BPM on Cloud

• Reduce overhead and downtime for client applications by using the new service accounts for password administration

IBM BPM

• Develop user interfaces more easily
• Get usage metrics by using IBM Cloud Product Insights
• Determine artifact usage in the web IBM Process Designer
• Experience enhanced abilities to discover and integrate services in the web Process Designer

IBM Process Federation Server 

• Import saved searches from federated IBM BPM systems into Process Federation Server


Develop user interfaces more easily

The BPM UI toolkit, which is based on the Salient Process SPARK UI toolkit, is now available with IBM BPM CF2017.06 to help you more easily develop even better user interfaces. This toolkit provides many powerful controls, including charting controls with bidirectional support. Plus, it is fully integrated with the web IBM Process Designer so you can benefit from various functions, such the ability to preview controls in the graphical theme editor.

The BPM UI toolkit is now the default toolkit. It provides equivalent controls to the legacy UI toolkits and includes many new controls. Although the Coaches and Responsive Coaches toolkits are deprecated, coaches that use these toolkits still work. Use the new BPM UI controls for new development and to replace existing coach implementations as required. To become familiar with the controls in the new toolkit, explore the Discover BPM UI sample. For more information, see Controls in the BPM UI toolkit.

Furthermore, for coaching and troubleshooting assistance, IBM BPM now provides guidance as you develop and test your coach-based user interfaces to ensure optimal UI performance. For more information, see Accessing coach performance statistics.

Get usage metrics by using IBM Cloud Product Insights

To get various usage metrics, you can register your IBM BPM instances with Cloud Product Insights. For more information, see Getting server usage metrics by using IBM Cloud Product Insights. For more information about Cloud Product Insights, see Getting started with Product Insights.

Determine artifact usage in the web Process Designer

When you work with an artifact in the web Process Designer, it is useful to know where the artifact is used so that you can see the impact of potential changes that you want to make. For example, before you change a business object in a process application, you can see the processes and services in that process application that use the business object. Use the web Process Designer References feature to view the artifacts in the current process application that use a particular library item and also the artifacts that the library item uses. For more information, see Determining artifact usage.

Experience enhanced abilities to discover and integrate services in the web Process Designer

In the web Process Designer, you can discover and integrate services in an IBM BPM process service flow:
• A new tutorial explains how to integrate an external IBM Blockchain service that is defined by using Hyperledger Composer in a business process as a REST service. For more information, see Invoking a REST API service.
• Drag a service from the library onto a service flow diagram. For more information, see Adding a service from the library.
• IBM Operational Decision Manager business rules. For more information, see Using IBM ODM business rules.

And it's on Fix Central here

Wednesday, 21 June 2017

IBM Redbook - Governing Operational Decisions in an Enterprise Scalable Way

Penned, in part, by two of my immediate colleagues in the IBM Professional Cloud Services here in the UK :-)

This IBM® Redbooks® publication introduces operational decision governance and describes in details how to implement it using the IBM Operational Decision Manager (ODM) platform. ODM allows businesses to automate and manage day to day operational decisions. It provides an integrated repository and management components for line-of-business, subject-matter experts to directly participate in the definition and governance of rules-based, decision logic, organized in decision services. Governance of changes to decision services is of particular importance and value.

This book describes how organizations can choose between the built-in ODM decision governance framework or a custom governance based on manually managed branches. Related topics such as access control, permissions and user management are covered and give a full view on decision service governance. You will find this book valuable if you are using or considering the usage of an operational decision management system in your organization, either with ODM on-premises or ODM on Cloud offerings.

This book was written to help assist the following target audience in applying Decision Management technology successfully: IT Project Managers, need to understand how Decision Governance differs from IT Governance and how ODM straddles both worlds to facilitate agile change.

IT Technical Architects, need to understand how to architect ODM to sit inside both the IT and business worlds.
Business Analyst, need to understand the processes for changing business policies using ODM Decision Center.
Business Rule Development Team, need to understand the best way to structure rule projects for scalability and maintainability.


Table of contents

Chapter 1. Introduction
Chapter 2. Decision governance for project managers
Chapter 3. Roles and responsibilities in governing decisions
Chapter 4. Securing Decision Center 
Chapter 5. Designing decision services
Chapter 6. Processes
Chapter 7. Decision Governance Framework
Chapter 8. Deployment
Chapter 9. ODM DevOps
Chapter 10. ODM on Cloud
Chapter 11. Branching and merging
Chapter 12. Conclusion
Appendix A. Acronyms

Monday, 19 June 2017

NullPointerException seen when using BPMConfig.sh to create a second IBM BPM Deployment Environment

I saw this earlier whilst attempting to create a second Deployment Environment, of type Process Server, within an existing BPM Advanced 8.5.7 cell, which already had a Process Centre Deployment Environment therein: -

/opt/ibm/WebSphere/AppServer/bin/BPMConfig.sh -create -de /mnt/ResponseFiles/Advanced-PS-ThreeClusters-DB2.properties

Logging to file /opt/ibm/WebSphere/AppServer/logs/config/BPMConfig_20170619-153221.log.
The 'BPMConfig.sh -create -de /mnt/ResponseFiles/Advanced-PS-ThreeClusters-DB2.properties' command failed. For more information, see the log file /opt/ibm/WebSphere/AppServer/logs/config/BPMConfig_20170619-153221.log.

I checked the logs: -

cat /opt/ibm/WebSphere/AppServer/logs/config/BPMConfig_20170619-153221.log

[19/06/17 15:39:01:391 BST] 00000001 WccmHelper    < com.ibm.bpm.config.util.ws.WccmHelper getBPMCellConfigExtension RETURN null
[19/06/17 15:39:01:391 BST] 00000001 BPMConfig     E com.ibm.bpm.config.BPMConfig main <Null Message>
                                 java.lang.NullPointerException
at com.ibm.bpm.config.BPMConfig.checkCellScopedDB(BPMConfig.java:1097)
at com.ibm.bpm.config.BPMConfig.configureDeploymentEnvironment(BPMConfig.java:641)


cat /opt/ibm/WebSphere/AppServer/logs/config/ffdc_20170619-153853/ffdc.2985516112090437880.txt 

[19/06/17 15:39:01:404 BST]     FFDC Exception:java.lang.NullPointerException SourceId:com.ibm.bpm.config.BPMConfig.main ProbeId:202 Reporter:java.lang.Class@5f390df3
java.lang.NullPointerException
at com.ibm.bpm.config.BPMConfig.checkCellScopedDB(BPMConfig.java:1097)
at com.ibm.bpm.config.BPMConfig.configureDeploymentEnvironment(BPMConfig.java:641)
at com.ibm.bpm.config.BPMConfig$Actions.createDe(BPMConfig.java:4437)

This led me to check the properties file - - within which I had: -

bpm.cell.name=PSCell1

whereas it should've been: -

bpm.cell.name=PSCell1

because I'm adding a second DE to an existing cell, with its profiles, Deployment Manager and Nodes.

Once I changed it ….

IBM BPM and DB2 and Permissions and Users and So On and So Forth :-)

I've seen this exception: -

com.ibm.db2.jcc.am.SqlSyntaxErrorException: com.ibm.db2.jcc.am.SqlSyntaxErrorException: DB2 SQL Error: SQLCODE=-204, SQLSTATE=42704, SQLERRMC=DB2USER1.LSW_SYSTEM_SCHEMA, DRIVER=4.18.60

before, as per these posts: -



However, this time it's subtly different.

gives us an SQL exception code, which DB2 can debug for us: -

db2 ? SQL0204

which returns: -

SQL0204N  "<name>" is an undefined name.

Note that the exception relates to DB2USER1.LSW_SYSTEM_SCHEMA whereas we have: -

db2 list tables for all|grep -i LSW_SYSTEM

LSW_SYSTEM                      BPMDB2USER      T     2017-06-15-10.19.40.987764
LSW_SYSTEM_SCHEMA               BPMDB2USER      T     2017-06-15-10.19.41.033429


This reflects a time when we tried/failed to use a Unix / DB2 user account that was LONGER than eight characters: -

DB2 - Still 8 characters after all these years ...

Looking at the scripts that WAS generates for the database here: -

/opt/IBM/WebSphere/AppServer/profiles/PSDmgr01/dbscripts/

I can see that the schema name has been correctly set by the BPMConfig.sh tool when we rebuilt the Deployment Environment with the new shorter user - db2user1: -

PSCell1.PSCell1De1/DB2/PSBPMDB/createSchema_Advanced.sql:CREATE TABLE db2user1.LSW_SYSTEM (
PSCell1.PSCell1De1/DB2/PSBPMDB/createSchema_Advanced.sql:ALTER TABLE db2user1.LSW_SYSTEM ADD CONSTRAINT "PROPKEY" CHECK (CHARACTER_LENGTH("PROPKEY",CODEUNITS16) <= 256)  ENFORCED ENABLE QUERY OPTIMIZATION
PSCell1.PSCell1De1/DB2/PSBPMDB/createSchema_Advanced.sql:ALTER TABLE db2user1.LSW_SYSTEM ADD CONSTRAINT "PROPVALUE" CHECK (CHARACTER_LENGTH("PROPVALUE",CODEUNITS16) <= 256)  ENFORCED ENABLE QUERY OPTIMIZATION
...
PSCell1.PSCell1De1/DB2/PSBPMDB/createSchema_Advanced.sql:    db2user1.LSW_SYSTEM("PROPKEY",
PSCell1.PSCell1De1/DB2/PSBPMDB/createSchema_Advanced.sql:    db2user1.LSW_SYSTEM_SCHEMA("PROPNAME",


but I'm guessing that we didn't drop/recreate the databases after that change :-(

Now to test …

For the record, I initially thought that this was a permissions error, and started looking at this: -


with: -

SELECT * FROM SYSIBMADM.PRIVILEGES WHERE AUTHID = 'DB2USER1' AND AUTHIDTYPE = 'U'

and: -

db2 grant dbadm on database to user db2user1

Can you say "Red herring" ??

Friday, 16 June 2017

WebSphere Liberty Collectives - Deploying Node.JS using REST

This is definitely a Work-In-Progress …..

Using this as input: -


I started by using a REST client within Chrome ( called Restlet ): -


with this JSON as input: -

{
  "rule":"Node.js Server Rule",
  "hosts":["wlpn.uk.ibm.com"],
  "variables": [
    { "name":"applicationPackage","value":"helloworld-1.0.0.tgz" },
    { "name":"serverName", "value":"Server1" },
    { "name":"clusterName", "value":"Cluster1" },
    { "name":"keystorePassword", "value":"passw0rd" },
    { "name":"applicationDir", "value":"/home/wasadmin/" }
  ]
}


to deploy a Node.JS server via this URL ( POST ): -


I went one step further and used this JSON: -

{
   "host": "wlpn.uk.ibm.com",
   "userDir":"/home/wasadmin/wlpn",
   "serverName":"Server1"
}


to undeploy the same.

I then translated that into command-line commands (!) using Curl: -

curl -d "@deploy.json" -H "Content-Type: application/json" -X POST https://wlpc.uk.ibm.com:9443/ibm/api/collective/v1/deployment/deploy --insecure -i -u wasadmin:passw0rd

and: -

curl -d "@undeploy.json" -H "Content-Type: application/json" -X POST https://wlpc.uk.ibm.com:9443/ibm/api/collective/v1/deployment/undeploy --insecure -i -u wasadmin:passw0rd

deploy.json

{
  "rule":"Node.js Server Rule",
  "hosts":["wlpn.uk.ibm.com"],
  "variables": [
    { "name":"applicationPackage","value":"helloworld-1.0.0.tgz" },
    { "name":"serverName", "value":"Server1" },
    { "name":"clusterName", "value":"Cluster1" },
    { "name":"keystorePassword", "value":"passw0rd" },
    { "name":"applicationDir", "value":"/home/wasadmin/" }
  ]
}


undeploy.json

{
   "host": "wlpn.uk.ibm.com",
   "userDir":"/home/wasadmin/wlpn",
   "serverName":"Server1"
}


Next I need to do the same to start and stop my servers …..

Node.JS - Unknown SSL protocol error

So I've been tinkering with HTTPS servers in Node.JS, and was following this thread: -


which has one create a public/private key pair, and then generate a self-signed certificate.

Having done this, I created a simple server: -

server.js 

var http = require('https');
var fs = require('fs');
 
var options = {
  key: fs.readFileSync('key.pem'),
  cert: fs.readFileSync('cert.pem')
};

var server = http.createServer(options, function(req, res) {
    res.writeHead(200);
    res.write('<p>Hello world!</p>');
    res.end();
});
 
var port = 10001;
server.listen(port, function() {
    console.log('server listening on port ' + port);
});

which I then started: -

node server.js 

server listening on port 10001

However, when I tried to connect to it: -

I got this: -

curl: (35) Unknown SSL protocol error in connection to localhost:-9838

and this: -


from Firefox, and this from Chrome: -


Thankfully, Google came to me aid - AGAIN !!

This post: -


suggested that the problem might be that the key length, of the private key, is wrong.

I checked: -

openssl rsa -in key.pem -text -noout

which reported: -

...
Private-Key: (512 bit)
...

I validated this by checking the certificate: -

openssl x509 -in cert.pem -text -noout

Certificate:
    Data:
        Version: 1 (0x0)
        Serial Number:
            89:66:62:89:72:dd:66:ff
        Signature Algorithm: sha1WithRSAEncryption
        Issuer: C=GB, ST=Hampshire, L=Winchester, O=IBM, OU=Cloud, CN=Dave Hay/emailAddress=david_hay@uk.ibm.com
        Validity
            Not Before: Jun 16 15:14:36 2017 GMT
            Not After : Oct 31 15:14:36 2044 GMT
        Subject: C=GB, ST=Hampshire, L=Winchester, O=IBM, OU=Cloud, CN=Dave Hay/emailAddress=david_hay@uk.ibm.com
        Subject Public Key Info:
            Public Key Algorithm: rsaEncryption
            RSA Public Key: (512 bit)
                Modulus (512 bit):
                    00:d3:fc:99:16:f7:a0:2a:e5:a5:53:09:55:7e:5f:
                    63:f3:d6:98:92:39:56:7c:71:fb:ca:5f:75:af:c4:
                    1f:78:d8:a3:23:1a:ca:e2:d5:f1:a6:43:61:2b:51:
                    e8:39:f5:43:77:4a:59:ae:8c:f5:22:a3:82:51:52:
                    45:12:c2:bf:95
                Exponent: 65537 (0x10001)
    Signature Algorithm: sha1WithRSAEncryption
        c9:76:2b:eb:c6:39:ad:ce:3d:0c:cb:8d:28:26:95:82:68:c4:
        cb:e6:06:fa:62:62:b8:ea:8d:13:47:7f:92:c4:0c:e6:d1:97:
        1c:ec:f1:01:e5:63:be:e5:f4:f4:cd:09:76:3f:55:75:72:2a:
        d2:c3:58:2a:c6:1f:64:50:ae:60


I regenerated the key pair: -

openssl genrsa -out key.pem 2048

and then regenerated the certificate: -

openssl req -new -key key.pem -out csr.pem
openssl x509 -req -days 9999 -in csr.pem -signkey key.pem -out cert.pem
rm csr.pem


and validated the key: -

openssl rsa -in key.pem -text -noout

Private-Key: (2048 bit)
...

and the certificate: -

openssl x509 -in cert.pem -text -noout

Certificate:
    Data:
        Version: 1 (0x0)
        Serial Number:
            aa:3b:0b:19:b8:7c:e5:42
        Signature Algorithm: sha1WithRSAEncryption
        Issuer: C=GB, ST=Hampshire, L=Winchester, O=IBM, OU=Cloud, CN=Dave Hay/emailAddress=david_hay@uk.ibm.com
        Validity
            Not Before: Jun 16 15:28:55 2017 GMT
            Not After : Oct 31 15:28:55 2044 GMT
        Subject: C=GB, ST=Hampshire, L=Winchester, O=IBM, OU=Cloud, CN=Dave Hay/emailAddress=david_hay@uk.ibm.com
        Subject Public Key Info:
            Public Key Algorithm: rsaEncryption
            RSA Public Key: (2048 bit)
                Modulus (2048 bit):

...

I then restarted my server

node server.js

and tested: -


<p>Hello world!</p>

and now Chrome is happy: -


and Firefox is happy: -


Obviously both browsers mark me down for using a self-signed certificate, but I can live with that.

I've since turned my Node.JS server into a Node module, and deployed it to WebSphere Liberty Profile and the IBM Node.JS runtime, as part of an IBM API Connect test ...