How to SUM personal composite metrics in APPOPTICS?

Hi All,

I've created 3 personal composite metrics in APPOPTICS, but I want SUM these 3 personal composite metrics to show in a Big Number Graph, but when I applied my new SUM composite metric appear in the graph this message: "There is no data available at this time interval".

Could someone can help me here?

I'm a noob here in APPOPTICS.

Follow the Details at below:

SUM Composite metric:

sum([
s("composite_truevue-prod-enterprise01.error_rate",{}),
s("composite_truevue-prod-report01.error_rate",{}),
s("composite_truevue-prod-report02.error_rate",{})])

Personal Composite metrics:

composite_truevue-prod-enterprise01.error_rate:

scale(
    divide([
        zero_fill(sum(s("trace.service.transaction.errors", {"service": "truevue-prod-enterprise01"}, {"period":"60"}))),
        sum(s("trace.service.transaction.requests", {"service": "truevue-prod-enterprise01"}))
    ]),
    {factor:"100"}
)

composite_truevue-prod-report01.error_rate:

scale(
    divide([
        zero_fill(sum(s("trace.service.transaction.errors", {"service": "truevue-prod-report01"}, {"period":"60"}))),
        sum(s("trace.service.transaction.requests", {"service": "truevue-prod-report01"}))
    ]),
    {factor:"100"}
)
composite_truevue-prod-report02.error_rate:
scale(
    divide([
        zero_fill(sum(s("trace.service.transaction.errors", {"service": "truevue-prod-report02"}, {"period":"60"}))),
        sum(s("trace.service.transaction.requests", {"service": "truevue-prod-report02"}))
    ]),
    {factor:"100"}
)

 Thx in advance, regards.

  • Hi,

    The answer for your question is simple (unfortunately) - composite metrics cannot be nested. To achieve currently what you need would require creation of the composite metric like this:

    sum([
    scale(
        divide([
            zero_fill(sum(s("trace.service.transaction.errors", {"service": "truevue-prod-enterprise01"}, {"period":"60"}))),
            sum(s("trace.service.transaction.requests", {"service": "truevue-prod-enterprise01"}))
        ]),
        {factor:"100"}
    ),
    scale(
        divide([
            zero_fill(sum(s("trace.service.transaction.errors", {"service": "truevue-prod-report01"}, {"period":"60"}))),
            sum(s("trace.service.transaction.requests", {"service": "truevue-prod-report01"}))
        ]),
        {factor:"100"}
    ),
    scale(
        divide([
            zero_fill(sum(s("trace.service.transaction.errors", {"service": "truevue-prod-report02"}, {"period":"60"}))),
            sum(s("trace.service.transaction.requests", {"service": "truevue-prod-report02"}))
        ]),
        {factor:"100"}
    )])
    I hope that will help.
  • Hi, 

    It's helped a lot!

    Many thanks, it's solved my problem here.