Well it was not a big issue bit something to take care. The pr - not yet
merged - is way more impacting users and kind of justifies to not use MP
today :(.

Le mar. 20 nov. 2018 22:39, César Hernández Mendoza <cesargu...@gmail.com>
a écrit :

> Hi Romain,
>
> Did you test passing accept header or just in the browser which sends json
> > and text as acceptable value so resolution can be not that deterministic
> > using it - but this is the request so all fine ;).
>
>
> Yes, yesterday my test was performed using safari and that was causing the
> behaviour I describe in my previous email.
> Today I build tested again and did some test using curl and the Accept
> header and I didn't find any issue. Thanks for the help.
>
> The last side note is prometheus does not support monotonic=false (small
> > glitch in the spec).
>
> Interesting, It seems this is been fixed for microprofile metrics 2.x
> release [1] [2] as we are speaking.
>
> [1] https://github.com/eclipse/microprofile-metrics/pull/309
> [2] https://github.com/eclipse/microprofile-metrics/issues/290
>
>
> El lun., 19 nov. 2018 a las 23:52, Romain Manni-Bucau (<
> rmannibu...@gmail.com>) escribió:
>
> > Hi César,
> >
> > Did you test passing accept header or just in the browser which sends
> json
> > and text as acceptable value so resolution can be not that deterministic
> > using it - but this is the request so all fine ;).
> >
> > The last side note is prometheus does not support monotonic=false (small
> > glitch in the spec).
> >
> > Le mar. 20 nov. 2018 03:12, César Hernández Mendoza <
> cesargu...@gmail.com>
> > a écrit :
> >
> > > Hi Ivan, nice job with this example.
> > >
> > > I found another potential issue with the metrics in TomEE, If you
> remove
> > > the `monotonic = true` from the @Counted annotation, then the format of
> > the
> > > endpoint: http://localhost:8080/rest-mp-metrics/metrics is no longer
> > > Prometheus but JSON instead.
> > >
> > >
> > > Without `monotonic = true`
> > >
> > >
> > >
> >
> {"application":{"message_counter":0},"vendor":{"startTime":1542679115312},"base":{"classloader.totalLoadedClass.count":8971,"thread.count":39,"classloader.currentLoadedClass.count":8971,"jvm.uptime":103050,"gc.PS
> > >
> > >
> >
> MarkSweep.count":2,"thread.max.count":39,"memory.committedHeap":369098752,"gc.PS
> > >
> > >
> >
> Scavenge.count":7,"cpu.availableProcessors":4,"thread.daemon.count":38,"classloader.totalUnloadedClass.count":8971,"memory.maxHeap":3817865216,"memory.usedHeap":69535960,"gc.PS
> > > MarkSweep.time":141,"gc.PS Scavenge.time":103}}
> > >
> > >
> > >
> > > With `monotonic = true`
> > >
> > > # TYPE application:message_counter counter
> > > application:message_counter 0.0
> > > # TYPE base:classloader_total_loaded_class_count counter
> > > base:classloader_total_loaded_class_count 8839.0
> > > # TYPE base:thread_count counter
> > > base:thread_count 39.0
> > > # TYPE base:classloader_current_loaded_class_count counter
> > > base:classloader_current_loaded_class_count 8847.0
> > > # TYPE base:jvm_uptime_seconds gauge
> > > base:jvm_uptime_seconds 0.006427
> > > # TYPE base:gc_ps_mark_sweep_count counter
> > > base:gc_ps_mark_sweep_count 2.0
> > > # TYPE base:gc_ps_scavenge_count counter
> > > base:gc_ps_scavenge_count 7.0
> > > # TYPE base:memory_committed_heap_bytes gauge
> > > base:memory_committed_heap_bytes 3.70147328E8
> > > # TYPE base:thread_max_count counter
> > > base:thread_max_count 39.0
> > > # TYPE base:cpu_available_processors gauge
> > > base:cpu_available_processors 4.0
> > > # TYPE base:thread_daemon_count counter
> > > base:thread_daemon_count 38.0
> > > # TYPE base:classloader_total_unloaded_class_count counter
> > > base:classloader_total_unloaded_class_count 8847.0
> > > # TYPE base:memory_max_heap_bytes gauge
> > > base:memory_max_heap_bytes 3.817865216E9
> > > # TYPE base:gc_ps_mark_sweep_time_seconds gauge
> > > base:gc_ps_mark_sweep_time_seconds 1.19E-4
> > > # TYPE base:memory_used_heap_bytes gauge
> > > base:memory_used_heap_bytes 6.7481504E7
> > > # TYPE base:gc_ps_scavenge_time_seconds gauge
> > > base:gc_ps_scavenge_time_seconds 1.09E-4
> > > # TYPE vendor:start_time counter
> > > vendor:start_time 1.542679428814E12
> > >
> > >
> > > This is not stated on the MP metrics spec. So I wonder if TomEE should
> > > provide a set of properties to avoid these random behaviors.
> > >
> > >
> > > El lun., 19 nov. 2018 a las 13:51, Ivan Junckes Filho (<
> > > ivanjunc...@gmail.com>) escribió:
> > >
> > > > Hey guys, just to let you know that I created a Microprofile Metrics
> > > > Example under Tomee.
> > > >
> > > > I am still working on that and I will provide more test scenarios.
> > > >
> > > > Here is the PR if you want to review the work so far:
> > > > https://github.com/apache/tomee/pull/203
> > > >
> > > > Feel free to merge if you think this can be done incrementally.
> > > >
> > >
> > >
> > > --
> > > Atentamente:
> > > César Hernández Mendoza.
> > >
> >
>
>
> --
> Atentamente:
> César Hernández Mendoza.
>

Reply via email to