Hi Ferdi, nice to see you are already working on it. If you use a tool like *curl <https://curl.haxx.se/>* you can execute: curl -X OPTIONS http://localhost:8080/mp-metrics-metered/metrics/application/<metric-name>
Replace <metric-name> with the name you set for @Metered. For GET would be: curl -X GET http://localhost:8080/mp-metrics-metered/metrics/application/ <metric-name> *curl* is just a tool, you could use *Postman <https://www.getpostman.com/>* if you like too. The link I added to the ticket is a "Getting Started with MicroProfile Metrics" tutorial / blog post, just to help you understand how it works. So, not specifically related to the task itself. It was more to give you an overview of the specification itself. Feel free to share a branch, or a Working In Progress PR if you would like with more questions. Hope it helps! On Thu, Nov 22, 2018 at 12:53 PM Ferdi <d...@ferdi.id> wrote: > Yeah, Hi Ivan, thanks for the nudge on Twitter, by the way. > > I've got the files and now are trying it. > > Since this is the first issue, I'd use this thread instead for the > questions, is that alright? > > The question: > Where can I find the full output example for the @Metered annotation, > for both GET and OPTIONS? > > I've got this output: > > { > "dailyStatus": { > "oneMinuteRate": 3.333333333333333e-12, > "rate15": { > "alpha": 0.7134952031398099, > "initialized": true, > "interval": 300000000000, > "updates": {}, > "value": 3.333333333333333e-12 > }, > "rate5": { > "alpha": 0.34075936979955623, > "initialized": true, > "interval": 300000000000, > "updates": {}, > "value": 3.333333333333333e-12 > }, > "unit": "minutes", > "fifteenMinuteRate": 3.333333333333333e-12, > "rate1": { > "alpha": 0.07995558537067671, > "initialized": true, > "interval": 300000000000, > "updates": {}, > "value": 3.333333333333333e-12 > }, > "fiveMinuteRate": 3.333333333333333e-12, > "meanRate": 0, > "lastUpdate": { > "andDecrement": 5142428994085380, > "opaque": 5142428994085379, > "andIncrement": 5142428994085379, > "plain": 5142428994085380, > "value": 5142428994085380, > "acquire": 5142428994085380 > }, > "count": 2, > "initNs": 5142119118305163 > } > } > > and a little bit confused since this link > <https://www.tomitribe.com/blog/getting-started-with-microprofile-metrics/> > > only give me: > > "itemsSold":{ > "count":2, > "meanRate":0.06512797383709411, > "oneMinRate":0.02942507589548365, > "fiveMinRate":0.0065021413358446346, > "fifteenMinRate":0.0022037834843897696 > } > > On 11/22/2018 7:57 PM, Ivan Junckes Filho wrote: > > Another thing I forgot to say. During this process of creating the > example > > you might find a bug, I did it creating the @Gauge example. The MP > release > > is still not final, so it might happen. > > > > If you find it, it will be a great way to start fixing a bug. > > > > On Thu, Nov 22, 2018 at 9:42 AM Ivan Junckes Filho < > ivanjunc...@gmail.com> > > wrote: > > > >> Hi Ferdi, I am glad you made it here! > >> > >> I know you would like to fix a bug in TomEE, but I would like to suggest > >> that you start with an example. > >> > >> It will help you navigate the code and learn more about it before going > >> into deeper areas. > >> > >> I created a JIRA ticket for you, it has a lot of information on how you > >> can do your first contribution. > >> https://issues.apache.org/jira/browse/TOMEE-2284 > >> > >> We use github, I also added the links in the ticket. It is just the > >> standard pull request approach. I suggest that you do this: > >> > >> 1 - Submit a PR > >> 2 - Send an email to the list asking someone to review it > >> 3 - If approved it will be merged by a commiter > >> > >> Intellij, maven 3.5 and git are OK. You just need to change to JDK 1.8, > we > >> are working on newer versions but this is still the stable one. > >> > >> Does this task work for you? > >> > >> If you have questions let us know, there are no silly questions, really! > >