How should node.js applications deployed to Weblogic be handled by Service Mapping?

jimzeigler
Kilo Contributor

I recently discovered a clustered Node.js (server side javascript) application in the Apache server config file for our web authentication service (which uses Oracle's  Access Manager, Identity Manager, and Unified Directory). The Node.js application provides a "Forgot your password" UI for updating your password in the ldap database. The Apache  config file treats it as a regular Weblogic cluster but it ends up as a Generic Application when it fails classification. I was thinking I should enhance the classification in the Weblogic Pattern to allow Node.js applications and add a new connection section but I wanted to get some feedback from the community before launching into it..

Questions:

  • Is ServiceNow planning to support Service mapping of Node.js applications in London or Madrid?
  • Is there any good documentation on using Node.js within application servers?
  • Are there any standards for Node.js configuration?
  • What pattern enhancements are needed to support Node.js applications?

Do Node.js apps:

    • connect to Databases?
    • call other types of applications?
    • have config files that we should parse and track?
1 REPLY 1

ek91
Kilo Contributor

We are having similar issues. 

I am struggling with decision where in the CMDB discovered Node.js microservices should be placed, from the architectural point of view - any suggestions would be more than welcome.

Looking at the latest patch of the developer instance, it doesn't look like it would be "supported" in London. 

Some examples of what I have used in our environment (currently as a connection section from the Apache on Unix pattern, but will eventually transform into application pattern dedicated to NodeJS - possibly similar approach to .NET Application pattern in cmdb_ci_appl_dot_net):

We expect certain services to be using PM2 runtime for NodeJS, so I will look for this process:

ps awwxo pid,ppid,command | grep pm2

example output:

1864 1 PM2 v2.10.1

based on the output, I confirm if there are any node process:

ps awwxo pid,ppid,command | grep $pid_of_PM2

example output:

24150 1864 node /srv/app/xxx/server.js
24155 1864 node /srv/app/xxx/server.js
24158 1864 node /srv/app/xxx/server.js

we can see this revolves around PID/PPID of 1864, based on which I look for its environment variables:

sudo cat /proc/$pid_of_pm2/environ | tr '\0' '\n'

The output of above has a lot of details that might be helpful.

Regarding the config files - you could look around directories based on the output of these examples:

whereis -l pm2 | grep pm2
whereis -l node | grep node

This could have connections to endless types of other solutions, which can vary based on the purpose of the node app: IIS, loadbalancers, logstash (Elastic stack) if NodeJS application is used for traffic filtering/routing.