Update ServiceNow Discovery and Service Patterns

ServiceNow introduced with London Patch 10 the ability to update the Discovery and Service Mapping patterns directly from the ServiceNow Store.

SNstore

In the store, you can enter Discovery and Service or Patterns and you will find the Discovery and Service Mapping Patterns Product. Here you can see, which is the latest published version, the compatibility information and release details.

This HI Service KB Article describes the install process.

You can also directly browse to System Applications > All available Applications > All and search there for Discovery. There you can see the status of the application. If you want to install it, you can do it here too, if there is an update available, you would see it also and could perform the install.

DiscoveryApplication

I like this new integration into the application catalog and service to get patterns outside of instance version upgrades.

 

 

ServiceNow Fundamentals free training path

I wrote a post about NowLearning last week. In the meantime Lisa Holenstein, Platform Success Architect from ServiceNow, posted a link on LinkedIn about the free ServiceNow Fundamentals training path on NowLearning.
I want to share this information in this post, as it is not sure, how long this offer will stay available for free.

The regular classroom or virtual course costs 2400€ and includes the training material and a voucher for the ServiceNow Certified Administrator certification.
The free training is good for everyone who does not need the certification, but wants to learn the ServiceNow platform basics.

CompareSNFundamentals

There is also another free learning path, which complements the fundamentals training: Additional ServiceNow Fundamentals Content for System Administrators and Developers

AdditionalCourse

I recommend to use this free training and build up your ServiceNow knowledge.

Have fun while learning!

 

NowLearning with ServiceNow

I am using Nowlearning a lot these days and recommend this warmly to you as a lot content is for free.

ServiceNow introduced its new learning portal NowLearning a in the second half of 2019 and moved with that some training and certification options into a central place. You need to register an account or use your existing ServiceNow account ID to login.

nowlearning

Once you logged in, you can see, your achievements.  nowlearning-loggedin

Browse to your profile (circle with your acronym) to also link you Webassessor account. With that your mainline certifications are also recognized.

nowlearning-profile

After entering your email address and saving it, you certifications should be linked. This can take a while, and I still get an error message after I logged in, but the certifications should be displayed. If not, then contact ServiceNow support.

Below your profile information there is interesting information about what you already accomplished related to training. Click through the available tabs (My Learning Plan, My Badges, My Certifications, My Transcript, My Vouchers) to see your status.

Vouchers are only displayed here, if you attended a training class, which includes a voucher for a certification (i.e. Discovery Fundamentals).

If you scroll down more, then you get the list of available trainings. The trainings are grouped into learning paths, which can contain free content and payed content, but it shows you what you need to know and book to get a badge/certification for this path.

trainigpaths

You can filter the trainings by Role, Level and Product. I am missing a search option, but as this is still relatively new, this be implemented in a future update.
In the screenshot above you can see already, that two of the training paths will have a micro certification included. With Add to plan you can add this path to your learning plan.

When you open one of the learning paths, you can see, how long you probably will need to fulfill this, which trainings and certifications you need, what is mandatory and which badges you get.
The training is also categorized into knowledge levels so you can decide, if you have sufficient knowledge.

learningpath

With Enroll you start the path.

From the free training I can highly recommend the CMDB fundamentals training, as this gives a very good overview of how the CMDB is structured and how it can be filled.

cmdbFundamentals

The training has a lot of videos and knowledge questions, so that you can check if you understood the content.

Training, where you need to book a class (purchase), will show the link Select a class. The free content will be displayed directly and you can see how far you are as it tracks your status.

pathstatus

After completing the course you can rate it.

I hope you will try out this free training and give feedback to ServiceNow to further improve this offer.

 

Event Management – delay alert action rule processing

By default ServiceNow processes the alert action rules directly when the alert is created. This can create false incidents if you already have remediation tasks implemented which fire, when an alert is raised (one example is automatic recovery actions in SCOM).

To avoid that you can create a system property, which will generally delay the process of the alert action rules. With that solution you handle all alerts in the same way and you cannot have exceptions.

How to implement:

  • Enter sys_properties.list in the filter navigator and press Enter.
  • Click the New button.
  • Name the new property evt_mgmt.alert_rule_delay, select Type integer and enter a value in seconds.evt_mgmt.alert_rule_delay
    Here you can see, I have entered 360 for 6 minutes.

Why did I select 6 min? The reason is that the SCOM connector by default checks every 2 min. Most of the SCOM rules run every 5 min. With 6 min delay most of the short outages should not create Incidents.

The result is this:

ActivityLog

You can see that the task is created 6 min after the original alert.

Attention: This system property is tested in the Jakarta release. I cannot guarantee, that it works in other releases or will be replaced by new functionality in newer releases.

Workflow inputs

What is a workflow input?

A workflow input is a string variable, which can be defined within a child workflow and to transfer data from a parent workflow.

When do I need a workflow input?

An input can be necessary, if a value, which was created within the parent workflow, needs to be used within the sub workflow and no existing form field could be used to write that value to.

Workflow inputs are only available in workflows which are not used for Catalog items (using the table Requested Item = sc_req_item). Catalog item workflows use variables defined in the form and do not display the inputs tab in the workflow properties.

Example

As I struggled with the documentation from ServiceNow about these input variables, I wanted share an example how I used an input.

I have two workflows:

  1. Parent: Change Request – System Build
  2. Child: Change Request – System Build Tasks

I have no field in the change request, where the device name is entered separately, therefore I had to extract it from the description.

I have used the scratchpad to store the extracted value.

workflow.scratchpad.devicename=current.short_description.split(‘:’)[1].trim();

Now I have the name of the device in the scratchpad variable devicename of the parent workflow (Change Request – System Build).

As scratchpad variables are only available in the context of the workflow it is running in, I cannot use this variable in the subflow. Now I need to have an input variable in the subflow.

I checkout the subflow (Change Request – System Build Tasks), went to Properties > Edit Inputs and created this input:
wf_input

When I now open the subflow activity in the parent workflow (where I call the subflow), then the devicename_task field is shown.

call_subflow

I give the value from the scratchpad variable to this input variable of the subflow by entering ${workflow.scratchpad.devicename}.

Within the subflow I then can get the value of the input variable with this command:
workflow.inputs.u_devicename_task
(Attention! it is the column name, I need to use!)

That’s it.

Here is also a good summary about variables in a workflow.

 

Workflow – Check Blackout Conflict

During our Change Management implementation in ServiceNow we realized that we need to change the Change Request – Normal workflow to check if the change is scheduled during Blackout. If that is the case, we wanted to have one additional approval.

As there was no default option to check for the Blackout conflict, we used this script to get a ‘yes’ or ‘no’ answer within the IF activity.

var count = new GlideAggregate('conflict');
count.addQuery('type','blackout');
count.addQuery('change.sys_id',current.sys_id);
count.addAggregate('COUNT');
count.query();
var conflicts = 0;
if(count.next())
conflicts = count.getAggregate('COUNT');

answer = ifScript();

function ifScript() {
if (conflicts>0) {
return (‘yes’);
}
else
{
return (‘no’);
}
}