Hello,

I'm been banging my head against this for the past couple of days but no luck. I'm trying to enhance one of our collectors to find events that match a particular regex and for events that match, I want to grab a value and assign it to a CustomerVar value. Here's my custom.js (took out comments):

Collector.prototype.customInit = function() {
return true;
};

Record.prototype.customPreParse = function(e) {
return true;
};

Record.prototype.customParse = function(e) {
this.parseCustomField(e);
return true;
};

Record.prototype.parseCustomField = function(e) {
this.s_RXBufferString.search(/GET\s+.*(\d+));
this.CustomerVar021 = RegExp.$1;
return true;
};


I verified that substring is in s_RXBufferString and the collector is in "custom" Execution mode.

I uploaded the file and looked to make sure the custom.js was deployed in that collector instance but still no luck getting that subexpression plugged into the cv21 value.

Can anyone advise as to what I might be doing wrong? I didn't think I needed to add in a custom map if I was using the long name, but I did have an earlier version of the file where I tried that as well.