I'm having some issues with Counters. I have a si...
# support
b
I'm having some issues with Counters. I have a simple custom counter coming from my application. When I put it on the dashboard. I see nothing but zeros and the tags I put on the metrics. I'm using increase and sum by tags. I'm simply looking for the number of requests coming in over a given period
I have no clue how to write the clickhouse query or I would try that
s
It would show zero if there is no increase. Is the application increasing the counter values?
b
yes it is, there is a hardcoded 1L that is being added
s
When is it incremented?
b
when the job is sent out to AWS
s
please help me understand in frequency and nature of the process that increments the count
b
The process runs once a minute and sends out multiple jobs at a time. This counter has 3 attributes on it and I'm using one of them to filter on
Even when I don't put the group by on the dashboard I still get a 0
when I know for a fact it should not be
s
The process runs once a minute
does the process restart every minute?
b
It doesn't
it is a long lived java process that also runs other things. This is just one part of it
the actual java counter object is created as a static and reused
I'm running on the latest version also if that helps
using k8s
using the ingestion dashboard I'm able to see that I've gotten about 8k samples
s
so long lived java process is emitting counter metrics but the increase is showing zero?
b
correct
s
What goes into the attribute values? Is it every chaning values or known values?
b
One is a changing value the other are known
one is a company grouping key the other is a status
s
Ok, does it create unique series each time, and how often does it repeat the count?
b
its a known value that can repeat every couple days
s
So if you take specific series, how often does it increment?
b
its a unique identifier based on a hash
s
that's the issue, if the counter starts with 1 as the first values and doesn't change for long time then it doesn't show any values. For such scenarios, Use delta temporality or record as events and count.
b
thats very unintuitive
I would expect the coutner to increase when I do a .add
instead of me having to do the counter myself
and I'm doing it based on the opentelemetry java counter examples
s
set the env
OTEL_EXPORTER_OTLP_METRICS_TEMPORALITY_PREFERENCE=delta
and try again
b
on which exporter
s
that's an application level env
b
gotcha
yes that seems to have worked
for future people the java properties directive in my file was
Copy code
otel.exporter.otlp.metrics.temporality.preference=delta
Now I am seeing no data in the dashboard
even though I have confirmed its being sent out
is there a setting inside of signoz I need to make
Any help? on this. I have data in clickhouse but signoz won't display it