• Forums
    • Public Forums
      • Community Connect
      • Dynatrace
        • Dynatrace Open Q&A
      • Application Monitoring & UEM
        • AppMon & UEM Open Q&A
      • Network Application Monitoring
        • NAM Open Q&A
  • Home /
  • Public Forums /
  • Network Application Monitoring /
  • NAM Open Q&A /
avatar image
Question by wim d. · Feb 21, 2014 at 10:23 AM ·

Extended regex for matching a word

How can I code the dcrum regex to match a certain string in the url and not get garbled ADS output?

The url is this:

https://dreambaby2.dreambaby.be/wps/myportal/nl/aanbieding/gratis-pampers...ect

As we Belgians are multiple-linguistic (smile) this url can have multiple appearances:

in Dutch:

https://dreambaby2.dreambaby.be/wps/myportal/nl/aanbieding/gratis-pampers...ect

in French:

https://dreambaby2.dreambaby.be/wps/myportal/fr/offre/pampers-gratuit...ect

Also, depending on being logged-in or not, 'myportal' can also be 'portal'

I coded the dcrum regex as:

(https?://dreambaby2.dreambaby.be/wps/(portal|myportal)/(nl|fr)/(aanbieding|offre)).*

This seems to fit all possible urls for this case, but the ADS output is not what I expect, due to the use of brackets:

https://dreambaby2.dreambaby.be/wps/myportal/nl/aanbiedingmyportalnlaanbieding

I would expect it to be:

https://dreambaby2.dreambaby.be/wps/myportal/nl/aanbieding

Of course I could code all languages separately, but as there are multiple urls to process the list can grow quite long.

Wim.

Comment

People who like this

0 Show 0
10 |2000000 characters needed characters left characters exceeded
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Toggle Comment visibility. Current Visibility: Viewable by all users

Up to 10 attachments (including images) can be used with a maximum of 50.0 MiB each and 250.0 MiB total.

3 Replies

  • Sort: 
  • Most voted
  • Newest
  • Oldest
avatar image

Answer by Pawel B. · Feb 24, 2014 at 07:03 AM

Please remember that you can still use Page Titles or other HTML tags to name your transactions. Than, url becomes just a parameter. You can also build your transactions in the report server where you can add operation (url) string rules to transaction definition.

Comment

People who like this

0 Show 0 · Share
10 |2000000 characters needed characters left characters exceeded
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Toggle Comment visibility. Current Visibility: Viewable by all users

Up to 10 attachments (including images) can be used with a maximum of 50.0 MiB each and 250.0 MiB total.

avatar image

Answer by wim d. · Feb 24, 2014 at 06:21 AM

OK.

For the time being I will code every URL separately (the last part also has 2 language equivalents and this is the main cause for bad matches).

Is there any chance that this will change in a future release?

Wim.

Comment

People who like this

0 Show 1 · Share
10 |2000000 characters needed characters left characters exceeded
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Toggle Comment visibility. Current Visibility: Viewable by all users

Up to 10 attachments (including images) can be used with a maximum of 50.0 MiB each and 250.0 MiB total.

avatar image Adam P. ♦♦ · Feb 24, 2014 at 08:02 AM 0
Share

Wim,

It looks to be possible anyway.

Try:

(https://dreambaby2.dreambaby.be/wps/(?:myportal|portal)/(?:fr|nl)/aanbieding)

"?:" mans that the content of this bracket contains alternatives of words.

It's will not be testable in RUM Console but will work when saved and sent to the AMD. Applications.xml file fill recognize it and let RTM process use it.

Sorry for the confusion.

avatar image

Answer by Adam P. · Feb 21, 2014 at 03:24 PM

For the example only with "portal", "myportal", "fr" and "nl" variations it would be:

(https://dreambaby2.dreambaby.be/wps/[myportal]*/[frnl]{2}/aanbieding)

As round brackets in DCRUM are used for selecting the part of string that should be reported so there might be a problem to use it for aternatives like "(one|two)". We're lucky that "myportal" overlaps "portal" ...

I will make sure what to do if we need to use (myportal|noportal) alternative and let you know.

Comment

People who like this

0 Show 2 · Share
10 |2000000 characters needed characters left characters exceeded
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Toggle Comment visibility. Current Visibility: Viewable by all users

Up to 10 attachments (including images) can be used with a maximum of 50.0 MiB each and 250.0 MiB total.

avatar image wim d. · Feb 24, 2014 at 03:02 AM 0
Share

Hi Adam,

coding with square brackets does not prevent getting a match for

https://dreambaby2.dreambaby.be/wps/mrtal/fn/aanbieding

which is not what I want.

Wim. 

avatar image Adam P. ♦♦ wim d. · Feb 24, 2014 at 05:04 AM 0
Share

I know, but our regexes does not allow to provide an alternatives of full phrases ...

So either you decide to use:

Definition for "portal", "myportal" and "ymportal"
(https://dreambaby2.dreambaby.be/wps/[my]*portal/[frnl]{2}/aanbieding)

and take a risk to have "ymportal" (is there really such URL?),

or

you provide as many definitions as many "myportal" and "portal" phrases you have:

Definition for "portal"
(https://dreambaby2.dreambaby.be/wps/portal/[frnl]{2}/aanbieding)
Defeinition for "myportal"
(https://dreambaby2.dreambaby.be/wps/myportal/[frnl]{2}/aanbieding)

How to get started

First steps in the forum
Read Community User Guide
Best practices of using forum

NAM 2019 SP5 is available


Check the RHEL support added in the latest NAM service pack.

Learn more

LIVE WEBINAR

"Performance Clinic - Monitoring as a Self Service with Dynatrace"


JANUARY 15, 3:00 PM GMT / 10:00 AM ET

Register here

Follow this Question

Answers Answers and Comments

2 People are following this question.

avatar image avatar image

Forum Tags

esm siebel Dynatrace Managed license nam probe wan citrix dna rest api configuration mq alerting NAM 2018 dashboard dcrumadvisory reports css nam universal decode database mobileapp RUM ads sap nam console scripting nam server sequence transactions nam 2019 upgrade
  • Forums
  • Public Forums
    • Community Connect
    • Dynatrace
      • Dynatrace Open Q&A
    • Application Monitoring & UEM
      • AppMon & UEM Open Q&A
    • Network Application Monitoring
      • NAM Open Q&A