Re: Support for multiple schema implementations in one response

2021-01-11 Thread Ivan Junckes Filho
Thanks guys, I ended up using the same object with one more field.



On Fri, Jan 8, 2021 at 5:53 PM Romain Manni-Bucau 
wrote:

> Hi Ivan,
>
> Sure, openapi schema supports oneOf([1]) - but not all json clients so
> take care.
> Personally I would either propose you to merge the models in one or -
> better - not use multiple shapes even if it is not required.
> The main issue is that doing so you easily break you caller error handling.
> Js guys will workaround it quickly but others can suffer from it.
>
> [1]
> https://github.com/eclipse/microprofile-open-api/blob/793faad902599e9900ac370ce3fbaf7d0bffa6a8/api/src/main/java/org/eclipse/microprofile/openapi/annotations/media/Schema.java#L65
>
> Le ven. 8 janv. 2021 à 21:39, Cesar Hernandez  a
> écrit :
>
>> Hi Ivan,
>>
>> What I recall is that oneOf is not part of Swagger version 2. But I
>> haven't try it yet with the maven plugin you mention.
>>
>> El vie, 8 ene 2021 a las 7:08, Ivan Junckes Filho ()
>> escribió:
>>
>>> Hello guys, I would like to know if there is a way with
>>> geronimo-openapi-plugin to generate the documentation for different classes
>>> in the same status code. I didn't tried different ways, but couldn't make
>>> it work. Any advise on this? Is this supported?
>>>
>>> @APIResponse(
>>> name = "badRequest",
>>> responseCode = "400",
>>> description = "Error.",
>>> content = @Content(
>>> mediaType = APPLICATION_JSON,
>>> schema = @Schema(oneOf = {Error.class, AnotherError.class}))
>>> )
>>>
>>>
>>
>> --
>> Atentamente:
>> César Hernández.
>>
>


Support for multiple schema implementations in one response

2021-01-08 Thread Ivan Junckes Filho
Hello guys, I would like to know if there is a way with
geronimo-openapi-plugin to generate the documentation for different classes
in the same status code. I didn't tried different ways, but couldn't make
it work. Any advise on this? Is this supported?

@APIResponse(
name = "badRequest",
responseCode = "400",
description = "Error.",
content = @Content(
mediaType = APPLICATION_JSON,
schema = @Schema(oneOf = {Error.class, AnotherError.class}))
)


Re: [VOTE] Release geronimo-openapi-1.0.14

2020-11-30 Thread Ivan Junckes Filho
+1 thank you for this Romain

On Mon, Nov 30, 2020 at 7:53 AM Romain Manni-Bucau 
wrote:

> Hi everyone,
>
> Here is the vote for Geronimo OpenAPI 1.0.14.
> Here is the changelog:
>
> 1–4 of 4View in Issue Navigator
> 
> PTKeySummaryAssigneeStatus
> [image: Major] [image: Task] GERONIMO-6786
>  Support @BeanParam
>  Romain Manni-Bucau
> 
> RESOLVED
> [image: Major] [image: Bug] GERONIMO-6787
>  openapi.json should
> land in META-INF/resources by default not META-INF/classes
>  Romain Manni-Bucau
> 
> RESOLVED
> [image: Major] [image: Task] GERONIMO-6788
>  Make JAXRS optional
> for schema processor + support BigDecimal/BigInteger and Object
>  Romain Manni-Bucau
> 
> RESOLVED
> [image: Major] [image: New Feature] GERONIMO-6790
>  Enable to use
> SchemaProcessor without jaxrs
>  Romain Manni-Bucau
> 
> RESOLVED
> 1–4 of 4
>
> Here is the staging repo:
> https://repository.apache.org/content/repositories/orgapachegeronimo-1135/
> Here is the dist area:
> https://dist.apache.org/repos/dist/dev/geronimo/openapi/
> Here is the tag:
> https://gitbox.apache.org/repos/asf?p=geronimo-openapi.git;a=commit;h=ed7112a2fea3c38b1bbe80d7ff534a0af49fa619
> My key is the same than last times.
>
> Please vote:
>
> [ ] +1 release it
> [ ] -1 ${cause}
>
> Vote will be opened for 3 days or until we get 3 +1 bindings.
>
> Romain Manni-Bucau
> @rmannibucau  |  Blog
>  | Old Blog
>  | Github
>  | LinkedIn
>  | Book
> 
>


Re: Metrics issue

2019-08-06 Thread Ivan Junckes Filho
Hi Cesar, I am using a M2 TomEE. but I may have not replaced the
system.properties as I use docker-compose with volumes.

I still couldn't make it work, I also didn't spend enough time on this. I
will do some more tries and let you know  if I fixed it.

On Mon, Aug 5, 2019 at 3:27 PM Cesar Hernandez  wrote:

> Hi Ivan,
>
> Can you share the version of TomEE you were having this issue?
> I want to double-check if was or not fixed on current master but I
> couldn't reproduce the issue.
>
> El lun., 29 jul. 2019 a las 11:16, Ivan Junckes Filho (<
> ivanjunc...@gmail.com>) escribió:
>
>> Ok thanks Romain!
>>
>> On Mon, Jul 29, 2019 at 1:59 PM Romain Manni-Bucau 
>> wrote:
>>
>>> More likely refine them to exclude geronimo metrics common. Think it was
>>> fixed on master though, not sure it got released.
>>>
>>> Le lun. 29 juil. 2019 à 18:07, Ivan Junckes Filho 
>>> a écrit :
>>>
>>>> These are the configs:
>>>> openejb.scan.webapp.container = true
>>>> openejb.scan.webapp.container.includes =
>>>> .*(geronimo|mp-jwt|mp-common|failsafe).*
>>>> openejb.scan.webapp.container.excludes =
>>>>
>>>> Should I remove all of them from the system.properties? Because local I
>>>> don't have it.
>>>>
>>>> On Mon, Jul 29, 2019 at 1:02 PM Romain Manni-Bucau <
>>>> rmannibu...@gmail.com> wrote:
>>>>
>>>>> Hi Ivan
>>>>>
>>>>> Looks like a tomee config issue, common module shouldnt be scanned,
>>>>> can you check your exclusion list?
>>>>>
>>>>> Le lun. 29 juil. 2019 à 17:47, Ivan Junckes Filho <
>>>>> ivanjunc...@gmail.com> a écrit :
>>>>>
>>>>>> Hey guys, there is an interesting issue happening with metrics in
>>>>>> tomee.
>>>>>>
>>>>>> When I can /metrics in the tomee runnning in my localhost wihout
>>>>>> docker I am able to access /metrics endpoint. But in the environment 
>>>>>> that I
>>>>>> use docker to run TomEE I get the issue below on calling /metrics.
>>>>>>
>>>>>> Anybody can help?
>>>>>>
>>>>>> 29-Jul-2019 12:41:56.870 WARNING [https-jsse-nio-8181-exec-7]
>>>>>> org.apache.cxf.jaxrs.model.OperationResourceInfoComparator.compare Both
>>>>>> org.apache.geronimo.microprofile.metrics.jaxrs.CdiMetricsEndpoints#getText
>>>>>> and
>>>>>> org.apache.geronimo.microprofile.metrics.common.jaxrs.MetricsEndpoints#getText
>>>>>> are equal candidates for handling the current request which can lead to
>>>>>> unpredictable results
>>>>>>
>>>>>
>
> --
> Atentamente:
> César Hernández.
>


Re: Metrics issue

2019-07-29 Thread Ivan Junckes Filho
Ok thanks Romain!

On Mon, Jul 29, 2019 at 1:59 PM Romain Manni-Bucau 
wrote:

> More likely refine them to exclude geronimo metrics common. Think it was
> fixed on master though, not sure it got released.
>
> Le lun. 29 juil. 2019 à 18:07, Ivan Junckes Filho 
> a écrit :
>
>> These are the configs:
>> openejb.scan.webapp.container = true
>> openejb.scan.webapp.container.includes =
>> .*(geronimo|mp-jwt|mp-common|failsafe).*
>> openejb.scan.webapp.container.excludes =
>>
>> Should I remove all of them from the system.properties? Because local I
>> don't have it.
>>
>> On Mon, Jul 29, 2019 at 1:02 PM Romain Manni-Bucau 
>> wrote:
>>
>>> Hi Ivan
>>>
>>> Looks like a tomee config issue, common module shouldnt be scanned, can
>>> you check your exclusion list?
>>>
>>> Le lun. 29 juil. 2019 à 17:47, Ivan Junckes Filho 
>>> a écrit :
>>>
>>>> Hey guys, there is an interesting issue happening with metrics in tomee.
>>>>
>>>> When I can /metrics in the tomee runnning in my localhost wihout docker
>>>> I am able to access /metrics endpoint. But in the environment that I use
>>>> docker to run TomEE I get the issue below on calling /metrics.
>>>>
>>>> Anybody can help?
>>>>
>>>> 29-Jul-2019 12:41:56.870 WARNING [https-jsse-nio-8181-exec-7]
>>>> org.apache.cxf.jaxrs.model.OperationResourceInfoComparator.compare Both
>>>> org.apache.geronimo.microprofile.metrics.jaxrs.CdiMetricsEndpoints#getText
>>>> and
>>>> org.apache.geronimo.microprofile.metrics.common.jaxrs.MetricsEndpoints#getText
>>>> are equal candidates for handling the current request which can lead to
>>>> unpredictable results
>>>>
>>>


Re: Metrics issue

2019-07-29 Thread Ivan Junckes Filho
These are the configs:
openejb.scan.webapp.container = true
openejb.scan.webapp.container.includes =
.*(geronimo|mp-jwt|mp-common|failsafe).*
openejb.scan.webapp.container.excludes =

Should I remove all of them from the system.properties? Because local I
don't have it.

On Mon, Jul 29, 2019 at 1:02 PM Romain Manni-Bucau 
wrote:

> Hi Ivan
>
> Looks like a tomee config issue, common module shouldnt be scanned, can
> you check your exclusion list?
>
> Le lun. 29 juil. 2019 à 17:47, Ivan Junckes Filho 
> a écrit :
>
>> Hey guys, there is an interesting issue happening with metrics in tomee.
>>
>> When I can /metrics in the tomee runnning in my localhost wihout docker I
>> am able to access /metrics endpoint. But in the environment that I use
>> docker to run TomEE I get the issue below on calling /metrics.
>>
>> Anybody can help?
>>
>> 29-Jul-2019 12:41:56.870 WARNING [https-jsse-nio-8181-exec-7]
>> org.apache.cxf.jaxrs.model.OperationResourceInfoComparator.compare Both
>> org.apache.geronimo.microprofile.metrics.jaxrs.CdiMetricsEndpoints#getText
>> and
>> org.apache.geronimo.microprofile.metrics.common.jaxrs.MetricsEndpoints#getText
>> are equal candidates for handling the current request which can lead to
>> unpredictable results
>>
>


Metrics issue

2019-07-29 Thread Ivan Junckes Filho
Hey guys, there is an interesting issue happening with metrics in tomee.

When I can /metrics in the tomee runnning in my localhost wihout docker I
am able to access /metrics endpoint. But in the environment that I use
docker to run TomEE I get the issue below on calling /metrics.

Anybody can help?

29-Jul-2019 12:41:56.870 WARNING [https-jsse-nio-8181-exec-7]
org.apache.cxf.jaxrs.model.OperationResourceInfoComparator.compare Both
org.apache.geronimo.microprofile.metrics.jaxrs.CdiMetricsEndpoints#getText
and
org.apache.geronimo.microprofile.metrics.common.jaxrs.MetricsEndpoints#getText
are equal candidates for handling the current request which can lead to
unpredictable results


Re: [VOTE] Release Apache Geronimo OpenAPI 1.0.8

2019-04-29 Thread Ivan Junckes Filho
+1

On Mon, Apr 29, 2019 at 6:57 AM Jean-Baptiste Onofré 
wrote:

> +1 (non binding)
>
> Regards
> JB
>
> On 29/04/2019 09:41, Romain Manni-Bucau wrote:
> > Hi guys,
> >
> > here is the vote for Geronimo OpenAPI 1.0.8. This is mainly for a few
> > fixes/enhancement and to enable CXF to upgrade:
> >
> > Major Improvement GERONIMO-6720
> >  The
> > AnnotationProcessor should be able to deduct the parameter name from
> > JAX-RS annotations
> >  Unassigned
> RESOLVED
> > Major Improvement GERONIMO-6722
> >  The
> > AnnotationProcessor should inject media type instead of response code
> > (when endpoint returns void or Response)
> >  Unassigned
> RESOLVED
> >
> >
> >
> > Tag:
> https://gitbox.apache.org/repos/asf?p=geronimo-openapi.git;a=tag;h=b3ec68380fa2ac81424735e7aa498d679ef27307
> > Staging (including
> > sources):
> https://repository.apache.org/content/repositories/orgapachegeronimo-1102
> > My key is the same than last time
> >
> > Please vote:
> >
> > [ ] +1: let's release it
> > [ ]  -1 ${cause}
> >
> > Vote will be opened as usual for 3 days or until we get 3 +1 (binding).
> >
> > Side note: this is a day with a lot of bank days in France so the
> > closing day can be missed from a few days on my side, feel free to
> > either close it for me or I'll catch up a few days after.
> >
> > Romain Manni-Bucau
> > @rmannibucau  |  Blog
> >  | Old Blog
> >  | Github
> >  | LinkedIn
> >  | Book
> > <
> https://www.packtpub.com/application-development/java-ee-8-high-performance
> >
>
> --
> Jean-Baptiste Onofré
> jbono...@apache.org
> http://blog.nanthrax.net
> Talend - http://www.talend.com
>


Re: OpenTracing Zipkin

2019-04-15 Thread Ivan Junckes Filho
Cool, these are good tips I will try both. I didn't try v1 yet.

On Mon, Apr 15, 2019 at 5:00 PM Romain Manni-Bucau 
wrote:

> Hmm, missed that but did you try using v1 instead of v2 endpoint?
>
> Side note: if it helps you to test move the delay to -1 to not wait the
> interval.
>
> Le lun. 15 avr. 2019 à 20:36, Ivan Junckes Filho 
> a écrit :
>
>> Romain I was actually using this docker-compose from JL as reference, but
>> wasn't able to make it work.
>>
>> I will have a look at it again this week, if I have improvement I will
>> let you know.
>>
>> If you have any other tips let me know.
>>
>> Thanks for the reply!
>>
>> On Fri, Apr 12, 2019 at 6:25 PM Romain Manni-Bucau 
>> wrote:
>>
>>> Hi Ivan
>>>
>>> Did you debug ZipkinHttp?
>>>
>>> Depending your server/app config you can need some config like providers
>>> etc. This class is a good start to check what is happening.
>>>
>>> A good config start is
>>>
>>> https://github.com/jeanouii/microprofile-samples/blob/master/docker-compose.yaml
>>> - you can need to inline the yaml depending you docker compose
>>> version/setup, multiline is not always well supported.
>>>
>>>
>>>
>>> Le ven. 12 avr. 2019 à 22:10, Ivan Junckes Filho 
>>> a
>>> écrit :
>>>
>>> > Hey guys I am having a hard time to setup TomEE with OpenTracing 1.0.2
>>> +
>>> > Zipkin.
>>> >
>>> > When I send the payload to the zipkin API
>>> > http://localhost:9411/api/v2/spans, I keep getting back:
>>> > 400 - "Expected a JSON_V2 encoded list, but received: JSON_V1"
>>> >
>>> > My payload is:
>>> > [
>>> >   {
>>> > "annotations": [
>>> >   {
>>> > "timestamp": 1555097175276000,
>>> > "value": "sr"
>>> >   },
>>> >   {
>>> > "timestamp": 1555097175402000,
>>> > "value": "ss"
>>> >   }
>>> > ],
>>> > "binaryAnnotations": [
>>> >   {
>>> > "key": "http.status_code",
>>> > "type": 3,
>>> > "value": 200
>>> >   },
>>> >   {
>>> > "key": "component",
>>> > "type": 6,
>>> > "value": "jaxrs"
>>> >   },
>>> >   {
>>> > "key": "span.kind",
>>> > "type": 6,
>>> > "value": "server"
>>> >   },
>>> >   {
>>> > "key": "http.url",
>>> > "type": 6,
>>> > "value": "http://localhost:8081/number-api/numbers/generate";
>>> >   },
>>> >   {
>>> > "key": "http.method",
>>> > "type": 6,
>>> > "value": "GET"
>>> >   }
>>> > ],
>>> > "duration": 126000,
>>> > "id": 2,
>>> > "kind": "SERVER",
>>> > "localEndpoint": {
>>> >   "ipv4": "127.0.0.1",
>>> >   "port": 8081,
>>> >   "serviceName": "number-api"
>>> > },
>>> > "name":
>>> >
>>> "GET:com.microprofile.samples.services.number.resource.NumberResource.generate",
>>> > "parentId": 1,
>>> > "tags": {
>>> >   "http.status_code": "200",
>>> >   "component": "jaxrs",
>>> >   "http.url": "http://localhost:8081/number-api/numbers/generate";,
>>> >   "http.method": "GET"
>>> > },
>>> > "timestamp": 1555097175276000,
>>> > "traceId": 24
>>> >   }
>>> > ]
>>> >
>>> > Any ideas how to fix this?  Anyone was able to configure zipkin as a
>>> > collector using TomEE?
>>> >
>>>
>>


Re: OpenTracing Zipkin

2019-04-15 Thread Ivan Junckes Filho
Romain I was actually using this docker-compose from JL as reference, but
wasn't able to make it work.

I will have a look at it again this week, if I have improvement I will let
you know.

If you have any other tips let me know.

Thanks for the reply!

On Fri, Apr 12, 2019 at 6:25 PM Romain Manni-Bucau 
wrote:

> Hi Ivan
>
> Did you debug ZipkinHttp?
>
> Depending your server/app config you can need some config like providers
> etc. This class is a good start to check what is happening.
>
> A good config start is
>
> https://github.com/jeanouii/microprofile-samples/blob/master/docker-compose.yaml
> - you can need to inline the yaml depending you docker compose
> version/setup, multiline is not always well supported.
>
>
>
> Le ven. 12 avr. 2019 à 22:10, Ivan Junckes Filho  a
> écrit :
>
> > Hey guys I am having a hard time to setup TomEE with OpenTracing 1.0.2 +
> > Zipkin.
> >
> > When I send the payload to the zipkin API
> > http://localhost:9411/api/v2/spans, I keep getting back:
> > 400 - "Expected a JSON_V2 encoded list, but received: JSON_V1"
> >
> > My payload is:
> > [
> >   {
> > "annotations": [
> >   {
> > "timestamp": 1555097175276000,
> > "value": "sr"
> >   },
> >   {
> > "timestamp": 1555097175402000,
> > "value": "ss"
> >   }
> > ],
> > "binaryAnnotations": [
> >   {
> > "key": "http.status_code",
> > "type": 3,
> > "value": 200
> >   },
> >   {
> > "key": "component",
> > "type": 6,
> > "value": "jaxrs"
> >   },
> >   {
> > "key": "span.kind",
> > "type": 6,
> > "value": "server"
> >   },
> >   {
> > "key": "http.url",
> > "type": 6,
> > "value": "http://localhost:8081/number-api/numbers/generate";
> >   },
> >   {
> > "key": "http.method",
> > "type": 6,
> > "value": "GET"
> >   }
> > ],
> > "duration": 126000,
> > "id": 2,
> > "kind": "SERVER",
> > "localEndpoint": {
> >   "ipv4": "127.0.0.1",
> >   "port": 8081,
> >   "serviceName": "number-api"
> > },
> > "name":
> >
> "GET:com.microprofile.samples.services.number.resource.NumberResource.generate",
> > "parentId": 1,
> > "tags": {
> >   "http.status_code": "200",
> >   "component": "jaxrs",
> >   "http.url": "http://localhost:8081/number-api/numbers/generate";,
> >   "http.method": "GET"
> > },
> > "timestamp": 1555097175276000,
> > "traceId": 24
> >   }
> > ]
> >
> > Any ideas how to fix this?  Anyone was able to configure zipkin as a
> > collector using TomEE?
> >
>


OpenTracing Zipkin

2019-04-12 Thread Ivan Junckes Filho
Hey guys I am having a hard time to setup TomEE with OpenTracing 1.0.2 +
Zipkin.

When I send the payload to the zipkin API http://localhost:9411/api/v2/spans,
I keep getting back:
400 - "Expected a JSON_V2 encoded list, but received: JSON_V1"

My payload is:
[
  {
"annotations": [
  {
"timestamp": 1555097175276000,
"value": "sr"
  },
  {
"timestamp": 1555097175402000,
"value": "ss"
  }
],
"binaryAnnotations": [
  {
"key": "http.status_code",
"type": 3,
"value": 200
  },
  {
"key": "component",
"type": 6,
"value": "jaxrs"
  },
  {
"key": "span.kind",
"type": 6,
"value": "server"
  },
  {
"key": "http.url",
"type": 6,
"value": "http://localhost:8081/number-api/numbers/generate";
  },
  {
"key": "http.method",
"type": 6,
"value": "GET"
  }
],
"duration": 126000,
"id": 2,
"kind": "SERVER",
"localEndpoint": {
  "ipv4": "127.0.0.1",
  "port": 8081,
  "serviceName": "number-api"
},
"name":
"GET:com.microprofile.samples.services.number.resource.NumberResource.generate",
"parentId": 1,
"tags": {
  "http.status_code": "200",
  "component": "jaxrs",
  "http.url": "http://localhost:8081/number-api/numbers/generate";,
  "http.method": "GET"
},
"timestamp": 1555097175276000,
"traceId": 24
  }
]

Any ideas how to fix this?  Anyone was able to configure zipkin as a
collector using TomEE?


Re: [VOTE] Release Geronimo OpenAPI 1.0.7

2019-03-29 Thread Ivan Junckes Filho
+1

On Fri, Mar 29, 2019 at 9:30 AM Daniel Cunha  wrote:

> +1
>
>
> Em sex, 29 de mar de 2019 às 08:31, Raymond Auge 
> escreveu:
>
>> +1
>>
>> - Ray
>>
>> On Fri, Mar 29, 2019, 04:54 Romain Manni-Bucau, 
>> wrote:
>>
>>> Hi guys,
>>>
>>> Here is the vote for our microprofile openapi implementation v 1.0.7.
>>> Here is the changelog:
>>>
>>>
>>> https://issues.apache.org/jira/secure/ReleaseNote.jspa?projectId=10220&version=12345014
>>>
>>> It is mainly bugfixes about tag duplication and some new openrationId
>>> generators.
>>>
>>> Here is the tag:
>>> https://gitbox.apache.org/repos/asf?p=geronimo-openapi.git;a=commit;h=e201583a965723d3417f1cf2f5b034bc70325570
>>> Here is the staging repo (with sources bundles):
>>> https://repository.apache.org/content/repositories/orgapachegeronimo-1100
>>>
>>> Please vote:
>>>
>>>  [ ] +1 let's relese it
>>>  [ ] -1 cancel it because ${reason}
>>>
>>> This vote is open for 3 days as usual or untll it gets its 3
>>> binding +1s.
>>>
>>> Romain Manni-Bucau
>>> @rmannibucau  |  Blog
>>>  | Old Blog
>>>  | Github
>>>  | LinkedIn
>>>  | Book
>>> 
>>>
>>
>
> --
> Daniel "soro" Cunha
> https://twitter.com/dvlc_
>


Re: OpenAPI and tags

2019-03-28 Thread Ivan Junckes Filho
+1

On Thu, Mar 28, 2019 at 12:32 PM Romain Manni-Bucau 
wrote:

> Hi guys,
>
> Seems we were not generating valid openapi.json in some cases when tags
> were set (https://issues.apache.org/jira/browse/GERONIMO-6716)
>
> I propose to run a release tomorrow if there is no objection and pending
> work here
>
> Romain Manni-Bucau
> @rmannibucau  |  Blog
>  | Old Blog
>  | Github
>  | LinkedIn
>  | Book
> 
>


Re: [VOTE] Release Apache Geronimo OpenAPI 1.0.6

2019-02-25 Thread Ivan Junckes Filho
+1

On Mon, Feb 25, 2019 at 5:32 AM Jean-Baptiste Onofré 
wrote:

> +1 (non binding)
>
> Regards
> JB
>
> On 25/02/2019 08:51, Romain Manni-Bucau wrote:
> > Hi guys,
> >
> > Here is the vote for our openapi+microprofile integration impl 1.0.6.
> >
> > Staging repo is available
> > at
> https://repository.apache.org/content/repositories/orgapachegeronimo-1089
> > Sources are
> > here:
> https://repository.apache.org/content/repositories/orgapachegeronimo-1089/org/apache/geronimo/geronimo-openapi/1.0.6/
> > Tag is
> > here:
> https://gitbox.apache.org/repos/asf?p=geronimo-openapi.git;a=commit;h=b1a4784c57b20c670ab8619b0ef2aadf8a48feef
> > My key is the same than last time.
> >
> > Changelog is the following one:
> >
> > Major Bug GERONIMO-6687
> >  OpenAPI parameter
> > style is always set to simple
> >  Unassigned
> RESOLVED
> > Major Bug GERONIMO-6692
> >  OpenAPI
> > SchemaProcessor causes a StackOverflowException when processing schema
> > for a class field that reference's it's own class
> >  Romain Manni-Bucau
> > <
> https://issues.apache.org/jira/secure/ViewProfile.jspa?name=romain.manni-bucau
> >
> > RESOLVED
> > Major Bug GERONIMO-6693
> >  arrays are not
> > supported in schema
> >  Romain Manni-Bucau
> > <
> https://issues.apache.org/jira/secure/ViewProfile.jspa?name=romain.manni-bucau
> >
> > RESOLVED
> > Major Improvement GERONIMO-6694
> >  Support @PATCH
> >  Romain Manni-Bucau
> > <
> https://issues.apache.org/jira/secure/ViewProfile.jspa?name=romain.manni-bucau
> >
> > RESOLVED
> > Major Bug GERONIMO-6695
> >  OpenAPI - Schemas
> > are not working properly with a few issues
> >  Romain Manni-Bucau
> > <
> https://issues.apache.org/jira/secure/ViewProfile.jspa?name=romain.manni-bucau
> >
> > RESOLVED
> > Major Improvement GERONIMO-6698
> >  OpenAPI - causes
> > NPE in Jersey CDIExtension
> >  Romain Manni-Bucau
> > <
> https://issues.apache.org/jira/secure/ViewProfile.jspa?name=romain.manni-bucau
> >
> > RESOLVED
> >
> >
> >
> > Please vote:
> >
> > [ ] +1 let it go out
> > [ ] -1 ${because X}
> >
> > Vote will stay open for 3 days or we get 3 +1 bindings vote as usual.
> >
> > Romain Manni-Bucau
> > @rmannibucau  |  Blog
> >  | Old Blog
> >  | Github
> >  | LinkedIn
> >  | Book
> > <
> https://www.packtpub.com/application-development/java-ee-8-high-performance
> >
>
> --
> Jean-Baptiste Onofré
> jbono...@apache.org
> http://blog.nanthrax.net
> Talend - http://www.talend.com
>


Re: Release train?

2019-02-24 Thread Ivan Junckes Filho
Hi Romain, I would love if the schema changes and the "in" ticket from
openapi are in this M3 release, is that possible?

On Sun, Feb 24, 2019 at 11:53 AM Romain Manni-Bucau 
wrote:

> Hi guys, several users asked for some release in MP land, anything you are
> working on or would like in? I will likely start it tomorrow if I find a
> slot for it.
>
> On my side I will import the docker/config code I mentionned in another
> thread in between.
>
> Romain Manni-Bucau
> @rmannibucau  |  Blog
>  | Old Blog
>  | Github
>  | LinkedIn
>  | Book
> 
>


[jira] [Commented] (GERONIMO-6695) OpenAPI - Schemas are not working properly with a few issues

2019-02-21 Thread Ivan Junckes Filho (JIRA)


[ 
https://issues.apache.org/jira/browse/GERONIMO-6695?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16774079#comment-16774079
 ] 

Ivan Junckes Filho commented on GERONIMO-6695:
--

Do you think this and also the "in" parameter can be added to a new release so 
it is ready for next time TomEE is released?

> OpenAPI - Schemas are not working properly with a few issues
> 
>
> Key: GERONIMO-6695
> URL: https://issues.apache.org/jira/browse/GERONIMO-6695
> Project: Geronimo
>  Issue Type: Bug
>  Security Level: public(Regular issues) 
>Reporter: Ivan Junckes Filho
>Assignee: Romain Manni-Bucau
>Priority: Major
> Fix For: OpenAPI_1.0.6
>
> Attachments: image-2019-02-19-11-05-49-553.png, 
> image-2019-02-19-11-07-02-967.png, image-2019-02-19-18-27-41-292.png
>
>
> 1 - Name of classes are not user friendly
> 2 - Internal system properties are showing up in the schema like factory, 
> superclass, typeParams... etc
> !image-2019-02-19-11-05-49-553.png!
> 3 - A lot of system classes are showing up as schemas and openapi should have 
> only webapp classes in the document. This even breaks swagger ui because it 
> makes it super slow.
> !image-2019-02-19-11-07-02-967.png!
> The previous images come from swagger-ui.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (GERONIMO-6695) OpenAPI - Schemas are not working properly with a few issues

2019-02-20 Thread Ivan Junckes Filho (JIRA)


[ 
https://issues.apache.org/jira/browse/GERONIMO-6695?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16773390#comment-16773390
 ] 

Ivan Junckes Filho commented on GERONIMO-6695:
--

Now it works, thanks Romain!

> OpenAPI - Schemas are not working properly with a few issues
> 
>
> Key: GERONIMO-6695
> URL: https://issues.apache.org/jira/browse/GERONIMO-6695
> Project: Geronimo
>  Issue Type: Bug
>  Security Level: public(Regular issues) 
>Reporter: Ivan Junckes Filho
>Assignee: Romain Manni-Bucau
>Priority: Major
> Attachments: image-2019-02-19-11-05-49-553.png, 
> image-2019-02-19-11-07-02-967.png, image-2019-02-19-18-27-41-292.png
>
>
> 1 - Name of classes are not user friendly
> 2 - Internal system properties are showing up in the schema like factory, 
> superclass, typeParams... etc
> !image-2019-02-19-11-05-49-553.png!
> 3 - A lot of system classes are showing up as schemas and openapi should have 
> only webapp classes in the document. This even breaks swagger ui because it 
> makes it super slow.
> !image-2019-02-19-11-07-02-967.png!
> The previous images come from swagger-ui.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (GERONIMO-6695) OpenAPI - Schemas are not working properly with a few issues

2019-02-20 Thread Ivan Junckes Filho (JIRA)


[ 
https://issues.apache.org/jira/browse/GERONIMO-6695?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16773200#comment-16773200
 ] 

Ivan Junckes Filho commented on GERONIMO-6695:
--

[~romain.manni-bucau] it took me some time to find what scenario it fails. It 
is related to openjpa, when I add persistence.xml to the project it adds a lot 
of classes to openapi. I don't know why. This is the project:

[https://github.com/ivanjunckes/testopenapi]

Can you help me to find the issue?

> OpenAPI - Schemas are not working properly with a few issues
> 
>
> Key: GERONIMO-6695
> URL: https://issues.apache.org/jira/browse/GERONIMO-6695
> Project: Geronimo
>  Issue Type: Bug
>  Security Level: public(Regular issues) 
>Reporter: Ivan Junckes Filho
>Assignee: Romain Manni-Bucau
>Priority: Major
> Attachments: image-2019-02-19-11-05-49-553.png, 
> image-2019-02-19-11-07-02-967.png, image-2019-02-19-18-27-41-292.png
>
>
> 1 - Name of classes are not user friendly
> 2 - Internal system properties are showing up in the schema like factory, 
> superclass, typeParams... etc
> !image-2019-02-19-11-05-49-553.png!
> 3 - A lot of system classes are showing up as schemas and openapi should have 
> only webapp classes in the document. This even breaks swagger ui because it 
> makes it super slow.
> !image-2019-02-19-11-07-02-967.png!
> The previous images come from swagger-ui.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (GERONIMO-6695) OpenAPI - Schemas are not working properly with a few issues

2019-02-19 Thread Ivan Junckes Filho (JIRA)


[ 
https://issues.apache.org/jira/browse/GERONIMO-6695?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16772350#comment-16772350
 ] 

Ivan Junckes Filho commented on GERONIMO-6695:
--

I am trying to build an example but couldn't yet as the example I built doesn't 
show a lot system classes. But the app from the client shows... trying to 
figure out why.

!image-2019-02-19-18-27-41-292.png!

> OpenAPI - Schemas are not working properly with a few issues
> 
>
> Key: GERONIMO-6695
> URL: https://issues.apache.org/jira/browse/GERONIMO-6695
> Project: Geronimo
>  Issue Type: Bug
>  Security Level: public(Regular issues) 
>Reporter: Ivan Junckes Filho
>Assignee: Romain Manni-Bucau
>Priority: Major
> Attachments: image-2019-02-19-11-05-49-553.png, 
> image-2019-02-19-11-07-02-967.png, image-2019-02-19-18-27-41-292.png
>
>
> 1 - Name of classes are not user friendly
> 2 - Internal system properties are showing up in the schema like factory, 
> superclass, typeParams... etc
> !image-2019-02-19-11-05-49-553.png!
> 3 - A lot of system classes are showing up as schemas and openapi should have 
> only webapp classes in the document. This even breaks swagger ui because it 
> makes it super slow.
> !image-2019-02-19-11-07-02-967.png!
> The previous images come from swagger-ui.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Updated] (GERONIMO-6695) OpenAPI - Schemas are not working properly with a few issues

2019-02-19 Thread Ivan Junckes Filho (JIRA)


 [ 
https://issues.apache.org/jira/browse/GERONIMO-6695?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Ivan Junckes Filho updated GERONIMO-6695:
-
Attachment: image-2019-02-19-18-27-41-292.png

> OpenAPI - Schemas are not working properly with a few issues
> 
>
> Key: GERONIMO-6695
> URL: https://issues.apache.org/jira/browse/GERONIMO-6695
> Project: Geronimo
>  Issue Type: Bug
>  Security Level: public(Regular issues) 
>Reporter: Ivan Junckes Filho
>Assignee: Romain Manni-Bucau
>Priority: Major
> Attachments: image-2019-02-19-11-05-49-553.png, 
> image-2019-02-19-11-07-02-967.png, image-2019-02-19-18-27-41-292.png
>
>
> 1 - Name of classes are not user friendly
> 2 - Internal system properties are showing up in the schema like factory, 
> superclass, typeParams... etc
> !image-2019-02-19-11-05-49-553.png!
> 3 - A lot of system classes are showing up as schemas and openapi should have 
> only webapp classes in the document. This even breaks swagger ui because it 
> makes it super slow.
> !image-2019-02-19-11-07-02-967.png!
> The previous images come from swagger-ui.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (GERONIMO-6695) OpenAPI - Schemas are not working properly with a few issues

2019-02-19 Thread Ivan Junckes Filho (JIRA)


[ 
https://issues.apache.org/jira/browse/GERONIMO-6695?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16772160#comment-16772160
 ] 

Ivan Junckes Filho commented on GERONIMO-6695:
--

[~romain.manni-bucau] this is on master, I got the snapshot and deployed with 
m2. This is a simple pojo, nothing special it should be supported. Also, this 
behavior happens for all classes in the webapp.

> OpenAPI - Schemas are not working properly with a few issues
> 
>
> Key: GERONIMO-6695
> URL: https://issues.apache.org/jira/browse/GERONIMO-6695
> Project: Geronimo
>  Issue Type: Bug
>  Security Level: public(Regular issues) 
>Reporter: Ivan Junckes Filho
>Assignee: Romain Manni-Bucau
>Priority: Major
> Attachments: image-2019-02-19-11-05-49-553.png, 
> image-2019-02-19-11-07-02-967.png
>
>
> 1 - Name of classes are not user friendly
> 2 - Internal system properties are showing up in the schema like factory, 
> superclass, typeParams... etc
> !image-2019-02-19-11-05-49-553.png!
> 3 - A lot of system classes are showing up as schemas and openapi should have 
> only webapp classes in the document. This even breaks swagger ui because it 
> makes it super slow.
> !image-2019-02-19-11-07-02-967.png!
> The previous images come from swagger-ui.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Updated] (GERONIMO-6695) OpenAPI - Schemas are not working properly with a few issues

2019-02-19 Thread Ivan Junckes Filho (JIRA)


 [ 
https://issues.apache.org/jira/browse/GERONIMO-6695?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Ivan Junckes Filho updated GERONIMO-6695:
-
Description: 
1 - Name of classes are not user friendly

2 - Internal system properties are showing up in the schema like factory, 
superclass, typeParams... etc

!image-2019-02-19-11-05-49-553.png!

3 - A lot of system classes are showing up as schemas and openapi should have 
only webapp classes in the document. This even breaks swagger ui because it 
makes it super slow.

!image-2019-02-19-11-07-02-967.png!

The previous images come from swagger-ui.

  was:
1 - Name of classes are not user friendly

2 - Internal system properties are showing up in the schema like factory, 
superclass, typeParams... etc

!image-2019-02-19-11-05-49-553.png!

3 - A lot of system classes are showing up as schemas and openapi should have 
only webapp classes in the document

!image-2019-02-19-11-07-02-967.png!

The previous images come from swagger-ui.


> OpenAPI - Schemas are not working properly with a few issues
> 
>
> Key: GERONIMO-6695
> URL: https://issues.apache.org/jira/browse/GERONIMO-6695
> Project: Geronimo
>  Issue Type: Bug
>  Security Level: public(Regular issues) 
>Reporter: Ivan Junckes Filho
>Priority: Major
> Attachments: image-2019-02-19-11-05-49-553.png, 
> image-2019-02-19-11-07-02-967.png
>
>
> 1 - Name of classes are not user friendly
> 2 - Internal system properties are showing up in the schema like factory, 
> superclass, typeParams... etc
> !image-2019-02-19-11-05-49-553.png!
> 3 - A lot of system classes are showing up as schemas and openapi should have 
> only webapp classes in the document. This even breaks swagger ui because it 
> makes it super slow.
> !image-2019-02-19-11-07-02-967.png!
> The previous images come from swagger-ui.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Created] (GERONIMO-6695) OpenAPI - Schemas are not working properly with a few issues

2019-02-19 Thread Ivan Junckes Filho (JIRA)
Ivan Junckes Filho created GERONIMO-6695:


 Summary: OpenAPI - Schemas are not working properly with a few 
issues
 Key: GERONIMO-6695
 URL: https://issues.apache.org/jira/browse/GERONIMO-6695
 Project: Geronimo
  Issue Type: Bug
  Security Level: public (Regular issues)
Reporter: Ivan Junckes Filho
 Attachments: image-2019-02-19-11-05-49-553.png, 
image-2019-02-19-11-07-02-967.png

1 - Name of classes are not user friendly

2 - Internal system properties are showing up in the schema like factory, 
superclass, typeParams... etc

!image-2019-02-19-11-05-49-553.png!

3 - A lot of system classes are showing up as schemas and openapi should have 
only webapp classes in the document

!image-2019-02-19-11-07-02-967.png!

The previous images come from swagger-ui.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


Re: "In" parameter not being populated OpenAPI

2019-02-11 Thread Ivan Junckes Filho
This is how it is showing up in components, schemas. But with a lot of not
needed properties as  this class has only telefone, mensagem and usuario.

 "br_com_gbrsistemas_crvirtual_sms_Sms": {
"deprecated": false,
"exclusiveMaximum": false,
"exclusiveMinimum": false,
"maxLength": 2147483647,
"minLength": 0,
"nullable": false,
"properties": {
  "telefone": {
"type": "string"
  },
  "mensagem": {
"type": "string"
  },
  "usuario": {
"type": "string"
  }
},
"readOnly": false,
"type": "object",
"uniqueItems": false,
"writeOnly": false
  },

Also the SNAPSHOT service path references the previous schema also with a
lot of not needed properties like deprecated, etc.

/sms/enviar": {
  "post": {
"deprecated": false,
"description": "Enviar SMS.",
"operationId": "enviarSms",
"parameters": [

],
"requestBody": {
  "content": {
"*/*": {
  "schema": {
"$ref":
"#/components/schemas/br_com_gbrsistemas_crvirtual_sms_Sms",
"deprecated": false,
"exclusiveMaximum": false,
"exclusiveMinimum": false,
"maxLength": 2147483647,
"minLength": 0,
"nullable": false,
"readOnly": false,
"type": "object",
"uniqueItems": false,
"writeOnly": false
  }
}
  },
  "required": false
},
"responses": {
  "200": {
"content": {
  "text/plain": {
"schema": {
  "deprecated": false,
  "exclusiveMaximum": false,
  "exclusiveMinimum": false,
  "maxLength": 2147483647,
  "minLength": 0,
  "nullable": false,
  "readOnly": false,
  "type": "string",
  "uniqueItems": false,
  "writeOnly": false
}
  }
},
"description": "Success"
  },
  "400": {
"content": {
  "200": {

  }
},
"description": "Bad Request"
  }
},
"security": [
  {
"bearer": [

]
  }
]
  }
},

The current m2 version of TomEE doesn't even show ref or any schema classes.

On Mon, Feb 11, 2019 at 12:12 PM Romain Manni-Bucau 
wrote:

> Hi Ivan, no the mapping can need some polishing to become mainstream
> (cause it is not openapi role to reimplement all mappers logic) but the
> annotation mapping is done.
> This one can depend the companions this annotation has, some will imply it
> gets ignored but AFAIK TCK test that and we pass them.
>
> Romain Manni-Bucau
> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> <https://rmannibucau.metawerx.net/> | Old Blog
> <http://rmannibucau.wordpress.com> | Github
> <https://github.com/rmannibucau> | LinkedIn
> <https://www.linkedin.com/in/rmannibucau> | Book
> <https://www.packtpub.com/application-development/java-ee-8-high-performance>
>
>
> Le lun. 11 févr. 2019 à 14:56, Ivan Junckes Filho 
> a écrit :
>
>> One thing I saw happening too, is when I add the annotation below it
>> doesn't get added to openapi.
>>
>> @RequestBody(content = @Content(schema = @Schema(implementation = 
>> Sms.class)))
>>
>>
>> Is that because it is under development?
>>
>>
>> On Mon, Feb 11, 2019 at 11:38 AM Romain Manni-Bucau <
>> rmannibu...@gmail.com> wrote:
>>
>>> Yes Ivan, array mapping is in progress. In the meantime you can define
>>> your schema to ensure you control it and the implicit representation does
>>> not depends on the way the impl parses it - which can not match your
>>> underlying mapper.
>>>
>>> Romain Manni-

Re: "In" parameter not being populated OpenAPI

2019-02-11 Thread Ivan Junckes Filho
One thing I saw happening too, is when I add the annotation below it
doesn't get added to openapi.

@RequestBody(content = @Content(schema = @Schema(implementation = Sms.class)))


Is that because it is under development?


On Mon, Feb 11, 2019 at 11:38 AM Romain Manni-Bucau 
wrote:

> Yes Ivan, array mapping is in progress. In the meantime you can define
> your schema to ensure you control it and the implicit representation does
> not depends on the way the impl parses it - which can not match your
> underlying mapper.
>
> Romain Manni-Bucau
> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> <https://rmannibucau.metawerx.net/> | Old Blog
> <http://rmannibucau.wordpress.com> | Github
> <https://github.com/rmannibucau> | LinkedIn
> <https://www.linkedin.com/in/rmannibucau> | Book
> <https://www.packtpub.com/application-development/java-ee-8-high-performance>
>
>
> Le lun. 11 févr. 2019 à 14:23, Ivan Junckes Filho 
> a écrit :
>
>> Looks like it is fixed in the master, but when I get the lib and add to
>> tomee it shows some bad behavior with the schemas.
>>
>> [image: image.png]
>>
>> On Mon, Feb 11, 2019 at 11:09 AM Ivan Junckes Filho <
>> ivanjunc...@gmail.com> wrote:
>>
>>> No I didn't, I will have a look. thanks
>>>
>>> On Mon, Feb 11, 2019 at 11:08 AM Romain Manni-Bucau <
>>> rmannibu...@gmail.com> wrote:
>>>
>>>> Hi Ivan,
>>>>
>>>> Did you test on the snapshot? we got some enhancements about it.
>>>>
>>>> Romain Manni-Bucau
>>>> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
>>>> <https://rmannibucau.metawerx.net/> | Old Blog
>>>> <http://rmannibucau.wordpress.com> | Github <
>>>> https://github.com/rmannibucau> |
>>>> LinkedIn <https://www.linkedin.com/in/rmannibucau> | Book
>>>> <
>>>> https://www.packtpub.com/application-development/java-ee-8-high-performance
>>>> >
>>>>
>>>>
>>>> Le lun. 11 févr. 2019 à 14:03, Ivan Junckes Filho <
>>>> ivanjunc...@gmail.com> a
>>>> écrit :
>>>>
>>>> > Hey guys, I think there is an issue with parameters as the "in"
>>>> property
>>>> > is required by the spec and is not showing up. This affects
>>>> swagger-ui as
>>>> > it doesn't replace uf by the actual value. Anyone aware of this issue?
>>>> >
>>>> > {
>>>> >   "openapi": "3.0.1",
>>>> >   "paths": {
>>>> > "/test/{uf}": {
>>>> >   "get": {
>>>> > "deprecated": false,
>>>> > "description": "Test by UF.",
>>>> > "operationId": "test",
>>>> > "parameters": [
>>>> >   {
>>>> > "name": "uf",
>>>> > "required": true,
>>>> > "schema": {
>>>> >   "type": "string"
>>>> > },
>>>> > "style": "simple"
>>>> >   }
>>>> > ],
>>>> > "responses": {
>>>> >   "200": {
>>>> > "content": {
>>>> >   "application/json": {
>>>> > "schema": {
>>>> >   "deprecated": false,
>>>> >   "exclusiveMaximum": false,
>>>> >   "exclusiveMinimum": false,
>>>> >   "items": {
>>>> >
>>>> >   },
>>>> >   "maxLength": 2147483647,
>>>> >   "minLength": 0,
>>>> >   "nullable": false,
>>>> >   "properties": {
>>>> >
>>>> >   },
>>>> >   "readOnly": false,
>>>> >   "uniqueItems": false,
>>>> >   "writeOnly": false
>>>> > }
>>>> >   }
>>>> > },
>>>> > "description": "Success"
>>>> >   },
>>>> >   "400": {
>>>> > "content": {
>>>> >   "200": {
>>>> >
>>>> >   }
>>>> > },
>>>> > "description": "Bad Request"
>>>> >   }
>>>> > },
>>>> >
>>>> >   }
>>>> > },
>>>> >
>>>> >   }
>>>> >   ]
>>>> > }
>>>> >
>>>>
>>>


Re: "In" parameter not being populated OpenAPI

2019-02-11 Thread Ivan Junckes Filho
Looks like it is fixed in the master, but when I get the lib and add to
tomee it shows some bad behavior with the schemas.

[image: image.png]

On Mon, Feb 11, 2019 at 11:09 AM Ivan Junckes Filho 
wrote:

> No I didn't, I will have a look. thanks
>
> On Mon, Feb 11, 2019 at 11:08 AM Romain Manni-Bucau 
> wrote:
>
>> Hi Ivan,
>>
>> Did you test on the snapshot? we got some enhancements about it.
>>
>> Romain Manni-Bucau
>> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
>> <https://rmannibucau.metawerx.net/> | Old Blog
>> <http://rmannibucau.wordpress.com> | Github <
>> https://github.com/rmannibucau> |
>> LinkedIn <https://www.linkedin.com/in/rmannibucau> | Book
>> <
>> https://www.packtpub.com/application-development/java-ee-8-high-performance
>> >
>>
>>
>> Le lun. 11 févr. 2019 à 14:03, Ivan Junckes Filho 
>> a
>> écrit :
>>
>> > Hey guys, I think there is an issue with parameters as the "in" property
>> > is required by the spec and is not showing up. This affects swagger-ui
>> as
>> > it doesn't replace uf by the actual value. Anyone aware of this issue?
>> >
>> > {
>> >   "openapi": "3.0.1",
>> >   "paths": {
>> > "/test/{uf}": {
>> >   "get": {
>> > "deprecated": false,
>> > "description": "Test by UF.",
>> > "operationId": "test",
>> > "parameters": [
>> >   {
>> > "name": "uf",
>> > "required": true,
>> > "schema": {
>> >   "type": "string"
>> > },
>> > "style": "simple"
>> >   }
>> > ],
>> > "responses": {
>> >   "200": {
>> > "content": {
>> >   "application/json": {
>> > "schema": {
>> >   "deprecated": false,
>> >   "exclusiveMaximum": false,
>> >   "exclusiveMinimum": false,
>> >   "items": {
>> >
>> >   },
>> >   "maxLength": 2147483647,
>> >   "minLength": 0,
>> >   "nullable": false,
>> >   "properties": {
>> >
>> >   },
>> >   "readOnly": false,
>> >   "uniqueItems": false,
>> >   "writeOnly": false
>> > }
>> >   }
>> > },
>> > "description": "Success"
>> >   },
>> >   "400": {
>> > "content": {
>> >   "200": {
>> >
>> >   }
>> > },
>> > "description": "Bad Request"
>> >   }
>> > },
>> >
>> >   }
>> > },
>> >
>> >   }
>> >   ]
>> > }
>> >
>>
>


Re: "In" parameter not being populated OpenAPI

2019-02-11 Thread Ivan Junckes Filho
No I didn't, I will have a look. thanks

On Mon, Feb 11, 2019 at 11:08 AM Romain Manni-Bucau 
wrote:

> Hi Ivan,
>
> Did you test on the snapshot? we got some enhancements about it.
>
> Romain Manni-Bucau
> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> <https://rmannibucau.metawerx.net/> | Old Blog
> <http://rmannibucau.wordpress.com> | Github <
> https://github.com/rmannibucau> |
> LinkedIn <https://www.linkedin.com/in/rmannibucau> | Book
> <
> https://www.packtpub.com/application-development/java-ee-8-high-performance
> >
>
>
> Le lun. 11 févr. 2019 à 14:03, Ivan Junckes Filho 
> a
> écrit :
>
> > Hey guys, I think there is an issue with parameters as the "in" property
> > is required by the spec and is not showing up. This affects swagger-ui as
> > it doesn't replace uf by the actual value. Anyone aware of this issue?
> >
> > {
> >   "openapi": "3.0.1",
> >   "paths": {
> > "/test/{uf}": {
> >   "get": {
> > "deprecated": false,
> > "description": "Test by UF.",
> > "operationId": "test",
> > "parameters": [
> >   {
> > "name": "uf",
> > "required": true,
> > "schema": {
> >   "type": "string"
> > },
> > "style": "simple"
> >   }
> > ],
> > "responses": {
> >   "200": {
> > "content": {
> >   "application/json": {
> > "schema": {
> >   "deprecated": false,
> >   "exclusiveMaximum": false,
> >   "exclusiveMinimum": false,
> >   "items": {
> >
> >   },
> >   "maxLength": 2147483647,
> >   "minLength": 0,
> >   "nullable": false,
> >   "properties": {
> >
> >   },
> >   "readOnly": false,
> >   "uniqueItems": false,
> >   "writeOnly": false
> > }
> >   }
> > },
> > "description": "Success"
> >   },
> >   "400": {
> > "content": {
> >   "200": {
> >
> >   }
> > },
> > "description": "Bad Request"
> >   }
> > },
> >
> >   }
> > },
> >
> >   }
> >   ]
> > }
> >
>


Re: @OpenAPIDefinition not working

2019-02-11 Thread Ivan Junckes Filho
It didn't seem to work for me adding the property to system.properties. Any
ideas what I am doing wrong?

On Sat, Feb 9, 2019 at 10:21 AM Roberto Cortez  wrote:

> Hi Ivan,
>
> Yes Romain is right, you should set openejb.cxf-rs.cache-application =
> false and it should work. We had to set that for the TCK to pass, but the
> config never reached the final distribution. I did notice that and I’ve
> added it in case a MP app is detected, but it was after M2 was released.
>
> Cheers,
> Roberto
>
> On 8 Feb 2019, at 21:06, Ivan Junckes Filho  wrote:
>
> I will take a look thanks again Romain
>
> On Fri, Feb 8, 2019 at 4:38 PM Romain Manni-Bucau 
> wrote:
>
>> Hey, just recalled we had a flag about it,
>>
>> you can skip it setting openejb.cxf-rs.cache-application=false
>>
>> Romain Manni-Bucau
>> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
>> <https://rmannibucau.metawerx.net/> | Old Blog
>> <http://rmannibucau.wordpress.com> | Github <
>> https://github.com/rmannibucau> |
>> LinkedIn <https://www.linkedin.com/in/rmannibucau> | Book
>> <
>> https://www.packtpub.com/application-development/java-ee-8-high-performance
>> >
>>
>>
>> Le ven. 8 févr. 2019 à 19:01, Ivan Junckes Filho 
>> a
>> écrit :
>>
>> > Interesting, ok thanks Romain.
>> >
>> > On Fri, Feb 8, 2019 at 3:29 PM Romain Manni-Bucau <
>> rmannibu...@gmail.com>
>> > wrote:
>> >
>> >> Hi Ivan,
>> >>
>> >> In a few cases - don't recall out of my head if it is all - TomEE wraps
>> >> user application in InternalApplication. IIRC it was for caching
>> reason -
>> >> TomEE not being super cleanly aligned on CDI + to avoid to get multiple
>> >> instances between runtime and deployment which can break user code.
>> >> Enhancing TomEE to no do it anymore or not use a wrapper when not
>> needed
>> >> can be a first step fixing that.
>> >>
>> >> Romain Manni-Bucau
>> >> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
>> >> <https://rmannibucau.metawerx.net/> | Old Blog
>> >> <http://rmannibucau.wordpress.com> | Github
>> >> <https://github.com/rmannibucau> | LinkedIn
>> >> <https://www.linkedin.com/in/rmannibucau> | Book
>> >> <
>> https://www.packtpub.com/application-development/java-ee-8-high-performance
>> >
>> >>
>> >>
>> >> Le ven. 8 févr. 2019 à 18:14, Ivan Junckes Filho <
>> ivanjunc...@gmail.com>
>> >> a écrit :
>> >>
>> >>> The @OpenAPIDefinition is not being picked up by the CDI extension
>> >>> because it is only getting InternalApplication instead of picking up
>> my
>> >>> custom Application config. Any ideas why? OpenAPIDefinition configs
>> are
>> >>> therefore not showing up in the openapi doc.
>> >>>
>> >>>
>> >>> @OpenAPIDefinition(info =
>> >>> @Info(
>> >>> title = "TEST",
>> >>> version = "2.0",
>> >>> description = "Pet Store App API",
>> >>> license = @License(
>> >>> name = "Apache 2.0",
>> >>> url = "
>> http://www.apache.org/licenses/LICENSE-2.0.html";),
>> >>> contact = @Contact(
>> >>> name = "PetStore API Support",
>> >>> url = "
>> https://github.com/eclipse/microprofile-open-api";,
>> >>> email = "supp...@petstore.com")
>> >>> ),
>> >>> security = @SecurityRequirement(name = "oauth2"),
>> >>> servers = @Server(url = "/test/"))
>> >>> @ApplicationPath("/api")
>> >>> @LoginConfig(authMethod = "MP-JWT")
>> >>> public class ApplicationConfiguration extends Application {
>> >>>
>> >>>
>>
>
>


"In" parameter not being populated OpenAPI

2019-02-11 Thread Ivan Junckes Filho
Hey guys, I think there is an issue with parameters as the "in" property is
required by the spec and is not showing up. This affects swagger-ui as it
doesn't replace uf by the actual value. Anyone aware of this issue?

{
  "openapi": "3.0.1",
  "paths": {
"/test/{uf}": {
  "get": {
"deprecated": false,
"description": "Test by UF.",
"operationId": "test",
"parameters": [
  {
"name": "uf",
"required": true,
"schema": {
  "type": "string"
},
"style": "simple"
  }
],
"responses": {
  "200": {
"content": {
  "application/json": {
"schema": {
  "deprecated": false,
  "exclusiveMaximum": false,
  "exclusiveMinimum": false,
  "items": {

  },
  "maxLength": 2147483647,
  "minLength": 0,
  "nullable": false,
  "properties": {

  },
  "readOnly": false,
  "uniqueItems": false,
  "writeOnly": false
}
  }
},
"description": "Success"
  },
  "400": {
"content": {
  "200": {

  }
},
"description": "Bad Request"
  }
},

  }
},

  }
  ]
}


Re: @OpenAPIDefinition not working

2019-02-08 Thread Ivan Junckes Filho
I will take a look thanks again Romain

On Fri, Feb 8, 2019 at 4:38 PM Romain Manni-Bucau 
wrote:

> Hey, just recalled we had a flag about it,
>
> you can skip it setting openejb.cxf-rs.cache-application=false
>
> Romain Manni-Bucau
> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> <https://rmannibucau.metawerx.net/> | Old Blog
> <http://rmannibucau.wordpress.com> | Github <
> https://github.com/rmannibucau> |
> LinkedIn <https://www.linkedin.com/in/rmannibucau> | Book
> <
> https://www.packtpub.com/application-development/java-ee-8-high-performance
> >
>
>
> Le ven. 8 févr. 2019 à 19:01, Ivan Junckes Filho  a
> écrit :
>
> > Interesting, ok thanks Romain.
> >
> > On Fri, Feb 8, 2019 at 3:29 PM Romain Manni-Bucau  >
> > wrote:
> >
> >> Hi Ivan,
> >>
> >> In a few cases - don't recall out of my head if it is all - TomEE wraps
> >> user application in InternalApplication. IIRC it was for caching reason
> -
> >> TomEE not being super cleanly aligned on CDI + to avoid to get multiple
> >> instances between runtime and deployment which can break user code.
> >> Enhancing TomEE to no do it anymore or not use a wrapper when not needed
> >> can be a first step fixing that.
> >>
> >> Romain Manni-Bucau
> >> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> >> <https://rmannibucau.metawerx.net/> | Old Blog
> >> <http://rmannibucau.wordpress.com> | Github
> >> <https://github.com/rmannibucau> | LinkedIn
> >> <https://www.linkedin.com/in/rmannibucau> | Book
> >> <
> https://www.packtpub.com/application-development/java-ee-8-high-performance
> >
> >>
> >>
> >> Le ven. 8 févr. 2019 à 18:14, Ivan Junckes Filho  >
> >> a écrit :
> >>
> >>> The @OpenAPIDefinition is not being picked up by the CDI extension
> >>> because it is only getting InternalApplication instead of picking up my
> >>> custom Application config. Any ideas why? OpenAPIDefinition configs are
> >>> therefore not showing up in the openapi doc.
> >>>
> >>>
> >>> @OpenAPIDefinition(info =
> >>> @Info(
> >>> title = "TEST",
> >>> version = "2.0",
> >>> description = "Pet Store App API",
> >>> license = @License(
> >>> name = "Apache 2.0",
> >>> url = "
> http://www.apache.org/licenses/LICENSE-2.0.html";),
> >>> contact = @Contact(
> >>> name = "PetStore API Support",
> >>> url = "
> https://github.com/eclipse/microprofile-open-api";,
> >>> email = "supp...@petstore.com")
> >>> ),
> >>> security = @SecurityRequirement(name = "oauth2"),
> >>> servers = @Server(url = "/test/"))
> >>> @ApplicationPath("/api")
> >>> @LoginConfig(authMethod = "MP-JWT")
> >>> public class ApplicationConfiguration extends Application {
> >>>
> >>>
>


Re: @OpenAPIDefinition not working

2019-02-08 Thread Ivan Junckes Filho
Interesting, ok thanks Romain.

On Fri, Feb 8, 2019 at 3:29 PM Romain Manni-Bucau 
wrote:

> Hi Ivan,
>
> In a few cases - don't recall out of my head if it is all - TomEE wraps
> user application in InternalApplication. IIRC it was for caching reason -
> TomEE not being super cleanly aligned on CDI + to avoid to get multiple
> instances between runtime and deployment which can break user code.
> Enhancing TomEE to no do it anymore or not use a wrapper when not needed
> can be a first step fixing that.
>
> Romain Manni-Bucau
> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> <https://rmannibucau.metawerx.net/> | Old Blog
> <http://rmannibucau.wordpress.com> | Github
> <https://github.com/rmannibucau> | LinkedIn
> <https://www.linkedin.com/in/rmannibucau> | Book
> <https://www.packtpub.com/application-development/java-ee-8-high-performance>
>
>
> Le ven. 8 févr. 2019 à 18:14, Ivan Junckes Filho 
> a écrit :
>
>> The @OpenAPIDefinition is not being picked up by the CDI extension
>> because it is only getting InternalApplication instead of picking up my
>> custom Application config. Any ideas why? OpenAPIDefinition configs are
>> therefore not showing up in the openapi doc.
>>
>>
>> @OpenAPIDefinition(info =
>> @Info(
>> title = "TEST",
>> version = "2.0",
>> description = "Pet Store App API",
>> license = @License(
>> name = "Apache 2.0",
>> url = 
>> "http://www.apache.org/licenses/LICENSE-2.0.html";),
>> contact = @Contact(
>> name = "PetStore API Support",
>> url = 
>> "https://github.com/eclipse/microprofile-open-api";,
>> email = "supp...@petstore.com")
>> ),
>> security = @SecurityRequirement(name = "oauth2"),
>> servers = @Server(url = "/test/"))
>> @ApplicationPath("/api")
>> @LoginConfig(authMethod = "MP-JWT")
>> public class ApplicationConfiguration extends Application {
>>
>>


@OpenAPIDefinition not working

2019-02-08 Thread Ivan Junckes Filho
The @OpenAPIDefinition is not being picked up by the CDI extension because
it is only getting InternalApplication instead of picking up my custom
Application config. Any ideas why? OpenAPIDefinition configs are therefore
not showing up in the openapi doc.


@OpenAPIDefinition(info =
@Info(
title = "TEST",
version = "2.0",
description = "Pet Store App API",
license = @License(
name = "Apache 2.0",
url =
"http://www.apache.org/licenses/LICENSE-2.0.html";),
contact = @Contact(
name = "PetStore API Support",
url =
"https://github.com/eclipse/microprofile-open-api";,
email = "supp...@petstore.com")
),
security = @SecurityRequirement(name = "oauth2"),
servers = @Server(url = "/test/"))
@ApplicationPath("/api")
@LoginConfig(authMethod = "MP-JWT")
public class ApplicationConfiguration extends Application {


MP RestClient issue DuplicateDefinitionException

2019-02-07 Thread Ivan Junckes Filho
Hey guys,  I need help with rest client in TomEE.

I am deploying in the same server 2 apps.

app1 -> Has the client interfaces, but I exclude from the war.
app2 -> Has the client interfaces from app1 in a jar.

I deploy app1 and app2 in the same server and I get the
DuplicateDefinitionException.

Any suggestions on what could be?

tomee   | 07-Feb-2019 12:50:09.512 INFO [main]
org.apache.webbeans.plugins.PluginLoader.startUp Adding OpenWebBeansPlugin
: [CdiPlugin]
tomee   | 07-Feb-2019 12:50:09.839 INFO [main]
org.apache.openejb.cdi.CdiScanner.handleBda Using annotated mode for
jar:file:/usr/local/tomee/lib/geronimo-config-impl-1.2.1.jar!/META-INF/beans.xml
looking all classes to find CDI beans, maybe think to add a beans.xml if
not there or add the jar to exclusions.list
tomee   | 07-Feb-2019 12:50:09.847 INFO [main]
org.apache.openejb.cdi.CdiScanner.handleBda Using annotated mode for
file:/usr/local/tomee/lib/microprofile-rest-client-api-1.1.jar looking all
classes to find CDI beans, maybe think to add a beans.xml if not there or
add the jar to exclusions.list
tomee   | 07-Feb-2019 12:50:09.977 INFO [main]
org.apache.geronimo.config.configsource.PropertyFileConfigSourceProvider.
Custom config found by GeronimoConfig. Name:
'META-INF/microprofile-config.properties', URL:
'file:/usr/local/tomee/webapps/crvirtualsiem/WEB-INF/classes/META-INF/microprofile-config.properties'
tomee   | 07-Feb-2019 12:50:10.978 SEVERE [main]
org.apache.openejb.cdi.OpenEJBLifecycle.startApplication CDI Beans module
deployment failed
tomee   |
org.apache.webbeans.exception.WebBeansConfigurationException: Error while
sending SystemEvent to a CDI Extension!
org.apache.webbeans.portable.events.discovery.AfterBeanDiscoveryImpl@578dbfa0
tomee   | at
org.apache.webbeans.event.NotificationManager.fireEvent(NotificationManager.java:735)
tomee   | at
org.apache.webbeans.container.BeanManagerImpl.fireEvent(BeanManagerImpl.java:495)
tomee   | at
org.apache.webbeans.container.BeanManagerImpl.fireLifecycleEvent(BeanManagerImpl.java:490)
tomee   | at
org.apache.webbeans.config.BeansDeployer.fireAfterBeanDiscoveryEvent(BeansDeployer.java:806)
tomee   | at
org.apache.webbeans.config.BeansDeployer.deploy(BeansDeployer.java:320)
tomee   | at
org.apache.openejb.cdi.OpenEJBLifecycle.startApplication(OpenEJBLifecycle.java:196)
tomee   | at
org.apache.openejb.cdi.ThreadSingletonServiceImpl.initialize(ThreadSingletonServiceImpl.java:229)
tomee   | at
org.apache.openejb.cdi.CdiBuilder.build(CdiBuilder.java:41)
tomee   | at
org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:963)
tomee   | at
org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:756)
tomee   | at
org.apache.tomee.catalina.TomcatWebAppBuilder.startInternal(TomcatWebAppBuilder.java:1308)
tomee   | at
org.apache.tomee.catalina.TomcatWebAppBuilder.configureStart(TomcatWebAppBuilder.java:1130)
tomee   | at
org.apache.tomee.catalina.GlobalListenerSupport.lifecycleEvent(GlobalListenerSupport.java:134)
tomee   | at
org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:123)
tomee   | at
org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5007)
tomee   | at
org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
tomee   | at
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:743)
tomee   | at
org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:719)
tomee   | at
org.apache.catalina.core.StandardHost.addChild(StandardHost.java:703)
tomee   | at
org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:986)
tomee   | at
org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1858)
tomee   | at
java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
tomee   | at
java.util.concurrent.FutureTask.run(FutureTask.java:266)
tomee   | at
org.apache.tomcat.util.threads.InlineExecutorService.execute(InlineExecutorService.java:75)
tomee   | at
java.util.concurrent.AbstractExecutorService.submit(AbstractExecutorService.java:112)
tomee   | at
org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:772)
tomee   | at
org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:426)
tomee   | at
org.apache.catalina.startup.HostConfig.start(HostConfig.java:1585)
tomee   | at
org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:308)
tomee   | at
org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:123)
tomee   | at
org.apache.catalina.util.L

Re: [ANNOUNCE] Apache Geronimo OpenAPI 1.0.5 released

2019-02-04 Thread Ivan Junckes Filho
Thanks Romain!

On Sat, Feb 2, 2019 at 2:33 PM Romain Manni-Bucau 
wrote:

> The Apache Geronimo team is happy to announce the Apache Geronimo OpenAPI 
> 1.0.5
> release.
>
> It brings several fixes in the generated openapi model.
>
> You can more on Apache Geronimo OpenAPI and more generally the
> Microprofile ecosystem at Geronimo at
> http://geronimo.apache.org/microprofile/.
>
> Apache Geronimo team
>


Re: [VOTE] Release Apache Geronimo OpenAPI 1.0.5

2019-01-28 Thread Ivan Junckes Filho
+1 thanks Romain

On Mon, Jan 28, 2019 at 1:38 PM Raymond Auge 
wrote:

> +1
>
> - Ray
>
> On Mon, Jan 28, 2019 at 9:25 AM Romain Manni-Bucau 
> wrote:
>
>> Hi guys,
>>
>> As requested last week, here is the Apache Geronimo OpenAPI 1.0.5 vote.
>>
>> Staging repo can be found at
>> https://repository.apache.org/content/repositories/orgapachegeronimo-1087/
>> Tag is at
>> https://gitbox.apache.org/repos/asf?p=geronimo-openapi.git;a=commit;h=eea43f1f245222567f51bb53bef3d877dc81bb27
>> My key is the same than for last votes.
>> Sources are available at
>> https://repository.apache.org/content/repositories/orgapachegeronimo-1087/org/apache/geronimo/geronimo-openapi/1.0.5/
>>
>> FYI the changelog is:
>>
>> PTKeySummaryAssigneeStatusDevelopment
>> [image: Major] [image: Bug] GERONIMO-6683
>>  Missing mapping
>> for Parameter.In in OpenAPI definition
>>  Unassigned RESOLVED
>> [image: Major] [image: Task] GERONIMO-6684
>>  Upgrade CXF to
>> 3.2.7  Unassigned
>> RESOLVED
>> [image: Major] [image: Task] GERONIMO-6685
>>  Basic integration
>> test for maven plugin
>>  Unassigned RESOLVED
>> [image: Major] [image: Bug] GERONIMO-6686
>>  OpenAPI
>> operationId is not unique
>>  Unassigned RESOLVED
>> [image: Major] [image: Bug] GERONIMO-6689
>>  OpenAPI default
>> response is not serialized
>>  Unassigned RESOLVED
>> [image: Major] [image: Bug] GERONIMO-6690
>>  OpenAPI
>> StringIndexOutOfBoundsException when @Path parent has only "/"
>>  Romain Manni-Bucau
>> 
>> RESOLVED
>>
>> Please vote:
>>
>> [ ] +1 let it go out
>> [ ] -1, cause ${blocker}
>>
>> Vote will be opened for 72h as usual
>>
>> Romain Manni-Bucau
>> @rmannibucau  |  Blog
>>  | Old Blog
>>  | Github
>>  | LinkedIn
>>  | Book
>> 
>>
>
>
> --
> *Raymond Augé* 
>  (@rotty3000)
> Senior Software Architect *Liferay, Inc.* 
>  (@Liferay)
> Board Member & EEG Co-Chair, OSGi Alliance 
> (@OSGiAlliance)
>


Re: OpenAPI integration with metrics/health

2019-01-25 Thread Ivan Junckes Filho
Cool thanks Romain.

On Fri, Jan 25, 2019 at 12:19 PM Romain Manni-Bucau 
wrote:

> likely end of next week it sounds feasible
>
> Romain Manni-Bucau
> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> <https://rmannibucau.metawerx.net/> | Old Blog
> <http://rmannibucau.wordpress.com> | Github
> <https://github.com/rmannibucau> | LinkedIn
> <https://www.linkedin.com/in/rmannibucau> | Book
> <https://www.packtpub.com/application-development/java-ee-8-high-performance>
>
>
> Le ven. 25 janv. 2019 à 15:18, Ivan Junckes Filho 
> a écrit :
>
>> I was trying to fix this in TomEE side
>> https://issues.apache.org/jira/browse/GERONIMO-6689.
>>
>> But I just saw it got fixed in Geronimo side this week.
>>
>> @Romain Manni-Bucau  would you be able to do a
>> release with this change and add it to TomEE release if there is time?
>>
>> On Fri, Jan 18, 2019 at 10:46 AM Ivan Junckes Filho <
>> ivanjunc...@gmail.com> wrote:
>>
>>> Thanks Romain, I will have a look.
>>>
>>> On Fri, Jan 18, 2019 at 10:41 AM Romain Manni-Bucau <
>>> rmannibu...@gmail.com> wrote:
>>>
>>>> You can use:
>>>>
>>>> void start(@Observes @intiialzed(ApplicationScoped.class) Object event,
>>>> final GeronimoOpenAPIExtension ext, final Application app) {
>>>>   final OpenAPI openapi = ext.getOrCreateOpenAPI(app);
>>>> }
>>>>
>>>> if you have a single app or collect them in the extension and call the
>>>> same method for all of them
>>>>
>>>> Romain Manni-Bucau
>>>> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
>>>> <https://rmannibucau.metawerx.net/> | Old Blog
>>>> <http://rmannibucau.wordpress.com> | Github
>>>> <https://github.com/rmannibucau> | LinkedIn
>>>> <https://www.linkedin.com/in/rmannibucau> | Book
>>>> <https://www.packtpub.com/application-development/java-ee-8-high-performance>
>>>>
>>>>
>>>> Le ven. 18 janv. 2019 à 13:00, Ivan Junckes Filho <
>>>> ivanjunc...@gmail.com> a écrit :
>>>>
>>>>> Cool I will have a look next week. Can you point out which event is it?
>>>>>
>>>>> On Thu, Jan 17, 2019 at 1:52 PM Romain Manni-Bucau <
>>>>> rmannibu...@gmail.com> wrote:
>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> Le jeu. 17 janv. 2019 à 16:49, Ivan Junckes Filho <
>>>>>> ivanjunc...@gmail.com> a écrit :
>>>>>>
>>>>>>> On Thu, Jan 17, 2019 at 12:11 PM Romain Manni-Bucau <
>>>>>>> rmannibu...@gmail.com> wrote:
>>>>>>>
>>>>>>>> I would prefer to not leak specs between them since they are used
>>>>>>>> without the others today.
>>>>>>>>
>>>>>>>> What is missing for it to work, returned types are explicit no?
>>>>>>>>
>>>>>>> It misses ResponseCodes, without that swagger ui doesn't work.
>>>>>>>
>>>>>>
>>>>>> Ok, 200/204 should definitely work
>>>>>>
>>>>>>
>>>>>>> Last releases got some work to have it working OOTB so this can
>>>>>>>> likely be enhanced again if required.
>>>>>>>>
>>>>>>> What is OOTB?
>>>>>>>
>>>>>>
>>>>>> out of the box ;)
>>>>>>
>>>>>>
>>>>>>> Also something unclear is if they should appear or not in the
>>>>>>>> openapi report (we made the choice to do but it is not required AFAIK)
>>>>>>>>
>>>>>>>> In my opinion we should keep it, but have at list a basic
>>>>>>> configure. @ResponseCode 200 should be there as it is the expected 
>>>>>>> response
>>>>>>> code.
>>>>>>>
>>>>>>
>>>>>> it must be implicit anyway
>>>>>>
>>>>>>
>>>>>>> Another option for tomee would be to enrich the OpenAPI with what it
>>>>>>>> need, there is the API for that.
>>>>>>>>
>>>>>>>> Can you elaborate?
>>>>>>>
>>>>>>
>>>>>> IIRC there is an event fired with OpenAPI model, tomee can observe it
>>>>>> and add all the doc it needs, including its internal endpoints or tomee
>>>>>> webapp
>>>>>>
>>>>>>
>>>>>>> Romain Manni-Bucau
>>>>>>>> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
>>>>>>>> <https://rmannibucau.metawerx.net/> | Old Blog
>>>>>>>> <http://rmannibucau.wordpress.com> | Github
>>>>>>>> <https://github.com/rmannibucau> | LinkedIn
>>>>>>>> <https://www.linkedin.com/in/rmannibucau> | Book
>>>>>>>> <https://www.packtpub.com/application-development/java-ee-8-high-performance>
>>>>>>>>
>>>>>>>>
>>>>>>>> Le jeu. 17 janv. 2019 à 14:49, Ivan Junckes Filho <
>>>>>>>> ivanjunc...@gmail.com> a écrit :
>>>>>>>>
>>>>>>>>> Hey guys, I was trying to make the openapi document generated by
>>>>>>>>> geronimo-openapi to work with swagger-ui. The issue is I can't execute
>>>>>>>>> requests from swagger-ui in the endpoints generated (metrics, health,
>>>>>>>>> openapi) by TomEE as they don't have a @ApiResponse annotation and
>>>>>>>>> swagger-ui doesn't display the message without that.
>>>>>>>>>
>>>>>>>>> What do you guys think of having this annotation by default in the
>>>>>>>>> endpoints? At least for 200?
>>>>>>>>>
>>>>>>>>> Or anyone has a better solution for this?
>>>>>>>>>
>>>>>>>>


Re: OpenAPI integration with metrics/health

2019-01-25 Thread Ivan Junckes Filho
I was trying to fix this in TomEE side
https://issues.apache.org/jira/browse/GERONIMO-6689.

But I just saw it got fixed in Geronimo side this week.

@Romain Manni-Bucau  would you be able to do a
release with this change and add it to TomEE release if there is time?

On Fri, Jan 18, 2019 at 10:46 AM Ivan Junckes Filho 
wrote:

> Thanks Romain, I will have a look.
>
> On Fri, Jan 18, 2019 at 10:41 AM Romain Manni-Bucau 
> wrote:
>
>> You can use:
>>
>> void start(@Observes @intiialzed(ApplicationScoped.class) Object event,
>> final GeronimoOpenAPIExtension ext, final Application app) {
>>   final OpenAPI openapi = ext.getOrCreateOpenAPI(app);
>> }
>>
>> if you have a single app or collect them in the extension and call the
>> same method for all of them
>>
>> Romain Manni-Bucau
>> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
>> <https://rmannibucau.metawerx.net/> | Old Blog
>> <http://rmannibucau.wordpress.com> | Github
>> <https://github.com/rmannibucau> | LinkedIn
>> <https://www.linkedin.com/in/rmannibucau> | Book
>> <https://www.packtpub.com/application-development/java-ee-8-high-performance>
>>
>>
>> Le ven. 18 janv. 2019 à 13:00, Ivan Junckes Filho 
>> a écrit :
>>
>>> Cool I will have a look next week. Can you point out which event is it?
>>>
>>> On Thu, Jan 17, 2019 at 1:52 PM Romain Manni-Bucau <
>>> rmannibu...@gmail.com> wrote:
>>>
>>>>
>>>>
>>>>
>>>> Le jeu. 17 janv. 2019 à 16:49, Ivan Junckes Filho <
>>>> ivanjunc...@gmail.com> a écrit :
>>>>
>>>>> On Thu, Jan 17, 2019 at 12:11 PM Romain Manni-Bucau <
>>>>> rmannibu...@gmail.com> wrote:
>>>>>
>>>>>> I would prefer to not leak specs between them since they are used
>>>>>> without the others today.
>>>>>>
>>>>>> What is missing for it to work, returned types are explicit no?
>>>>>>
>>>>> It misses ResponseCodes, without that swagger ui doesn't work.
>>>>>
>>>>
>>>> Ok, 200/204 should definitely work
>>>>
>>>>
>>>>> Last releases got some work to have it working OOTB so this can likely
>>>>>> be enhanced again if required.
>>>>>>
>>>>> What is OOTB?
>>>>>
>>>>
>>>> out of the box ;)
>>>>
>>>>
>>>>> Also something unclear is if they should appear or not in the openapi
>>>>>> report (we made the choice to do but it is not required AFAIK)
>>>>>>
>>>>>> In my opinion we should keep it, but have at list a basic configure.
>>>>> @ResponseCode 200 should be there as it is the expected response code.
>>>>>
>>>>
>>>> it must be implicit anyway
>>>>
>>>>
>>>>> Another option for tomee would be to enrich the OpenAPI with what it
>>>>>> need, there is the API for that.
>>>>>>
>>>>>> Can you elaborate?
>>>>>
>>>>
>>>> IIRC there is an event fired with OpenAPI model, tomee can observe it
>>>> and add all the doc it needs, including its internal endpoints or tomee
>>>> webapp
>>>>
>>>>
>>>>> Romain Manni-Bucau
>>>>>> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
>>>>>> <https://rmannibucau.metawerx.net/> | Old Blog
>>>>>> <http://rmannibucau.wordpress.com> | Github
>>>>>> <https://github.com/rmannibucau> | LinkedIn
>>>>>> <https://www.linkedin.com/in/rmannibucau> | Book
>>>>>> <https://www.packtpub.com/application-development/java-ee-8-high-performance>
>>>>>>
>>>>>>
>>>>>> Le jeu. 17 janv. 2019 à 14:49, Ivan Junckes Filho <
>>>>>> ivanjunc...@gmail.com> a écrit :
>>>>>>
>>>>>>> Hey guys, I was trying to make the openapi document generated by
>>>>>>> geronimo-openapi to work with swagger-ui. The issue is I can't execute
>>>>>>> requests from swagger-ui in the endpoints generated (metrics, health,
>>>>>>> openapi) by TomEE as they don't have a @ApiResponse annotation and
>>>>>>> swagger-ui doesn't display the message without that.
>>>>>>>
>>>>>>> What do you guys think of having this annotation by default in the
>>>>>>> endpoints? At least for 200?
>>>>>>>
>>>>>>> Or anyone has a better solution for this?
>>>>>>>
>>>>>>


Re: OpenTracing - nullpointer OpenTracingFilter

2019-01-23 Thread Ivan Junckes Filho
Good news, this is not happening in the master. I will close the ticket and
wait for the release.

On Wed, Jan 23, 2019 at 11:16 AM Ivan Junckes Filho 
wrote:

> This is the ticket:
> https://issues.apache.org/jira/browse/TOMEE-2457
>
> This looks like a release blocker in my opinion. I will check the master
> and see how it behaves.
>
> On Tue, Jan 22, 2019 at 3:53 PM Roberto Cortez 
> wrote:
>
>> Hi Ivan,
>>
>> Can you please provide a test case that reproduces the issue? Thank you!
>>
>> Cheers,
>> Roberto
>>
>> > On 22 Jan 2019, at 16:07, Romain Manni-Bucau 
>> wrote:
>> >
>> > Long story short, the MP impl assume CDI is active, if not then tomee
>> but
>> > disable the MP impl.
>> > For us it means disabling also the servlet container initializers. It
>> can
>> > be done in OpenEJBContextConfig or - likely good - implementing a
>> > contextual ConfigSource (reading AppContext#properties for instance) and
>> > forcing geronimo.opentracing.filter.active to false for the webapp (not
>> > globally). Setting the system property you should get the same behavior
>> but
>> > it will be global so some app will not get tracing.
>> > In other word it is the core work tomee must do: integration :).
>> >
>> > Romain Manni-Bucau
>> > @rmannibucau <https://twitter.com/rmannibucau> |  Blog
>> > <https://rmannibucau.metawerx.net/> | Old Blog
>> > <http://rmannibucau.wordpress.com> | Github <
>> https://github.com/rmannibucau> |
>> > LinkedIn <https://www.linkedin.com/in/rmannibucau> | Book
>> > <
>> https://www.packtpub.com/application-development/java-ee-8-high-performance
>> >
>> >
>> >
>> > Le mar. 22 janv. 2019 à 17:03, Ivan Junckes Filho <
>> ivanjunc...@gmail.com> a
>> > écrit :
>> >
>> >> When you say it is a bug in CDI support of TomEE, could you please be
>> more
>> >> specific? Of course if you are aware of what it could be·
>> >>
>> >> On Tue, Jan 22, 2019 at 12:50 PM Romain Manni-Bucau <
>> rmannibu...@gmail.com>
>> >> wrote:
>> >>
>> >>> Hmm, we can add a check in the filter and fail the deployment but at
>> the
>> >>> end it is a bug in CDI support of TomEE so likely saner to fix it in
>> TomEE,
>> >>> right?
>> >>>
>> >>> Romain Manni-Bucau
>> >>> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
>> >>> <https://rmannibucau.metawerx.net/> | Old Blog
>> >>> <http://rmannibucau.wordpress.com> | Github
>> >>> <https://github.com/rmannibucau> | LinkedIn
>> >>> <https://www.linkedin.com/in/rmannibucau> | Book
>> >>> <
>> https://www.packtpub.com/application-development/java-ee-8-high-performance
>> >
>> >>>
>> >>>
>> >>> Le mar. 22 janv. 2019 à 15:37, Ivan Junckes Filho <
>> ivanjunc...@gmail.com>
>> >>> a écrit :
>> >>>
>> >>>> I would say if the extension was not executed for some reason that we
>> >>>> need to know why, we need to make sure the filter doesn't throw that
>> >>>> exception or completely ignore the filter logic right?
>> >>>>
>> >>>> On Tue, Jan 22, 2019 at 12:08 PM Romain Manni-Bucau <
>> >>>> rmannibu...@gmail.com> wrote:
>> >>>>
>> >>>>> Hi Ivan,
>> >>>>>
>> >>>>> This means the opentracing extension was not executed for the app:
>> >>>>>
>> https://github.com/apache/geronimo-opentracing/blob/master/geronimo-opentracing/src/main/java/org/apache/geronimo/microprofile/opentracing/microprofile/cdi/OpenTracingExtension.java#L125
>> >>>>>
>> >>>>> Romain Manni-Bucau
>> >>>>> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
>> >>>>> <https://rmannibucau.metawerx.net/> | Old Blog
>> >>>>> <http://rmannibucau.wordpress.com> | Github
>> >>>>> <https://github.com/rmannibucau> | LinkedIn
>> >>>>> <https://www.linkedin.com/in/rmannibucau> | Book
>> >>>>> <
>> https://www.packtpub.com/application-development/java-ee-8-high-performance
>> >
>> >>>>>
>> >>>>>
>> >>>>> Le mar. 22 janv. 2019 à 14:39, Ivan Junckes Filho <
>> >>>>> ivanjunc...@gmail.com> a écrit :
>> >>>>>
>> >>>>>> Hey guys, I would like some help with an opentracing issue. I am
>> not
>> >>>>>> sure if it was already fixed or not. It was happening on version
>> 1.0.0,
>> >>>>>> current M1 release of TomEE 8.
>> >>>>>>
>> >>>>>> There is a nullpointer happening in OpenTracingFilter and it seems
>> to
>> >>>>>> be because this injection is null.
>> >>>>>>
>> >>>>>> @Inject
>> >>>>>> private GeronimoOpenTracingConfig config;
>> >>>>>>
>> >>>>>> So this line throws the null pointer:
>> >>>>>>
>> >>>>>> skipDefaultTags =
>> Boolean.parseBoolean(config.read("filter.forcedTracing.skipDefaultTags",
>> "false"));
>> >>>>>>
>> >>>>>> Anyone can help with this?
>> >>>>>>
>> >>>>>> Logs are attached.
>> >>>>>>
>> >>>>>>
>> >>>>>>
>>
>>


Re: OpenTracing - nullpointer OpenTracingFilter

2019-01-23 Thread Ivan Junckes Filho
This is the ticket:
https://issues.apache.org/jira/browse/TOMEE-2457

This looks like a release blocker in my opinion. I will check the master
and see how it behaves.

On Tue, Jan 22, 2019 at 3:53 PM Roberto Cortez  wrote:

> Hi Ivan,
>
> Can you please provide a test case that reproduces the issue? Thank you!
>
> Cheers,
> Roberto
>
> > On 22 Jan 2019, at 16:07, Romain Manni-Bucau 
> wrote:
> >
> > Long story short, the MP impl assume CDI is active, if not then tomee but
> > disable the MP impl.
> > For us it means disabling also the servlet container initializers. It can
> > be done in OpenEJBContextConfig or - likely good - implementing a
> > contextual ConfigSource (reading AppContext#properties for instance) and
> > forcing geronimo.opentracing.filter.active to false for the webapp (not
> > globally). Setting the system property you should get the same behavior
> but
> > it will be global so some app will not get tracing.
> > In other word it is the core work tomee must do: integration :).
> >
> > Romain Manni-Bucau
> > @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> > <https://rmannibucau.metawerx.net/> | Old Blog
> > <http://rmannibucau.wordpress.com> | Github <
> https://github.com/rmannibucau> |
> > LinkedIn <https://www.linkedin.com/in/rmannibucau> | Book
> > <
> https://www.packtpub.com/application-development/java-ee-8-high-performance
> >
> >
> >
> > Le mar. 22 janv. 2019 à 17:03, Ivan Junckes Filho 
> a
> > écrit :
> >
> >> When you say it is a bug in CDI support of TomEE, could you please be
> more
> >> specific? Of course if you are aware of what it could be·
> >>
> >> On Tue, Jan 22, 2019 at 12:50 PM Romain Manni-Bucau <
> rmannibu...@gmail.com>
> >> wrote:
> >>
> >>> Hmm, we can add a check in the filter and fail the deployment but at
> the
> >>> end it is a bug in CDI support of TomEE so likely saner to fix it in
> TomEE,
> >>> right?
> >>>
> >>> Romain Manni-Bucau
> >>> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> >>> <https://rmannibucau.metawerx.net/> | Old Blog
> >>> <http://rmannibucau.wordpress.com> | Github
> >>> <https://github.com/rmannibucau> | LinkedIn
> >>> <https://www.linkedin.com/in/rmannibucau> | Book
> >>> <
> https://www.packtpub.com/application-development/java-ee-8-high-performance
> >
> >>>
> >>>
> >>> Le mar. 22 janv. 2019 à 15:37, Ivan Junckes Filho <
> ivanjunc...@gmail.com>
> >>> a écrit :
> >>>
> >>>> I would say if the extension was not executed for some reason that we
> >>>> need to know why, we need to make sure the filter doesn't throw that
> >>>> exception or completely ignore the filter logic right?
> >>>>
> >>>> On Tue, Jan 22, 2019 at 12:08 PM Romain Manni-Bucau <
> >>>> rmannibu...@gmail.com> wrote:
> >>>>
> >>>>> Hi Ivan,
> >>>>>
> >>>>> This means the opentracing extension was not executed for the app:
> >>>>>
> https://github.com/apache/geronimo-opentracing/blob/master/geronimo-opentracing/src/main/java/org/apache/geronimo/microprofile/opentracing/microprofile/cdi/OpenTracingExtension.java#L125
> >>>>>
> >>>>> Romain Manni-Bucau
> >>>>> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> >>>>> <https://rmannibucau.metawerx.net/> | Old Blog
> >>>>> <http://rmannibucau.wordpress.com> | Github
> >>>>> <https://github.com/rmannibucau> | LinkedIn
> >>>>> <https://www.linkedin.com/in/rmannibucau> | Book
> >>>>> <
> https://www.packtpub.com/application-development/java-ee-8-high-performance
> >
> >>>>>
> >>>>>
> >>>>> Le mar. 22 janv. 2019 à 14:39, Ivan Junckes Filho <
> >>>>> ivanjunc...@gmail.com> a écrit :
> >>>>>
> >>>>>> Hey guys, I would like some help with an opentracing issue. I am not
> >>>>>> sure if it was already fixed or not. It was happening on version
> 1.0.0,
> >>>>>> current M1 release of TomEE 8.
> >>>>>>
> >>>>>> There is a nullpointer happening in OpenTracingFilter and it seems
> to
> >>>>>> be because this injection is null.
> >>>>>>
> >>>>>> @Inject
> >>>>>> private GeronimoOpenTracingConfig config;
> >>>>>>
> >>>>>> So this line throws the null pointer:
> >>>>>>
> >>>>>> skipDefaultTags =
> Boolean.parseBoolean(config.read("filter.forcedTracing.skipDefaultTags",
> "false"));
> >>>>>>
> >>>>>> Anyone can help with this?
> >>>>>>
> >>>>>> Logs are attached.
> >>>>>>
> >>>>>>
> >>>>>>
>
>


Re: OpenTracing - nullpointer OpenTracingFilter

2019-01-22 Thread Ivan Junckes Filho
When you say it is a bug in CDI support of TomEE, could you please be more
specific? Of course if you are aware of what it could be·

On Tue, Jan 22, 2019 at 12:50 PM Romain Manni-Bucau 
wrote:

> Hmm, we can add a check in the filter and fail the deployment but at the
> end it is a bug in CDI support of TomEE so likely saner to fix it in TomEE,
> right?
>
> Romain Manni-Bucau
> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> <https://rmannibucau.metawerx.net/> | Old Blog
> <http://rmannibucau.wordpress.com> | Github
> <https://github.com/rmannibucau> | LinkedIn
> <https://www.linkedin.com/in/rmannibucau> | Book
> <https://www.packtpub.com/application-development/java-ee-8-high-performance>
>
>
> Le mar. 22 janv. 2019 à 15:37, Ivan Junckes Filho 
> a écrit :
>
>> I would say if the extension was not executed for some reason that we
>> need to know why, we need to make sure the filter doesn't throw that
>> exception or completely ignore the filter logic right?
>>
>> On Tue, Jan 22, 2019 at 12:08 PM Romain Manni-Bucau <
>> rmannibu...@gmail.com> wrote:
>>
>>> Hi Ivan,
>>>
>>> This means the opentracing extension was not executed for the app:
>>> https://github.com/apache/geronimo-opentracing/blob/master/geronimo-opentracing/src/main/java/org/apache/geronimo/microprofile/opentracing/microprofile/cdi/OpenTracingExtension.java#L125
>>>
>>> Romain Manni-Bucau
>>> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
>>> <https://rmannibucau.metawerx.net/> | Old Blog
>>> <http://rmannibucau.wordpress.com> | Github
>>> <https://github.com/rmannibucau> | LinkedIn
>>> <https://www.linkedin.com/in/rmannibucau> | Book
>>> <https://www.packtpub.com/application-development/java-ee-8-high-performance>
>>>
>>>
>>> Le mar. 22 janv. 2019 à 14:39, Ivan Junckes Filho 
>>> a écrit :
>>>
>>>> Hey guys, I would like some help with an opentracing issue. I am not
>>>> sure if it was already fixed or not. It was happening on version 1.0.0,
>>>> current M1 release of TomEE 8.
>>>>
>>>> There is a nullpointer happening in OpenTracingFilter and it seems to
>>>> be because this injection is null.
>>>>
>>>> @Inject
>>>> private GeronimoOpenTracingConfig config;
>>>>
>>>> So this line throws the null pointer:
>>>>
>>>> skipDefaultTags = 
>>>> Boolean.parseBoolean(config.read("filter.forcedTracing.skipDefaultTags", 
>>>> "false"));
>>>>
>>>> Anyone can help with this?
>>>>
>>>> Logs are attached.
>>>>
>>>>
>>>>


Re: OpenTracing - nullpointer OpenTracingFilter

2019-01-22 Thread Ivan Junckes Filho
I would say if the extension was not executed for some reason that we need
to know why, we need to make sure the filter doesn't throw that exception
or completely ignore the filter logic right?

On Tue, Jan 22, 2019 at 12:08 PM Romain Manni-Bucau 
wrote:

> Hi Ivan,
>
> This means the opentracing extension was not executed for the app:
> https://github.com/apache/geronimo-opentracing/blob/master/geronimo-opentracing/src/main/java/org/apache/geronimo/microprofile/opentracing/microprofile/cdi/OpenTracingExtension.java#L125
>
> Romain Manni-Bucau
> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> <https://rmannibucau.metawerx.net/> | Old Blog
> <http://rmannibucau.wordpress.com> | Github
> <https://github.com/rmannibucau> | LinkedIn
> <https://www.linkedin.com/in/rmannibucau> | Book
> <https://www.packtpub.com/application-development/java-ee-8-high-performance>
>
>
> Le mar. 22 janv. 2019 à 14:39, Ivan Junckes Filho 
> a écrit :
>
>> Hey guys, I would like some help with an opentracing issue. I am not sure
>> if it was already fixed or not. It was happening on version 1.0.0, current
>> M1 release of TomEE 8.
>>
>> There is a nullpointer happening in OpenTracingFilter and it seems to be
>> because this injection is null.
>>
>> @Inject
>> private GeronimoOpenTracingConfig config;
>>
>> So this line throws the null pointer:
>>
>> skipDefaultTags = 
>> Boolean.parseBoolean(config.read("filter.forcedTracing.skipDefaultTags", 
>> "false"));
>>
>> Anyone can help with this?
>>
>> Logs are attached.
>>
>>
>>


OpenTracing - nullpointer OpenTracingFilter

2019-01-22 Thread Ivan Junckes Filho
Hey guys, I would like some help with an opentracing issue. I am not sure
if it was already fixed or not. It was happening on version 1.0.0, current
M1 release of TomEE 8.

There is a nullpointer happening in OpenTracingFilter and it seems to be
because this injection is null.

@Inject
private GeronimoOpenTracingConfig config;

So this line throws the null pointer:

skipDefaultTags =
Boolean.parseBoolean(config.read("filter.forcedTracing.skipDefaultTags",
"false"));

Anyone can help with this?

Logs are attached.
jan 18, 2019 5:46:35 PM sun.reflect.NativeMethodAccessorImpl invoke
ADVERTÊNCIA: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting 
property 'source' to 
'org.eclipse.jst.jee.server:crvirtual-gerenciador-services' did not find a 
matching property.
jan 18, 2019 5:46:35 PM sun.reflect.NativeMethodAccessorImpl invoke
INFORMAÇÕES: Server version:Apache Tomcat (TomEE)/9.0.12 (8.0.0-M1)
jan 18, 2019 5:46:35 PM sun.reflect.NativeMethodAccessorImpl invoke
INFORMAÇÕES: Server built:  Sep 4 2018 22:13:41 UTC
jan 18, 2019 5:46:35 PM sun.reflect.NativeMethodAccessorImpl invoke
INFORMAÇÕES: Server number: 9.0.12.0
jan 18, 2019 5:46:35 PM sun.reflect.NativeMethodAccessorImpl invoke
INFORMAÇÕES: OS Name:   Windows 10
jan 18, 2019 5:46:35 PM sun.reflect.NativeMethodAccessorImpl invoke
INFORMAÇÕES: OS Version:10.0
jan 18, 2019 5:46:35 PM sun.reflect.NativeMethodAccessorImpl invoke
INFORMAÇÕES: Architecture:  amd64
jan 18, 2019 5:46:35 PM sun.reflect.NativeMethodAccessorImpl invoke
INFORMAÇÕES: Java Home: C:\Program Files\Java\jdk1.8.0_191\jre
jan 18, 2019 5:46:35 PM sun.reflect.NativeMethodAccessorImpl invoke
INFORMAÇÕES: JVM Version:   1.8.0_191-b12
jan 18, 2019 5:46:35 PM sun.reflect.NativeMethodAccessorImpl invoke
INFORMAÇÕES: JVM Vendor:Oracle Corporation
jan 18, 2019 5:46:35 PM sun.reflect.NativeMethodAccessorImpl invoke
INFORMAÇÕES: CATALINA_BASE: 
C:\Users\rsv.guima\servers\apache-tomee-microprofile-8.0.0-M1
jan 18, 2019 5:46:35 PM sun.reflect.NativeMethodAccessorImpl invoke
INFORMAÇÕES: CATALINA_HOME: 
C:\Users\rsv.guima\servers\apache-tomee-microprofile-8.0.0-M1
jan 18, 2019 5:46:35 PM sun.reflect.NativeMethodAccessorImpl invoke
INFORMAÇÕES: Command line argument: 
-Dcatalina.base=C:\Users\rsv.guima\servers\apache-tomee-microprofile-8.0.0-M1
jan 18, 2019 5:46:35 PM sun.reflect.NativeMethodAccessorImpl invoke
INFORMAÇÕES: Command line argument: 
-Dcatalina.home=C:\Users\rsv.guima\servers\apache-tomee-microprofile-8.0.0-M1
jan 18, 2019 5:46:35 PM sun.reflect.NativeMethodAccessorImpl invoke
INFORMAÇÕES: Command line argument: 
-Dwtp.deploy=C:\Users\rsv.guima\servers\apache-tomee-microprofile-8.0.0-M1\wtpwebapps
jan 18, 2019 5:46:35 PM sun.reflect.NativeMethodAccessorImpl invoke
INFORMAÇÕES: Command line argument: 
-Djava.endorsed.dirs=C:\Users\rsv.guima\servers\apache-tomee-microprofile-8.0.0-M1\endorsed
jan 18, 2019 5:46:35 PM sun.reflect.NativeMethodAccessorImpl invoke
INFORMAÇÕES: Command line argument: -Dfile.encoding=Cp1252
jan 18, 2019 5:46:35 PM sun.reflect.DelegatingMethodAccessorImpl invoke
INFORMAÇÕES: The APR based Apache Tomcat Native library which allows optimal 
performance in production environments was not found on the java.library.path: 
[C:\Program 
Files\Java\jdk1.8.0_191\bin;C:\WINDOWS\Sun\Java\bin;C:\WINDOWS\system32;C:\WINDOWS;C:/Program
 Files/Java/jre1.8.0_191/bin/server;C:/Program 
Files/Java/jre1.8.0_191/bin;C:/Program 
Files/Java/jre1.8.0_191/lib/amd64;C:\Program Files (x86)\Common 
Files\Oracle\Java\javapath;C:\Program Files (x86)\Intel\iCLS Client\;C:\Program 
Files\Intel\iCLS 
Client\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\Program
 Files (x86)\Intel\Intel(R) Management Engine Components\DAL;C:\Program 
Files\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files 
(x86)\Intel\Intel(R) Management Engine Components\IPT;C:\Program 
Files\Intel\Intel(R) Management Engine Components\IPT;C:\Program 
Files\PuTTY\;C:\WINDOWS\System32\OpenSSH\;C:\Program Files 
(x86)\Java\jre6\bin;C:\Program 
Files\Git\cmd;C:\Users\rsv.guima\AppData\Local\Microsoft\WindowsApps;C:\Users\rsv.guima\AppData\Local\Programs\Git\cmd;C:\WINDOWS\system32;;.]
jan 18, 2019 5:46:36 PM sun.reflect.DelegatingMethodAccessorImpl invoke
INFORMAÇÕES: Initializing ProtocolHandler ["http-nio-8080"]
jan 18, 2019 5:46:36 PM sun.reflect.DelegatingMethodAccessorImpl invoke
INFORMAÇÕES: Using a shared selector for servlet write/read
jan 18, 2019 5:46:36 PM sun.reflect.DelegatingMethodAccessorImpl invoke
INFORMAÇÕES: Initializing ProtocolHandler ["ajp-nio-8009"]
jan 18, 2019 5:46:36 PM sun.reflect.DelegatingMethodAccessorImpl invoke
INFORMAÇÕES: Using a shared selector for servlet write/read
jan 18, 2019 5:46:37 PM org.apache.openejb.util.OptionsLog info
INFORMAÇÕES: Using 
'openejb.jdbc.datasource-creator=org.apache.tomee.jdbc.TomEEDataSour

Re: OpenAPI integration with metrics/health

2019-01-18 Thread Ivan Junckes Filho
Thanks Romain, I will have a look.

On Fri, Jan 18, 2019 at 10:41 AM Romain Manni-Bucau 
wrote:

> You can use:
>
> void start(@Observes @intiialzed(ApplicationScoped.class) Object event,
> final GeronimoOpenAPIExtension ext, final Application app) {
>   final OpenAPI openapi = ext.getOrCreateOpenAPI(app);
> }
>
> if you have a single app or collect them in the extension and call the
> same method for all of them
>
> Romain Manni-Bucau
> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> <https://rmannibucau.metawerx.net/> | Old Blog
> <http://rmannibucau.wordpress.com> | Github
> <https://github.com/rmannibucau> | LinkedIn
> <https://www.linkedin.com/in/rmannibucau> | Book
> <https://www.packtpub.com/application-development/java-ee-8-high-performance>
>
>
> Le ven. 18 janv. 2019 à 13:00, Ivan Junckes Filho 
> a écrit :
>
>> Cool I will have a look next week. Can you point out which event is it?
>>
>> On Thu, Jan 17, 2019 at 1:52 PM Romain Manni-Bucau 
>> wrote:
>>
>>>
>>>
>>>
>>> Le jeu. 17 janv. 2019 à 16:49, Ivan Junckes Filho 
>>> a écrit :
>>>
>>>> On Thu, Jan 17, 2019 at 12:11 PM Romain Manni-Bucau <
>>>> rmannibu...@gmail.com> wrote:
>>>>
>>>>> I would prefer to not leak specs between them since they are used
>>>>> without the others today.
>>>>>
>>>>> What is missing for it to work, returned types are explicit no?
>>>>>
>>>> It misses ResponseCodes, without that swagger ui doesn't work.
>>>>
>>>
>>> Ok, 200/204 should definitely work
>>>
>>>
>>>> Last releases got some work to have it working OOTB so this can likely
>>>>> be enhanced again if required.
>>>>>
>>>> What is OOTB?
>>>>
>>>
>>> out of the box ;)
>>>
>>>
>>>> Also something unclear is if they should appear or not in the openapi
>>>>> report (we made the choice to do but it is not required AFAIK)
>>>>>
>>>>> In my opinion we should keep it, but have at list a basic configure.
>>>> @ResponseCode 200 should be there as it is the expected response code.
>>>>
>>>
>>> it must be implicit anyway
>>>
>>>
>>>> Another option for tomee would be to enrich the OpenAPI with what it
>>>>> need, there is the API for that.
>>>>>
>>>>> Can you elaborate?
>>>>
>>>
>>> IIRC there is an event fired with OpenAPI model, tomee can observe it
>>> and add all the doc it needs, including its internal endpoints or tomee
>>> webapp
>>>
>>>
>>>> Romain Manni-Bucau
>>>>> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
>>>>> <https://rmannibucau.metawerx.net/> | Old Blog
>>>>> <http://rmannibucau.wordpress.com> | Github
>>>>> <https://github.com/rmannibucau> | LinkedIn
>>>>> <https://www.linkedin.com/in/rmannibucau> | Book
>>>>> <https://www.packtpub.com/application-development/java-ee-8-high-performance>
>>>>>
>>>>>
>>>>> Le jeu. 17 janv. 2019 à 14:49, Ivan Junckes Filho <
>>>>> ivanjunc...@gmail.com> a écrit :
>>>>>
>>>>>> Hey guys, I was trying to make the openapi document generated by
>>>>>> geronimo-openapi to work with swagger-ui. The issue is I can't execute
>>>>>> requests from swagger-ui in the endpoints generated (metrics, health,
>>>>>> openapi) by TomEE as they don't have a @ApiResponse annotation and
>>>>>> swagger-ui doesn't display the message without that.
>>>>>>
>>>>>> What do you guys think of having this annotation by default in the
>>>>>> endpoints? At least for 200?
>>>>>>
>>>>>> Or anyone has a better solution for this?
>>>>>>
>>>>>


Re: OpenAPI integration with metrics/health

2019-01-18 Thread Ivan Junckes Filho
Cool I will have a look next week. Can you point out which event is it?

On Thu, Jan 17, 2019 at 1:52 PM Romain Manni-Bucau 
wrote:

>
>
>
> Le jeu. 17 janv. 2019 à 16:49, Ivan Junckes Filho 
> a écrit :
>
>> On Thu, Jan 17, 2019 at 12:11 PM Romain Manni-Bucau <
>> rmannibu...@gmail.com> wrote:
>>
>>> I would prefer to not leak specs between them since they are used
>>> without the others today.
>>>
>>> What is missing for it to work, returned types are explicit no?
>>>
>> It misses ResponseCodes, without that swagger ui doesn't work.
>>
>
> Ok, 200/204 should definitely work
>
>
>> Last releases got some work to have it working OOTB so this can likely be
>>> enhanced again if required.
>>>
>> What is OOTB?
>>
>
> out of the box ;)
>
>
>> Also something unclear is if they should appear or not in the openapi
>>> report (we made the choice to do but it is not required AFAIK)
>>>
>>> In my opinion we should keep it, but have at list a basic configure.
>> @ResponseCode 200 should be there as it is the expected response code.
>>
>
> it must be implicit anyway
>
>
>> Another option for tomee would be to enrich the OpenAPI with what it
>>> need, there is the API for that.
>>>
>>> Can you elaborate?
>>
>
> IIRC there is an event fired with OpenAPI model, tomee can observe it and
> add all the doc it needs, including its internal endpoints or tomee webapp
>
>
>> Romain Manni-Bucau
>>> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
>>> <https://rmannibucau.metawerx.net/> | Old Blog
>>> <http://rmannibucau.wordpress.com> | Github
>>> <https://github.com/rmannibucau> | LinkedIn
>>> <https://www.linkedin.com/in/rmannibucau> | Book
>>> <https://www.packtpub.com/application-development/java-ee-8-high-performance>
>>>
>>>
>>> Le jeu. 17 janv. 2019 à 14:49, Ivan Junckes Filho 
>>> a écrit :
>>>
>>>> Hey guys, I was trying to make the openapi document generated by
>>>> geronimo-openapi to work with swagger-ui. The issue is I can't execute
>>>> requests from swagger-ui in the endpoints generated (metrics, health,
>>>> openapi) by TomEE as they don't have a @ApiResponse annotation and
>>>> swagger-ui doesn't display the message without that.
>>>>
>>>> What do you guys think of having this annotation by default in the
>>>> endpoints? At least for 200?
>>>>
>>>> Or anyone has a better solution for this?
>>>>
>>>


Re: OpenAPI integration with metrics/health

2019-01-17 Thread Ivan Junckes Filho
On Thu, Jan 17, 2019 at 12:11 PM Romain Manni-Bucau 
wrote:

> I would prefer to not leak specs between them since they are used without
> the others today.
>
> What is missing for it to work, returned types are explicit no?
>
It misses ResponseCodes, without that swagger ui doesn't work.

> Last releases got some work to have it working OOTB so this can likely be
> enhanced again if required.
>
What is OOTB?

> Also something unclear is if they should appear or not in the openapi
> report (we made the choice to do but it is not required AFAIK)
>
> In my opinion we should keep it, but have at list a basic configure.
@ResponseCode 200 should be there as it is the expected response code.

> Another option for tomee would be to enrich the OpenAPI with what it need,
> there is the API for that.
>
> Can you elaborate?

> Romain Manni-Bucau
> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> <https://rmannibucau.metawerx.net/> | Old Blog
> <http://rmannibucau.wordpress.com> | Github
> <https://github.com/rmannibucau> | LinkedIn
> <https://www.linkedin.com/in/rmannibucau> | Book
> <https://www.packtpub.com/application-development/java-ee-8-high-performance>
>
>
> Le jeu. 17 janv. 2019 à 14:49, Ivan Junckes Filho 
> a écrit :
>
>> Hey guys, I was trying to make the openapi document generated by
>> geronimo-openapi to work with swagger-ui. The issue is I can't execute
>> requests from swagger-ui in the endpoints generated (metrics, health,
>> openapi) by TomEE as they don't have a @ApiResponse annotation and
>> swagger-ui doesn't display the message without that.
>>
>> What do you guys think of having this annotation by default in the
>> endpoints? At least for 200?
>>
>> Or anyone has a better solution for this?
>>
>


OpenAPI integration with metrics/health

2019-01-17 Thread Ivan Junckes Filho
Hey guys, I was trying to make the openapi document generated by
geronimo-openapi to work with swagger-ui. The issue is I can't execute
requests from swagger-ui in the endpoints generated (metrics, health,
openapi) by TomEE as they don't have a @ApiResponse annotation and
swagger-ui doesn't display the message without that.

What do you guys think of having this annotation by default in the
endpoints? At least for 200?

Or anyone has a better solution for this?


Re: Geronimo OpenAPI maven plugin coming changes

2019-01-10 Thread Ivan Junckes Filho
If I annotate this to give the general info about the app it doesn't work
in the /openapi endpoint.

@OpenAPIDefinition(info = @Info(title = "App Name", version = "1.0"))

I should be opening a ticket soon. I also would like to work on this
when I have time in the future.


On Wed, Jan 9, 2019 at 5:38 PM Romain Manni-Bucau 
wrote:

> Kind of. This part is processed but when using the maven plugin you dont
> always want to even use as provided the mp api to pollute your code with
> that so we can now configure this mandatory part in the pom or defaults are
> provided to generate a valid openapi.json.
>
> Without that info set the openapi.json misses it. I know cxf was used to
> set default wrong values to pass validator but it also exposes wrong data
> so i prefer we generate an invalid doc than swallowing an error.
>
> Is it the issue you are soeaking about? Or did you find another case - i
> know with some ioc lib proxies can swallow annotation but i guess you
> tested on tomee so it should be fine?
>
> Le mer. 9 janv. 2019 18:38, Ivan Junckes Filho  a
> écrit :
>
>> Hey Romain, when you say info are you talking about the annotations
>> below? I was planning to open an issue to have that information in the open
>> api document. Is this the same issue?
>>
>> @OpenAPIDefinition(info = @Info(title = "App Name", version = "1.0"))
>>
>>
>>
>>
>> On Wed, Jan 9, 2019 at 7:47 AM Romain Manni-Bucau 
>> wrote:
>>
>>> Hi guys,
>>>
>>> I'm planning to enable to configure info part of the maven plugin for
>>> openapi today + add a few fixes for implicit configuration for returned
>>> types (they are not always populated)
>>> Then I'm planning to launch a release, any objection?
>>>
>>> Romain Manni-Bucau
>>> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
>>> <https://rmannibucau.metawerx.net/> | Old Blog
>>> <http://rmannibucau.wordpress.com> | Github
>>> <https://github.com/rmannibucau> | LinkedIn
>>> <https://www.linkedin.com/in/rmannibucau> | Book
>>> <https://www.packtpub.com/application-development/java-ee-8-high-performance>
>>>
>>


Re: [VOTE] Release Apache Microprofile Aggregator 1.0.1

2019-01-10 Thread Ivan Junckes Filho
+1

On Thu, Jan 10, 2019 at 3:03 AM Jean-Baptiste Onofré 
wrote:

> +1 (non binding)
>
> Regards
> JB
>
> On 09/01/2019 14:17, Romain Manni-Bucau wrote:
> > Hi guys,
> >
> > Here is the annouced vote for our microprofile aggregator project. Here
> > are the fixed issues:
> >
> > P T   Key Summary AssigneeStatus  Development
> > Major Bug GERONIMO-6668
> >  OpenAPI version
> > requires jackson but it is not provided
> >  Romain Manni-Bucau
> > <
> https://issues.apache.org/jira/secure/ViewProfile.jspa?name=romain.manni-bucau
> >
> > RESOLVED
> > Major Bug GERONIMO-6669
> >  utilda packaging
> > include unneeded artifacts (javax)
> >  Romain Manni-Bucau
> > <
> https://issues.apache.org/jira/secure/ViewProfile.jspa?name=romain.manni-bucau
> >
> > RESOLVED
> > Major Improvement GERONIMO-6671
> >  Use
> > Geronimo-metrics 1.0.2
> >  Romain Manni-Bucau
> > <
> https://issues.apache.org/jira/secure/ViewProfile.jspa?name=romain.manni-bucau
> >
> > RESOLVED
> > Major Improvement GERONIMO-6672
> >  Use
> > Geronimo-openapi 1.0.4
> >  Romain Manni-Bucau
> > <
> https://issues.apache.org/jira/secure/ViewProfile.jspa?name=romain.manni-bucau
> >
> > RESOLVED
> > Major New Feature GERONIMO-6673
> >  Minimal debug UI
> > for metrics, opentracing and health
> >  Romain Manni-Bucau
> > <
> https://issues.apache.org/jira/secure/ViewProfile.jspa?name=romain.manni-bucau
> >
> > RESOLVED
> > Major Improvement GERONIMO-6678
> >  Upgrade Meecrowave
> > to 1.2.5 
> Romain
> > Manni-Bucau
> > <
> https://issues.apache.org/jira/secure/ViewProfile.jspa?name=romain.manni-bucau
> >
> > RESOLVED
> >
> >
> > It mainly fixes openapi version of the bom - transitively utilda distro
> > - and also brings the new UI module to the game.
> >
> > The staging repository is available
> > at:
> https://repository.apache.org/content/repositories/orgapachegeronimo-1086
> > Tag can be found
> > at:
> https://gitbox.apache.org/repos/asf?p=geronimo-microprofile.git;a=commit;h=f2bb7cff63dd0098260a8de988509e27f6eb5a46
> > Sources are
> > in:
> https://repository.apache.org/content/repositories/orgapachegeronimo-1086/org/apache/geronimo/geronimo-microprofile/1.0.1/
> >
> > Note: this vote depends on meecrowave and openapi releases indeed.
> >
> > Please vote:
> >
> > [ ] +1 let it go out
> > [ ] -1, cause ${blocker}
> >
> > Vote will be opened for 72h as usual
> >
> > Romain Manni-Bucau
> > @rmannibucau  |  Blog
> >  | Old Blog
> >  | Github
> >  | LinkedIn
> >  | Book
> > <
> https://www.packtpub.com/application-development/java-ee-8-high-performance
> >
>
> --
> Jean-Baptiste Onofré
> jbono...@apache.org
> http://blog.nanthrax.net
> Talend - http://www.talend.com
>


Re: [VOTE] Release Apache Geronimo OpenAPI 1.0.4 (take 2 - enum fix included)

2019-01-10 Thread Ivan Junckes Filho
+1

On Thu, Jan 10, 2019 at 3:02 AM Jean-Baptiste Onofré 
wrote:

> +1 (non binding)
>
> Regards
> JB
>
> On 09/01/2019 14:09, Romain Manni-Bucau wrote:
> > Hi guys,
> >
> > We already have a few fixes which can be blocker for some users so i'd
> > like to release our MP openapi impl. Here are the issues we fixed - and
> > the enum fix i mentionned in previous vote is in:
> >
> > P T   Key Summary AssigneeStatus  Development
> > Major Improvement GERONIMO-6675
> >  Enable to
> > configure info in OpenAPI maven plugin
> >  Romain Manni-Bucau
> > <
> https://issues.apache.org/jira/secure/ViewProfile.jspa?name=romain.manni-bucau
> >
> > RESOLVED
> > Major Improvement GERONIMO-6676
> > 
> > @Schema(type=ARRAY) is wrongly mapped
> >  Romain Manni-Bucau
> > <
> https://issues.apache.org/jira/secure/ViewProfile.jspa?name=romain.manni-bucau
> >
> > RESOLVED
> > Major Improvement GERONIMO-6677
> >  Implicit class
> > mapping is rarely filled properly
> >  Romain Manni-Bucau
> > <
> https://issues.apache.org/jira/secure/ViewProfile.jspa?name=romain.manni-bucau
> >
> > RESOLVED
> > Minor Improvement GERONIMO-6670
> >  When /openapi is
> > requested with a mediatype the server does not support the response
> > serialization fails
> >  Romain Manni-Bucau
> > <
> https://issues.apache.org/jira/secure/ViewProfile.jspa?name=romain.manni-bucau
> >
> > RESOLVED
> >
> >
> > The staging repository is available
> > at:
> https://repository.apache.org/content/repositories/orgapachegeronimo-1085
> > Tag can be found
> > at:
> https://gitbox.apache.org/repos/asf?p=geronimo-openapi.git;a=commit;h=51fa5bcce919594f33dc50d3259b56e730ae0c21
> > Sources are
> > in:
> https://repository.apache.org/content/repositories/orgapachegeronimo-1085/org/apache/geronimo/geronimo-openapi/1.0.4/
> >
> > Please vote:
> >
> > [ ] +1 let it go out
> > [ ] -1, cause ${blocker}
> >
> > Vote will be opened for 72h as usual
> >
> > Romain Manni-Bucau
> > @rmannibucau  |  Blog
> >  | Old Blog
> >  | Github
> >  | LinkedIn
> >  | Book
> > <
> https://www.packtpub.com/application-development/java-ee-8-high-performance
> >
>
> --
> Jean-Baptiste Onofré
> jbono...@apache.org
> http://blog.nanthrax.net
> Talend - http://www.talend.com
>


Re: Geronimo OpenAPI maven plugin coming changes

2019-01-09 Thread Ivan Junckes Filho
Hey Romain, when you say info are you talking about the annotations below?
I was planning to open an issue to have that information in the open api
document. Is this the same issue?

@OpenAPIDefinition(info = @Info(title = "App Name", version = "1.0"))




On Wed, Jan 9, 2019 at 7:47 AM Romain Manni-Bucau 
wrote:

> Hi guys,
>
> I'm planning to enable to configure info part of the maven plugin for
> openapi today + add a few fixes for implicit configuration for returned
> types (they are not always populated)
> Then I'm planning to launch a release, any objection?
>
> Romain Manni-Bucau
> @rmannibucau  |  Blog
>  | Old Blog
>  | Github
>  | LinkedIn
>  | Book
> 
>


Re: Ability for my changes to go in

2019-01-09 Thread Ivan Junckes Filho
Ok, I understand. But please avoid that, because it doesn't help new
contributors to join the project.

Now that I am a father my kid helps me to better understand some new
things. I bought a kid's broom for my daughter and the other day I was
sweeping the house and she got the broom to help. She wasn't really helping
at all, she was walking over the dust and spreading it... but she was there
with me and at some point she will start to realize that and be able to
help without making a mess. If I did it for her just because she is slow or
doesn't bring the result it could be, she would probably never learn or
help. I understand we are driven for results, but sometimes slowing down a
bit and think the long term can be successful.

Got a bit thoughtful here... hehehe but I think it helps us to think of how
we can do better :)

And btw, thanks for reaching out privately and offer a ticket for me to
work on. That was nice of you!





On Tue, Jan 8, 2019 at 4:19 PM Romain Manni-Bucau 
wrote:

> Hi Ivan
>
> Indeed it does but fix was quite straight forward and i was planning a
> release on sunday - but got some "box" issues on saturday and a good part
> of sunday so i didnt manage to make it. Rational was to include it in
> microprofile repo release. If I can I will proceed later this week.
>
> On the process Im fine with whatever works the best and doesnt slow down
> too much dependencies. Guess the fixes we got last week - and why mp repo
> must be rereleased - + the fact it happens over a weekend for you was a no
> luck case here. Also being more vocal on the dev list can help since we are
> list driven and not github driven - just thinking out loud. At least it
> would have enabled to 1. know you were going to work on that and 2. guide
> you earlier and avoid to ask you to rework the pr probably. Wdyt?
>
> Romain
>
>
> Le mar. 8 janv. 2019 18:56, Ivan Junckes Filho  a
> écrit :
>
>> Hey Romain, I see your comments with feedback in the PR I opened, thank
>> you for that. I had a busy weekend and couldn't reply immediately.
>> https://github.com/apache/geronimo-openapi/pull/4
>>
>> But I saw also in the PR that there were some conflicts and the change
>> was incorporated in the master differently, maybe a better way than my
>> approach.
>>
>> I think we should change the way this is done because I would rather
>> receive feedback and change my PR  than have the change on master done by
>> somebody else. Geronimo-openapi is a project with "1 Contributor" I was
>> trying to become the second one.
>>
>> Does this make sense?
>>
>


Ability for my changes to go in

2019-01-08 Thread Ivan Junckes Filho
Hey Romain, I see your comments with feedback in the PR I opened, thank you
for that. I had a busy weekend and couldn't reply immediately.
https://github.com/apache/geronimo-openapi/pull/4

But I saw also in the PR that there were some conflicts and the change was
incorporated in the master differently, maybe a better way than my approach.

I think we should change the way this is done because I would rather
receive feedback and change my PR  than have the change on master done by
somebody else. Geronimo-openapi is a project with "1 Contributor" I was
trying to become the second one.

Does this make sense?


Re: TOMEE-2289

2019-01-04 Thread Ivan Junckes Filho
FYI I opened a PR on geronimo to fix the issue with text/html.

https://github.com/apache/geronimo-openapi/pull/4

Postman was working because it used */* and the implementation was properly
handling it, but not handling text/html.

On Thu, Jan 3, 2019 at 2:34 PM Ivan Junckes Filho 
wrote:

> Yes, the default content-type for browsers is text/html. I will submit a
> pr accepting that.
>
> On Thu, Jan 3, 2019 at 2:17 PM César Hernández Mendoza <
> cesargu...@gmail.com> wrote:
>
>> This  "default" behavior is also present in Metrics geronimo
>> implementation.
>> The issue is that the spec doesn't explicitly indicate the default
>> content-type requirement.
>>
>> El jue., 3 ene. 2019 a las 9:48, Ivan Junckes Filho (<
>> ivanjunc...@gmail.com>)
>> escribió:
>>
>> > I will take a look and help troubleshoot this.
>> >
>> > On Thu, Jan 3, 2019 at 12:08 PM Puneeth PS 
>> wrote:
>> >
>> > > Hi Ivan,
>> > >
>> > > /openapi works in POSTMAN client but not on browser, so might not be
>> an
>> > > issue.
>> > >
>> > > On Thu, Jan 3, 2019 at 6:38 PM Ivan Junckes Filho <
>> ivanjunc...@gmail.com
>> > >
>> > > wrote:
>> > >
>> > > > Hi Puneeth, I added a couple of more comments.
>> > > >
>> > > > There seems to have a couple of bugs in the openapi implementation.
>> > > >
>> > > > Json serialization bug and also /openapi is not working without the
>> > > header.
>> > > > So we may need to open bugs
>> > > > in https://issues.apache.org/jira/projects/GERONIMO/issues
>> > > > <https://issues.apache.org/jira/projects/GERONIMO/issues>.
>> > > >
>> > > > I will try to help troubleshoot these issues.
>> > > >
>> > > >
>> > > >
>> > > >
>> > > > On Thu, Jan 3, 2019 at 12:53 AM Puneeth PS 
>> > wrote:
>> > > >
>> > > > > Hi Ivan,
>> > > > >
>> > > > > I have made the changes requested and I've some questions
>> regarding
>> > the
>> > > > > spec which I've asked on the github thread, can you please clarify
>> > > these?
>> > > > >
>> > > > > On Wed 2 Jan, 2019, 6:09 PM Ivan Junckes Filho <
>> > ivanjunc...@gmail.com
>> > > > > wrote:
>> > > > >
>> > > > > > Puneeth, I did some comments here
>> > > > > >
>> > https://github.com/apache/tomee/pull/340#pullrequestreview-188661807
>> > > ,
>> > > > > > please take a look.
>> > > > > >
>> > > > > > On Wed, Jan 2, 2019 at 9:51 AM Ivan Junckes Filho <
>> > > > ivanjunc...@gmail.com
>> > > > > >
>> > > > > > wrote:
>> > > > > >
>> > > > > > > Hi Puneeth, I will review it for you.
>> > > > > > >
>> > > > > > > On Wed, Jan 2, 2019 at 8:39 AM Puneeth PS <
>> puneeth...@gmail.com>
>> > > > > wrote:
>> > > > > > >
>> > > > > > >> Hi,
>> > > > > > >>
>> > > > > > >> I have created a PR (
>> https://github.com/apache/tomee/pull/340
>> > )
>> > > > for
>> > > > > > >> TOMEE-2289. Can someone take a look and help me improve it?
>> > > > > > >>
>> > > > > > >
>> > > > > >
>> > > > >
>> > > >
>> > >
>> >
>>
>>
>> --
>> Atentamente:
>> César Hernández Mendoza.
>>
>


[jira] [Created] (GERONIMO-6670) Content-type text/html is returning error on /open

2019-01-04 Thread Ivan Junckes Filho (JIRA)
Ivan Junckes Filho created GERONIMO-6670:


 Summary: Content-type text/html is returning error on /open
 Key: GERONIMO-6670
 URL: https://issues.apache.org/jira/browse/GERONIMO-6670
 Project: Geronimo
  Issue Type: Improvement
  Security Level: public (Regular issues)
Reporter: Ivan Junckes Filho


Content-type text/html is returning this error when used:

No message body writer has been found for class 
org.apache.geronimo.microprofile.openapi.impl.model.OpenAPIImpl, ContentType: 
text/html

This content type is used by browsers, so if the user wants to do a GET 
/openapi in the browser it will display this error.

The ideal scenario is that user must be able to see the default openapi 
document using the browser.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


Re: [VOTE] Apache Geronimo OpenAPI 1.0.3

2019-01-04 Thread Ivan Junckes Filho
+1

On Thu, Jan 3, 2019 at 6:30 PM Mark Struberg  wrote:

> +1
>
> LieGrue,
> strub
>
>
> > Am 02.01.2019 um 16:10 schrieb Romain Manni-Bucau  >:
> >
> > Hi guys,
> >
> > as mentionned here is the vote fore Geronimo OpenAPI 1.0.3 to ensure we
> don't need jackson when using it
> >
> > The staging repo is:
> https://repository.apache.org/content/repositories/orgapachegeronimo-1082
> > My keys is still available in
> http://svn.apache.org/repos/asf/geronimo/KEYS
> > Tag is on the main source repo and sources in the staging repo.
> >
> > This vote is open for 3 days as usual or untll it gets its 3 binding +1s.
> >
> > Romain Manni-Bucau
> > @rmannibucau |  Blog | Old Blog | Github | LinkedIn | Book
>
>


Re: [VOTE] Apache Geronimo Metrics 1.0.2

2019-01-04 Thread Ivan Junckes Filho
+1

On Thu, Jan 3, 2019 at 6:39 PM Mark Struberg  wrote:

> +1
>
> LieGrue,
> strub
>
>
> > Am 02.01.2019 um 16:18 schrieb Romain Manni-Bucau  >:
> >
> > Hi guys,
> >
> > As mentionned here is the vote for Geronimo Metrics 1.0.2 to ensure
> sigar extension does not register twice the same filesystem when multiple
> mount points are present - which prevents the startup of any application
> embedding it.
> >
> > The staging repo is:
> https://repository.apache.org/content/repositories/orgapachegeronimo-1083
> > My keys is still available in
> http://svn.apache.org/repos/asf/geronimo/KEYS
> > Tag is on the main source repo and sources in the staging repo.
> >
> > This vote is open for 3 days as usual or untll it gets its 3 binding +1s.
> >
> > Romain Manni-Bucau
> > @rmannibucau |  Blog | Old Blog | Github | LinkedIn | Book
>
>


Re: Microprofile OpenAPI

2018-11-30 Thread Ivan Junckes Filho
On Fri, Nov 30, 2018 at 2:34 PM Richard Monson-Haefel <
monsonhae...@gmail.com> wrote:

> When you are setting up a MP Rest Client, there are certain annotations
> that are required, right?  Is it possible to have the TomEE code detect
> these MP annotations and change the default to yaml automatically?  That
> way, yaml is only the default if you are communicating with MP-conformant
> systems.  Just looking for a compromise here.
>
I still think this is an alternative and not the standard. Also, I don't
think this would be a good solution to tie this to a microprofile lib.


>
> On Fri, Nov 30, 2018 at 10:25 AM Ivan Junckes Filho  >
> wrote:
>
> > The goal for this is to implement Microprofile Specifications. So what
> the
> > Microprofile community decides is important and needs to be followed. Of
> > course everyone has a voice there and you clearly spoke up there which is
> > great. You think it is not the best approach, but people there until now
> > think it is. So why not respect what they decide?
> >
> > It would be compatible if you put yaml by default and choose to make json
> > default with a property. But making json default and adding extra configs
> > to make yaml default is not what the spec defines.
> >
> > This is the standard:
> > "The default format of the /openapi endpoint is YAML.
> >
> > Anything different than this is what you think is the best and not a
> > consensus in the MicroProfile community. "Stupid" is a very personal
> > opinion and doesn't reflect what people think about it there, neither my
> > opinion.
> >
> > I again, think we should follow what the standard is and change later if
> > the community decides so.
> >
> > On Fri, Nov 30, 2018 at 2:14 PM Romain Manni-Bucau <
> rmannibu...@gmail.com>
> > wrote:
> >
> > > I don't understand why you say so Ivan, it is perfectly compatible.
> > >
> > > Also to answer clearly to your question: I prefer to have an impl not
> > > compatible with the spec when the spec says something stupid, most of
> the
> > > time we put toggle to be able to be compatible but sometimes there is
> not
> > > even a way to be compatible, this is what has been done in TomEE since
> > > years and it works well making users happy rather than spec leads.
> > >
> > > Romain Manni-Bucau
> > > @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> > > <https://rmannibucau.metawerx.net/> | Old Blog
> > > <http://rmannibucau.wordpress.com> | Github
> > > <https://github.com/rmannibucau> | LinkedIn
> > > <https://www.linkedin.com/in/rmannibucau> | Book
> > > <
> >
> https://www.packtpub.com/application-development/java-ee-8-high-performance
> > >
> > >
> > >
> > > Le ven. 30 nov. 2018 à 17:11, Ivan Junckes Filho <
> ivanjunc...@gmail.com>
> > > a écrit :
> > >
> > >> This is against the spec as well, yaml is required and must always be
> > >> default. Do we really want to let our implementation not compatible
> with
> > >> that?
> > >>
> > >> On Fri, Nov 30, 2018 at 2:03 PM Romain Manni-Bucau <
> > rmannibu...@gmail.com>
> > >> wrote:
> > >>
> > >>> If jackson yaml is present it will add a (jackson) writer for yaml,
> if
> > >>> not it stays on json.
> > >>>
> > >>> Romain Manni-Bucau
> > >>> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> > >>> <https://rmannibucau.metawerx.net/> | Old Blog
> > >>> <http://rmannibucau.wordpress.com> | Github
> > >>> <https://github.com/rmannibucau> | LinkedIn
> > >>> <https://www.linkedin.com/in/rmannibucau> | Book
> > >>> <
> >
> https://www.packtpub.com/application-development/java-ee-8-high-performance
> > >
> > >>>
> > >>>
> > >>> Le ven. 30 nov. 2018 à 16:51, Ivan Junckes Filho <
> > ivanjunc...@gmail.com>
> > >>> a écrit :
> > >>>
> > >>>> @Romain Manni-Bucau  not sure I understood
> > you.
> > >>>> Are you saying you will work to make it compatible with the spec?
> > Have yaml
> > >>>> as default?
> > >>>>
> > >>>> On Fri, Nov 30, 2018 at 1:30 PM César Hernández Mendoza <
> > >>>> cesargu...@gmail.com> wrote:
> > >>>>
>

Re: Microprofile OpenAPI

2018-11-30 Thread Ivan Junckes Filho
The goal for this is to implement Microprofile Specifications. So what the
Microprofile community decides is important and needs to be followed. Of
course everyone has a voice there and you clearly spoke up there which is
great. You think it is not the best approach, but people there until now
think it is. So why not respect what they decide?

It would be compatible if you put yaml by default and choose to make json
default with a property. But making json default and adding extra configs
to make yaml default is not what the spec defines.

This is the standard:
"The default format of the /openapi endpoint is YAML.

Anything different than this is what you think is the best and not a
consensus in the MicroProfile community. "Stupid" is a very personal
opinion and doesn't reflect what people think about it there, neither my
opinion.

I again, think we should follow what the standard is and change later if
the community decides so.

On Fri, Nov 30, 2018 at 2:14 PM Romain Manni-Bucau 
wrote:

> I don't understand why you say so Ivan, it is perfectly compatible.
>
> Also to answer clearly to your question: I prefer to have an impl not
> compatible with the spec when the spec says something stupid, most of the
> time we put toggle to be able to be compatible but sometimes there is not
> even a way to be compatible, this is what has been done in TomEE since
> years and it works well making users happy rather than spec leads.
>
> Romain Manni-Bucau
> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> <https://rmannibucau.metawerx.net/> | Old Blog
> <http://rmannibucau.wordpress.com> | Github
> <https://github.com/rmannibucau> | LinkedIn
> <https://www.linkedin.com/in/rmannibucau> | Book
> <https://www.packtpub.com/application-development/java-ee-8-high-performance>
>
>
> Le ven. 30 nov. 2018 à 17:11, Ivan Junckes Filho 
> a écrit :
>
>> This is against the spec as well, yaml is required and must always be
>> default. Do we really want to let our implementation not compatible with
>> that?
>>
>> On Fri, Nov 30, 2018 at 2:03 PM Romain Manni-Bucau 
>> wrote:
>>
>>> If jackson yaml is present it will add a (jackson) writer for yaml, if
>>> not it stays on json.
>>>
>>> Romain Manni-Bucau
>>> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
>>> <https://rmannibucau.metawerx.net/> | Old Blog
>>> <http://rmannibucau.wordpress.com> | Github
>>> <https://github.com/rmannibucau> | LinkedIn
>>> <https://www.linkedin.com/in/rmannibucau> | Book
>>> <https://www.packtpub.com/application-development/java-ee-8-high-performance>
>>>
>>>
>>> Le ven. 30 nov. 2018 à 16:51, Ivan Junckes Filho 
>>> a écrit :
>>>
>>>> @Romain Manni-Bucau  not sure I understood you.
>>>> Are you saying you will work to make it compatible with the spec? Have yaml
>>>> as default?
>>>>
>>>> On Fri, Nov 30, 2018 at 1:30 PM César Hernández Mendoza <
>>>> cesargu...@gmail.com> wrote:
>>>>
>>>>> >
>>>>> > I think regardless of what the MicroProfile team decides, we need to
>>>>> make
>>>>> > it work as the specification says. Then iterate from there.
>>>>> > In my opinion this is a big problem that makes us strongly
>>>>> incompatible
>>>>> > with the standard.
>>>>>
>>>>>
>>>>> +1
>>>>>
>>>>> El vie., 30 nov. 2018 a las 5:44, Ivan Junckes Filho (<
>>>>> ivanjunc...@gmail.com>)
>>>>> escribió:
>>>>>
>>>>> > I think regardless of what the MicroProfile team decides, we need to
>>>>> make
>>>>> > it work as the specification says. Then iterate from there.
>>>>> >
>>>>> > In my opinion this is a big problem that makes us strongly
>>>>> incompatible
>>>>> > with the standard.
>>>>> >
>>>>> > On Fri, Nov 30, 2018 at 3:36 AM Romain Manni-Bucau <
>>>>> rmannibu...@gmail.com>
>>>>> > wrote:
>>>>> >
>>>>> > > Browser and all clients default to */* or octect/stream so the
>>>>> else is
>>>>> > > never used normally and was here just to put a mimetype from an
>>>>> optional.
>>>>> > >
>>>>> > > Browsers even send a kind of "all you can" value (*/*, html, xml at
>>

Re: Microprofile OpenAPI

2018-11-30 Thread Ivan Junckes Filho
This is against the spec as well, yaml is required and must always be
default. Do we really want to let our implementation not compatible with
that?

On Fri, Nov 30, 2018 at 2:03 PM Romain Manni-Bucau 
wrote:

> If jackson yaml is present it will add a (jackson) writer for yaml, if not
> it stays on json.
>
> Romain Manni-Bucau
> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> <https://rmannibucau.metawerx.net/> | Old Blog
> <http://rmannibucau.wordpress.com> | Github
> <https://github.com/rmannibucau> | LinkedIn
> <https://www.linkedin.com/in/rmannibucau> | Book
> <https://www.packtpub.com/application-development/java-ee-8-high-performance>
>
>
> Le ven. 30 nov. 2018 à 16:51, Ivan Junckes Filho 
> a écrit :
>
>> @Romain Manni-Bucau  not sure I understood you.
>> Are you saying you will work to make it compatible with the spec? Have yaml
>> as default?
>>
>> On Fri, Nov 30, 2018 at 1:30 PM César Hernández Mendoza <
>> cesargu...@gmail.com> wrote:
>>
>>> >
>>> > I think regardless of what the MicroProfile team decides, we need to
>>> make
>>> > it work as the specification says. Then iterate from there.
>>> > In my opinion this is a big problem that makes us strongly incompatible
>>> > with the standard.
>>>
>>>
>>> +1
>>>
>>> El vie., 30 nov. 2018 a las 5:44, Ivan Junckes Filho (<
>>> ivanjunc...@gmail.com>)
>>> escribió:
>>>
>>> > I think regardless of what the MicroProfile team decides, we need to
>>> make
>>> > it work as the specification says. Then iterate from there.
>>> >
>>> > In my opinion this is a big problem that makes us strongly incompatible
>>> > with the standard.
>>> >
>>> > On Fri, Nov 30, 2018 at 3:36 AM Romain Manni-Bucau <
>>> rmannibu...@gmail.com>
>>> > wrote:
>>> >
>>> > > Browser and all clients default to */* or octect/stream so the else
>>> is
>>> > > never used normally and was here just to put a mimetype from an
>>> optional.
>>> > >
>>> > > Browsers even send a kind of "all you can" value (*/*, html, xml at
>>> > least).
>>> > >
>>> > > So yes we can make this value confifurable but this never happens.
>>> Ivan's
>>> > > case was even with cxf client which sets a value normally by default
>>> so
>>> > it
>>> > > wouldnt help I think.
>>> > >
>>> > > Le ven. 30 nov. 2018 06:21, John D. Ament  a
>>> > écrit
>>> > > :
>>> > >
>>> > > > The question posed to the MP team does not really match the
>>> question
>>> > > > posted here, and seems to be a tangental ask.
>>> > > >
>>> > > > The problem is this line of code [1], and nothing to do with
>>> TomEE's
>>> > > > behavior; it defaults to JSON even though the spec states it
>>> should be
>>> > > > YAML.  Perhaps a clean solution would be to make this a config
>>> setting?
>>> > > > But seems like there's a missing TCK test as well.  I'd also
>>> question
>>> > > when
>>> > > > a browser goes here, what does it send in the Accepts header.  My
>>> guess
>>> > > is
>>> > > > most modern browsers send text/html which also wouldn't line up.
>>> > > >
>>> > > > John
>>> > > >
>>> > > > [1]:
>>> > > >
>>> > >
>>> >
>>> https://github.com/apache/geronimo-openapi/blob/master/geronimo-openapi-impl/src/main/java/org/apache/geronimo/microprofile/openapi/jaxrs/OpenAPIFilter.java#L57
>>> > > >
>>> > > > On Thu, Nov 29, 2018 at 3:58 PM Romain Manni-Bucau <
>>> > > rmannibu...@gmail.com>
>>> > > > wrote:
>>> > > >
>>> > > >> Response is fine (thanks jaxrs), request is up to jaxrs runtime so
>>> > > >> depends where you deploy it (i dont think implementing a custom
>>> writer
>>> > > for
>>> > > >> that is right for users, it has too much pitfalls once integrated
>>> to
>>> > > >> anything else than this very specific spec).
>>> > > >>
>>> > > >

Re: Microprofile OpenAPI

2018-11-30 Thread Ivan Junckes Filho
@Romain Manni-Bucau  not sure I understood you. Are
you saying you will work to make it compatible with the spec? Have yaml as
default?

On Fri, Nov 30, 2018 at 1:30 PM César Hernández Mendoza <
cesargu...@gmail.com> wrote:

> >
> > I think regardless of what the MicroProfile team decides, we need to make
> > it work as the specification says. Then iterate from there.
> > In my opinion this is a big problem that makes us strongly incompatible
> > with the standard.
>
>
> +1
>
> El vie., 30 nov. 2018 a las 5:44, Ivan Junckes Filho (<
> ivanjunc...@gmail.com>)
> escribió:
>
> > I think regardless of what the MicroProfile team decides, we need to make
> > it work as the specification says. Then iterate from there.
> >
> > In my opinion this is a big problem that makes us strongly incompatible
> > with the standard.
> >
> > On Fri, Nov 30, 2018 at 3:36 AM Romain Manni-Bucau <
> rmannibu...@gmail.com>
> > wrote:
> >
> > > Browser and all clients default to */* or octect/stream so the else is
> > > never used normally and was here just to put a mimetype from an
> optional.
> > >
> > > Browsers even send a kind of "all you can" value (*/*, html, xml at
> > least).
> > >
> > > So yes we can make this value confifurable but this never happens.
> Ivan's
> > > case was even with cxf client which sets a value normally by default so
> > it
> > > wouldnt help I think.
> > >
> > > Le ven. 30 nov. 2018 06:21, John D. Ament  a
> > écrit
> > > :
> > >
> > > > The question posed to the MP team does not really match the question
> > > > posted here, and seems to be a tangental ask.
> > > >
> > > > The problem is this line of code [1], and nothing to do with TomEE's
> > > > behavior; it defaults to JSON even though the spec states it should
> be
> > > > YAML.  Perhaps a clean solution would be to make this a config
> setting?
> > > > But seems like there's a missing TCK test as well.  I'd also question
> > > when
> > > > a browser goes here, what does it send in the Accepts header.  My
> guess
> > > is
> > > > most modern browsers send text/html which also wouldn't line up.
> > > >
> > > > John
> > > >
> > > > [1]:
> > > >
> > >
> >
> https://github.com/apache/geronimo-openapi/blob/master/geronimo-openapi-impl/src/main/java/org/apache/geronimo/microprofile/openapi/jaxrs/OpenAPIFilter.java#L57
> > > >
> > > > On Thu, Nov 29, 2018 at 3:58 PM Romain Manni-Bucau <
> > > rmannibu...@gmail.com>
> > > > wrote:
> > > >
> > > >> Response is fine (thanks jaxrs), request is up to jaxrs runtime so
> > > >> depends where you deploy it (i dont think implementing a custom
> writer
> > > for
> > > >> that is right for users, it has too much pitfalls once integrated to
> > > >> anything else than this very specific spec).
> > > >>
> > > >> Le jeu. 29 nov. 2018 21:39, Jonathan Gallimore <
> > > >> jonathan.gallim...@gmail.com> a écrit :
> > > >>
> > > >>> If the spec requires that, then I'd expect to get a YAML response
> if
> > > >>> making a request without an `Accept` header on the request.
> > > >>>
> > > >>> I haven't looked through the microprofile-openapi TCK, but I'd
> expect
> > > >>> that to be tested, and I'd suggest contributing a test there if
> there
> > > isn't
> > > >>> one.
> > > >>>
> > > >>> If you wanted to explicitly request a YAML response, I'd expect one
> > of
> > > >>> these to work:
> > > >>>
> > > >>> Accept: application/x-yaml
> > > >>> Accept: text/yaml
> > > >>>
> > > >>> I'd expect a Content-Type header on the response to identify the
> mime
> > > >>> type of the response, whatever is being returned.
> > > >>>
> > > >>> Jon
> > > >>>
> > > >>> On Thu, Nov 29, 2018 at 4:50 PM Ivan Junckes Filho <
> > > >>> ivanjunc...@gmail.com> wrote:
> > > >>>
> > > >>>> Hey guys, I think I found a bug in OpenAPI implementation.
> > > >>>>
> > > >>>> The spec says:
> > > >>>> "The default format of the /openapi endpoint is YAML."
> > > >>>>
> > > >>>> But when I try to access /openapi it returns JSON by default.
> > > >>>>
> > > >>>> This is not correct.
> > > >>>>
> > > >>>> Also how can I access yaml if it is not default?
> > > >>>>
> > > >>>
> > >
> >
>
>
> --
> Atentamente:
> César Hernández Mendoza.
>


Re: [jira] [Commented] (GERONIMO-6658) Issue @Gauge Accept: application/json

2018-11-30 Thread Ivan Junckes Filho
eusFormatter());
>endpoints.setSecurityValidator(new SecurityValidator() {
>@Override
>public void checkSecurity(final SecurityContext
> securityContext, final UriInfo uriInfo) {
>// no-op
>}
>});
>final Object json = endpoints.getJson("application", "foo",
> null, null);
>assertEquals(singletonMap("foo", 1L), json);
>}
>}
>
>
> 
> This is an automated message from the Apache Git Service.
> To respond to the message, please log on GitHub and use the
> URL above to go to the specific comment.
>
> For queries about this service, please contact Infrastructure at:
> us...@infra.apache.org
>
>
> > Issue @Gauge Accept: application/json
> > -
> >
> > Key: GERONIMO-6658
> > URL: https://issues.apache.org/jira/browse/GERONIMO-6658
> > Project: Geronimo
> >  Issue Type: Bug
> >  Security Level: public(Regular issues)
> >Reporter: Ivan Junckes Filho
> >Priority: Major
> >
> > Trying access a gauge /metrics/application/ with "Accept:
> application/json" I get the error below:
> >
> > 21-Nov-2018 17:24:08.811 WARNING [http-nio-8080-exec-4]
> org.apache.cxf.jaxrs.model.OperationResourceInfoComparator.compare Both
> org.apache.geronimo.microprofile.metrics.common.jaxrs.MetricsEndpoints#getJson
> and
> org.apache.geronimo.microprofile.metrics.jaxrs.CdiMetricsEndpoints#getJson
> are equal candidates for handling the current request which can lead to
> unpredictable results
> > 21-Nov-2018 17:26:52.183 SEVERE [http-nio-8080-exec-4]
> org.apache.cxf.jaxrs.utils.JAXRSUtils.logMessageHandlerProblem Problem with
> writing the data, class java.util.Collections$SingletonMap, ContentType:
> application/json
> > 21-Nov-2018 17:26:52.184 WARNING [http-nio-8080-exec-4]
> org.apache.cxf.phase.PhaseInterceptorChain.doDefaultLogging Interceptor for
> {[
> http://jaxrs.common.metrics.microprofile.geronimo.apache.org/}MetricsEndpoints|http://jaxrs.common.metrics.microprofile.geronimo.apache.org/%7DMetricsEndpoints
> <http://jaxrs.common.metrics.microprofile.geronimo.apache.org/%7DMetricsEndpoints%7Chttp://jaxrs.common.metrics.microprofile.geronimo.apache.org/%7DMetricsEndpoints>]
>  has
> thrown exception, unwinding now
> >  org.apache.cxf.interceptor.Fault
> > at
> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.handleWriteException(JAXRSOutInterceptor.java:396)
> > at
> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.serializeMessage(JAXRSOutInterceptor.java:272)
> > at
> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.processResponse(JAXRSOutInterceptor.java:122)
> > at
> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.handleMessage(JAXRSOutInterceptor.java:84)
> > at
> org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:308)
> > at
> org.apache.cxf.interceptor.OutgoingChainInterceptor.handleMessage(OutgoingChainInterceptor.java:90)
> > at
> org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:308)
> > at
> org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitiationObserver.java:121)
> > at
> org.apache.cxf.transport.http.AbstractHTTPDestination.invoke(AbstractHTTPDestination.java:267)
> > at
> org.apache.openejb.server.cxf.rs.CxfRsHttpListener.doInvoke(CxfRsHttpListener.java:253)
> > at
> org.apache.tomee.webservices.CXFJAXRSFilter.doFilter(CXFJAXRSFilter.java:94)
> > at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
> > at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
> > at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53)
> > at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
> > at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
> > at org.apache.openejb.server.httpd.EEFilter.doFilter(EEFilter.java:65)
> > at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
> > at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
> > at
> org.apache.tomee.microprofile.jwt.MPJWTFilter.doFilter(MPJWTFilter.java:64)
> > at
> org

Re: Microprofile OpenAPI

2018-11-30 Thread Ivan Junckes Filho
I think regardless of what the MicroProfile team decides, we need to make
it work as the specification says. Then iterate from there.

In my opinion this is a big problem that makes us strongly incompatible
with the standard.

On Fri, Nov 30, 2018 at 3:36 AM Romain Manni-Bucau 
wrote:

> Browser and all clients default to */* or octect/stream so the else is
> never used normally and was here just to put a mimetype from an optional.
>
> Browsers even send a kind of "all you can" value (*/*, html, xml at least).
>
> So yes we can make this value confifurable but this never happens. Ivan's
> case was even with cxf client which sets a value normally by default so it
> wouldnt help I think.
>
> Le ven. 30 nov. 2018 06:21, John D. Ament  a écrit
> :
>
> > The question posed to the MP team does not really match the question
> > posted here, and seems to be a tangental ask.
> >
> > The problem is this line of code [1], and nothing to do with TomEE's
> > behavior; it defaults to JSON even though the spec states it should be
> > YAML.  Perhaps a clean solution would be to make this a config setting?
> > But seems like there's a missing TCK test as well.  I'd also question
> when
> > a browser goes here, what does it send in the Accepts header.  My guess
> is
> > most modern browsers send text/html which also wouldn't line up.
> >
> > John
> >
> > [1]:
> >
> https://github.com/apache/geronimo-openapi/blob/master/geronimo-openapi-impl/src/main/java/org/apache/geronimo/microprofile/openapi/jaxrs/OpenAPIFilter.java#L57
> >
> > On Thu, Nov 29, 2018 at 3:58 PM Romain Manni-Bucau <
> rmannibu...@gmail.com>
> > wrote:
> >
> >> Response is fine (thanks jaxrs), request is up to jaxrs runtime so
> >> depends where you deploy it (i dont think implementing a custom writer
> for
> >> that is right for users, it has too much pitfalls once integrated to
> >> anything else than this very specific spec).
> >>
> >> Le jeu. 29 nov. 2018 21:39, Jonathan Gallimore <
> >> jonathan.gallim...@gmail.com> a écrit :
> >>
> >>> If the spec requires that, then I'd expect to get a YAML response if
> >>> making a request without an `Accept` header on the request.
> >>>
> >>> I haven't looked through the microprofile-openapi TCK, but I'd expect
> >>> that to be tested, and I'd suggest contributing a test there if there
> isn't
> >>> one.
> >>>
> >>> If you wanted to explicitly request a YAML response, I'd expect one of
> >>> these to work:
> >>>
> >>> Accept: application/x-yaml
> >>> Accept: text/yaml
> >>>
> >>> I'd expect a Content-Type header on the response to identify the mime
> >>> type of the response, whatever is being returned.
> >>>
> >>> Jon
> >>>
> >>> On Thu, Nov 29, 2018 at 4:50 PM Ivan Junckes Filho <
> >>> ivanjunc...@gmail.com> wrote:
> >>>
> >>>> Hey guys, I think I found a bug in OpenAPI implementation.
> >>>>
> >>>> The spec says:
> >>>> "The default format of the /openapi endpoint is YAML."
> >>>>
> >>>> But when I try to access /openapi it returns JSON by default.
> >>>>
> >>>> This is not correct.
> >>>>
> >>>> Also how can I access yaml if it is not default?
> >>>>
> >>>
>


Re: Microprofile OpenAPI

2018-11-29 Thread Ivan Junckes Filho
Please share the ticket here Romain, so everybody can follow.

On Thu, Nov 29, 2018 at 3:16 PM Bruno Baptista  wrote:

> +1 on getting an MP clarification on this.
> Bruno Baptista
> https://twitter.com/brunobat_
>
>
> On 29/11/18 17:10, Romain Manni-Bucau wrote:
>
> Well the point is not much what the spec says, the implementation supports
> all that since it lets the writer setup be done in the integrations if
> needed.
>
> See it from the point of view of the lib:
>
> 1. 99% of the case will be json and json is well set up for microprofile
> 2. yaml libs are different for most servers so no reason to impose one or
> even make it conflicting
>
> => the integration needs to customize the writers if needed
>
> In the lib the most we could do is to not default to json if the mediatype
> is null adding a config to default to yaml but often yaml writer don't
> answer to text/yaml so not sure it would be good for users. I will open a
> MP ticket about that.
>
> Romain Manni-Bucau
> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> <https://rmannibucau.metawerx.net/> | Old Blog
> <http://rmannibucau.wordpress.com> | Github
> <https://github.com/rmannibucau> | LinkedIn
> <https://www.linkedin.com/in/rmannibucau> | Book
> <https://www.packtpub.com/application-development/java-ee-8-high-performance>
>
>
> Le jeu. 29 nov. 2018 à 18:07, Bruno Baptista  a
> écrit :
>
>> Hi Romain,
>>
>> Independent of the implementation details, if we have to specify the
>> accept header with "text/yaml", the response in not *yaml by default*
>> like the spec says... right?
>>
>> Ivan, Is there a test in the TCK to make sure the default is yaml?
>>
>> Cheers
>> Bruno Baptista
>> https://twitter.com/brunobat_
>>
>>
>>
>>
>> On 29/11/18 16:58, Romain Manni-Bucau wrote:
>>
>> Hello Ivan,
>>
>> this is actually not exactly the case, the impl is writer agnostic and
>> fully relies on JAXRS for that so if you have a body writer which matches
>> OpenAPI and returns yaml by default or
>> which prefer yaml over json then you will have the behavior you describe.
>>
>> To get yaml you can send the Accept header valued with yaml media type
>> like "text/yaml" for some implementations.
>>
>> Side note: the impl does not impose any body writer to be integrable in
>> any environment and does not enforce yaml as well cause it is not part of
>> the core of microprofile (and hopefully will never be) so no reason to
>> import a lib (which can be heavy and potentially with vulnerabilities +
>> work for the users to maintain it) for that.
>>
>> Romain Manni-Bucau
>> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
>> <https://rmannibucau.metawerx.net/> | Old Blog
>> <http://rmannibucau.wordpress.com> | Github
>> <https://github.com/rmannibucau> | LinkedIn
>> <https://www.linkedin.com/in/rmannibucau> | Book
>> <https://www.packtpub.com/application-development/java-ee-8-high-performance>
>>
>>
>> Le jeu. 29 nov. 2018 à 17:50, Ivan Junckes Filho 
>> a écrit :
>>
>>> Hey guys, I think I found a bug in OpenAPI implementation.
>>>
>>> The spec says:
>>> "The default format of the /openapi endpoint is YAML."
>>>
>>> But when I try to access /openapi it returns JSON by default.
>>>
>>> This is not correct.
>>>
>>> Also how can I access yaml if it is not default?
>>>
>>


Re: Microprofile OpenAPI

2018-11-29 Thread Ivan Junckes Filho
Hey Romain, take a look on:

https://download.eclipse.org/microprofile/microprofile-open-api-1.0/microprofile-openapi-spec.html#_content_format

It is clear for me there, that the default should be yaml.

On Thu, Nov 29, 2018 at 2:58 PM Romain Manni-Bucau 
wrote:

> Hello Ivan,
>
> this is actually not exactly the case, the impl is writer agnostic and
> fully relies on JAXRS for that so if you have a body writer which matches
> OpenAPI and returns yaml by default or
> which prefer yaml over json then you will have the behavior you describe.
>
> To get yaml you can send the Accept header valued with yaml media type
> like "text/yaml" for some implementations.
>
> Side note: the impl does not impose any body writer to be integrable in
> any environment and does not enforce yaml as well cause it is not part of
> the core of microprofile (and hopefully will never be) so no reason to
> import a lib (which can be heavy and potentially with vulnerabilities +
> work for the users to maintain it) for that.
>
> Romain Manni-Bucau
> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> <https://rmannibucau.metawerx.net/> | Old Blog
> <http://rmannibucau.wordpress.com> | Github
> <https://github.com/rmannibucau> | LinkedIn
> <https://www.linkedin.com/in/rmannibucau> | Book
> <https://www.packtpub.com/application-development/java-ee-8-high-performance>
>
>
> Le jeu. 29 nov. 2018 à 17:50, Ivan Junckes Filho 
> a écrit :
>
>> Hey guys, I think I found a bug in OpenAPI implementation.
>>
>> The spec says:
>> "The default format of the /openapi endpoint is YAML."
>>
>> But when I try to access /openapi it returns JSON by default.
>>
>> This is not correct.
>>
>> Also how can I access yaml if it is not default?
>>
>


Microprofile OpenAPI

2018-11-29 Thread Ivan Junckes Filho
Hey guys, I think I found a bug in OpenAPI implementation.

The spec says:
"The default format of the /openapi endpoint is YAML."

But when I try to access /openapi it returns JSON by default.

This is not correct.

Also how can I access yaml if it is not default?


Write tests geronimo

2018-11-23 Thread Ivan Junckes Filho
Hello guys, I did a change on Geronimo Metrics.
https://github.com/apache/geronimo-metrics/pull/2

geronimo-metrics, as you are aware, is a library used in TomEE.

I am wondering how can I write a test for my change. Writing a test in
TomEE for this is very simple, but writing a test in geronimo I don't know
how to do it.

Basically what I need it to have an app, deploy it with a resource, call an
endpoint annotated with @Gauge and check if the gauge metric works.

https://github.com/apache/tomee/pull/213 (This does it in the TomEE side)

I see some references to Meecrowave in the project as well, not sure how
some tests use Meecrowave and if that is a pattern we should use there.

The TCK for MicroProfile Metrics is on TomEE, so the other question is if
we should just rely on the TCK or if we should not.

Thanks.


Re: Metrics Gauge Example and Bug

2018-11-23 Thread Ivan Junckes Filho
It worked, thanks man!

On Fri, Nov 23, 2018 at 12:40 PM Roberto Cortez  wrote:

> Yes, that was the issue. This should fix it:
>
> https://github.com/apache/tomee/commit/1bfb65a1837235f4e9ad4458f67aabcab5eff829
>
> Try to pull the code and test it again.
>
> Cheers,
> Roberto
>
> On 23 Nov 2018, at 14:14, Roberto Cortez  wrote:
>
> No point. I’ve found the issue:
>
> It’s here:
>
> https://github.com/tomitribe/tomee/commit/7f18f4bcfe64119b9001d5ac6bffeb7324987a37
>
> This commit reverted back the new JsonbProvider to the old JohnzonProvider.
>
> The fix should be just to replace one with another. Let me try it and test.
>
> Cheers,
> Roberto
>
> On 23 Nov 2018, at 12:06, Ivan Junckes Filho 
> wrote:
>
> I was using the current master.
>
> 1.1.9
>
> I will try to use the version Romain proposed and see how it works.
>
>
> On Thu, Nov 22, 2018 at 7:36 PM Roberto Cortez <
> radcor...@yahoo.com.invalid> wrote:
>
>> Hey,
>>
>> I think metrics doesn’t even run properly on TomEE 7.x because of CDI 2.0.
>>
>> Regarding the fail, I’m not sure what is wrong. I remember seeing that
>> before and I think it got fixed when we added the JsonB JAX-RS Provider.
>> Maybe there is a regression in some place.
>>
>> Cheers,
>> Roberto
>>
>> > On 22 Nov 2018, at 21:08, Romain Manni-Bucau 
>> wrote:
>> >
>> > Hi Ivan
>> >
>> > Do you use tomee 8 with johnzon 1.1.10? Works well on this one normally
>> if johnzon defaults are not broken. On tomee 7 you need to add jsonb ;)
>> >
>> > Le jeu. 22 nov. 2018 21:51, Ivan Junckes Filho > <mailto:ivanjunc...@gmail.com>> a écrit :
>> > Also there are a lot of properties being returned on that payload that
>> are not needed like rate1, rate5... etc.
>> >
>> >
>> >
>> > On Thu, Nov 22, 2018 at 6:26 PM Ivan Junckes Filho <
>> ivanjunc...@gmail.com <mailto:ivanjunc...@gmail.com>> wrote:
>> > The issue with the TCK is because meter in the spec expects
>> fifteenMinRate instead of fifteenMinuteRate.
>> >
>> > Same apply for the other properties like fiveMin..oneMin..
>> >
>> > @JsonbProperty("fifteenMinRate") is probably being ignored.
>> >
>> >
>> >
>> >
>> > On Thu, Nov 22, 2018 at 5:46 PM Ivan Junckes Filho <
>> ivanjunc...@gmail.com <mailto:ivanjunc...@gmail.com>> wrote:
>> > Hey Romain, it is actually a mapping issue. I created the PR but the
>> microprofile metrics TCK seems to be broken on TomEE, so I am not sure if
>> the PR is reliable.
>> > https://github.com/apache/geronimo-metrics/pull/2 <
>> https://github.com/apache/geronimo-metrics/pull/2>
>> >
>> > I will try to check what is going on with the TCK on TomEE, if you have
>> any tips let me know.
>> >
>> >
>> >
>> >
>> >
>> > On Wed, Nov 21, 2018 at 7:59 PM Romain Manni-Bucau <
>> rmannibu...@gmail.com <mailto:rmannibu...@gmail.com>> wrote:
>> > Hi Ivan
>> >
>> > It is a bug in tomee scanning I think
>> >
>> >
>> > Le mer. 21 nov. 2018 21:35, Ivan Junckes Filho > <mailto:ivanjunc...@gmail.com>> a
>> > écrit :
>> >
>> > > Hey guys, I was writing an example of metrics gauge (WIP).
>> > >
>> > > https://github.com/apache/tomee/pull/213 <
>> https://github.com/apache/tomee/pull/213>
>> > >
>> > > And I found a bug when trying access a gauge with "Accept:
>> > > application/json".
>> > >
>> > > Just to let you know that I will work on a fix for this:
>> > >
>> > > 21-Nov-2018 17:24:08.811 WARNING [http-nio-8080-exec-4]
>> > > org.apache.cxf.jaxrs.model.OperationResourceInfoComparator.compare
>> Both
>> > >
>> org.apache.geronimo.microprofile.metrics.common.jaxrs.MetricsEndpoints#getJson
>> > > and
>> > >
>> org.apache.geronimo.microprofile.metrics.jaxrs.CdiMetricsEndpoints#getJson
>> > > are equal candidates for handling the current request which can lead
>> to
>> > > unpredictable results
>> > > 21-Nov-2018 17:26:52.183 SEVERE [http-nio-8080-exec-4]
>> > > org.apache.cxf.jaxrs.utils.JAXRSUtils.logMessageHandlerProblem
>> Problem with
>> > > writing the data, class java.util.Collections$SingletonMap,
>> ContentType:
>> > > application/json
>> > > 21-Nov-2

Re: Metrics Gauge Example and Bug

2018-11-23 Thread Ivan Junckes Filho
I was using the current master.

1.1.9

I will try to use the version Romain proposed and see how it works.


On Thu, Nov 22, 2018 at 7:36 PM Roberto Cortez 
wrote:

> Hey,
>
> I think metrics doesn’t even run properly on TomEE 7.x because of CDI 2.0.
>
> Regarding the fail, I’m not sure what is wrong. I remember seeing that
> before and I think it got fixed when we added the JsonB JAX-RS Provider.
> Maybe there is a regression in some place.
>
> Cheers,
> Roberto
>
> > On 22 Nov 2018, at 21:08, Romain Manni-Bucau 
> wrote:
> >
> > Hi Ivan
> >
> > Do you use tomee 8 with johnzon 1.1.10? Works well on this one normally
> if johnzon defaults are not broken. On tomee 7 you need to add jsonb ;)
> >
> > Le jeu. 22 nov. 2018 21:51, Ivan Junckes Filho  <mailto:ivanjunc...@gmail.com>> a écrit :
> > Also there are a lot of properties being returned on that payload that
> are not needed like rate1, rate5... etc.
> >
> >
> >
> > On Thu, Nov 22, 2018 at 6:26 PM Ivan Junckes Filho <
> ivanjunc...@gmail.com <mailto:ivanjunc...@gmail.com>> wrote:
> > The issue with the TCK is because meter in the spec expects
> fifteenMinRate instead of fifteenMinuteRate.
> >
> > Same apply for the other properties like fiveMin..oneMin..
> >
> > @JsonbProperty("fifteenMinRate") is probably being ignored.
> >
> >
> >
> >
> > On Thu, Nov 22, 2018 at 5:46 PM Ivan Junckes Filho <
> ivanjunc...@gmail.com <mailto:ivanjunc...@gmail.com>> wrote:
> > Hey Romain, it is actually a mapping issue. I created the PR but the
> microprofile metrics TCK seems to be broken on TomEE, so I am not sure if
> the PR is reliable.
> > https://github.com/apache/geronimo-metrics/pull/2 <
> https://github.com/apache/geronimo-metrics/pull/2>
> >
> > I will try to check what is going on with the TCK on TomEE, if you have
> any tips let me know.
> >
> >
> >
> >
> >
> > On Wed, Nov 21, 2018 at 7:59 PM Romain Manni-Bucau <
> rmannibu...@gmail.com <mailto:rmannibu...@gmail.com>> wrote:
> > Hi Ivan
> >
> > It is a bug in tomee scanning I think
> >
> >
> > Le mer. 21 nov. 2018 21:35, Ivan Junckes Filho  <mailto:ivanjunc...@gmail.com>> a
> > écrit :
> >
> > > Hey guys, I was writing an example of metrics gauge (WIP).
> > >
> > > https://github.com/apache/tomee/pull/213 <
> https://github.com/apache/tomee/pull/213>
> > >
> > > And I found a bug when trying access a gauge with "Accept:
> > > application/json".
> > >
> > > Just to let you know that I will work on a fix for this:
> > >
> > > 21-Nov-2018 17:24:08.811 WARNING [http-nio-8080-exec-4]
> > > org.apache.cxf.jaxrs.model.OperationResourceInfoComparator.compare Both
> > >
> org.apache.geronimo.microprofile.metrics.common.jaxrs.MetricsEndpoints#getJson
> > > and
> > >
> org.apache.geronimo.microprofile.metrics.jaxrs.CdiMetricsEndpoints#getJson
> > > are equal candidates for handling the current request which can lead to
> > > unpredictable results
> > > 21-Nov-2018 17:26:52.183 SEVERE [http-nio-8080-exec-4]
> > > org.apache.cxf.jaxrs.utils.JAXRSUtils.logMessageHandlerProblem Problem
> with
> > > writing the data, class java.util.Collections$SingletonMap,
> ContentType:
> > > application/json
> > > 21-Nov-2018 17:26:52.184 WARNING [http-nio-8080-exec-4]
> > > org.apache.cxf.phase.PhaseInterceptorChain.doDefaultLogging
> Interceptor for
> > > {
> > >
> http://jaxrs.common.metrics.microprofile.geronimo.apache.org/}MetricsEndpoints
> <
> http://jaxrs.common.metrics.microprofile.geronimo.apache.org/%7DMetricsEndpoints
> >
> > > has thrown exception, unwinding now
> > >  org.apache.cxf.interceptor.Fault
> > > at
> > >
> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.handleWriteException(JAXRSOutInterceptor.java:396)
> > > at
> > >
> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.serializeMessage(JAXRSOutInterceptor.java:272)
> > > at
> > >
> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.processResponse(JAXRSOutInterceptor.java:122)
> > > at
> > >
> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.handleMessage(JAXRSOutInterceptor.java:84)
> > > at
> > >
> org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:308)
> > > at
> > >
> org.apache.cxf.interceptor.OutgoingChainInterceptor.handleMessage(O

Re: Metrics Gauge Example and Bug

2018-11-22 Thread Ivan Junckes Filho
Also there are a lot of properties being returned on that payload that are
not needed like rate1, rate5... etc.



On Thu, Nov 22, 2018 at 6:26 PM Ivan Junckes Filho 
wrote:

> The issue with the TCK is because meter in the spec expects fifteenMinRate
> instead of fifteenMinuteRate.
>
> Same apply for the other properties like fiveMin..oneMin..
>
> @JsonbProperty("fifteenMinRate") is probably being ignored.
>
>
>
>
> On Thu, Nov 22, 2018 at 5:46 PM Ivan Junckes Filho 
> wrote:
>
>> Hey Romain, it is actually a mapping issue. I created the PR but the
>> microprofile metrics TCK seems to be broken on TomEE, so I am not sure if
>> the PR is reliable.
>> https://github.com/apache/geronimo-metrics/pull/2
>>
>> I will try to check what is going on with the TCK on TomEE, if you have
>> any tips let me know.
>>
>>
>>
>>
>>
>> On Wed, Nov 21, 2018 at 7:59 PM Romain Manni-Bucau 
>> wrote:
>>
>>> Hi Ivan
>>>
>>> It is a bug in tomee scanning I think
>>>
>>>
>>> Le mer. 21 nov. 2018 21:35, Ivan Junckes Filho  a
>>> écrit :
>>>
>>> > Hey guys, I was writing an example of metrics gauge (WIP).
>>> >
>>> > https://github.com/apache/tomee/pull/213
>>> >
>>> > And I found a bug when trying access a gauge with "Accept:
>>> > application/json".
>>> >
>>> > Just to let you know that I will work on a fix for this:
>>> >
>>> > 21-Nov-2018 17:24:08.811 WARNING [http-nio-8080-exec-4]
>>> > org.apache.cxf.jaxrs.model.OperationResourceInfoComparator.compare Both
>>> >
>>> org.apache.geronimo.microprofile.metrics.common.jaxrs.MetricsEndpoints#getJson
>>> > and
>>> >
>>> org.apache.geronimo.microprofile.metrics.jaxrs.CdiMetricsEndpoints#getJson
>>> > are equal candidates for handling the current request which can lead to
>>> > unpredictable results
>>> > 21-Nov-2018 17:26:52.183 SEVERE [http-nio-8080-exec-4]
>>> > org.apache.cxf.jaxrs.utils.JAXRSUtils.logMessageHandlerProblem Problem
>>> with
>>> > writing the data, class java.util.Collections$SingletonMap,
>>> ContentType:
>>> > application/json
>>> > 21-Nov-2018 17:26:52.184 WARNING [http-nio-8080-exec-4]
>>> > org.apache.cxf.phase.PhaseInterceptorChain.doDefaultLogging
>>> Interceptor for
>>> > {
>>> >
>>> http://jaxrs.common.metrics.microprofile.geronimo.apache.org/}MetricsEndpoints
>>> > has thrown exception, unwinding now
>>> >  org.apache.cxf.interceptor.Fault
>>> > at
>>> >
>>> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.handleWriteException(JAXRSOutInterceptor.java:396)
>>> > at
>>> >
>>> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.serializeMessage(JAXRSOutInterceptor.java:272)
>>> > at
>>> >
>>> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.processResponse(JAXRSOutInterceptor.java:122)
>>> > at
>>> >
>>> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.handleMessage(JAXRSOutInterceptor.java:84)
>>> > at
>>> >
>>> org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:308)
>>> > at
>>> >
>>> org.apache.cxf.interceptor.OutgoingChainInterceptor.handleMessage(OutgoingChainInterceptor.java:90)
>>> > at
>>> >
>>> org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:308)
>>> > at
>>> >
>>> org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitiationObserver.java:121)
>>> > at
>>> >
>>> org.apache.cxf.transport.http.AbstractHTTPDestination.invoke(AbstractHTTPDestination.java:267)
>>> > at
>>> >
>>> org.apache.openejb.server.cxf.rs.CxfRsHttpListener.doInvoke(CxfRsHttpListener.java:253)
>>> > at
>>> >
>>> org.apache.tomee.webservices.CXFJAXRSFilter.doFilter(CXFJAXRSFilter.java:94)
>>> > at
>>> >
>>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
>>> > at
>>> >
>>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
>>> > at
>>> org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53)
>>> > at
>>> >
>>> org.apache.catalina.core.

Re: Metrics Gauge Example and Bug

2018-11-22 Thread Ivan Junckes Filho
The issue with the TCK is because meter in the spec expects fifteenMinRate
instead of fifteenMinuteRate.

Same apply for the other properties like fiveMin..oneMin..

@JsonbProperty("fifteenMinRate") is probably being ignored.




On Thu, Nov 22, 2018 at 5:46 PM Ivan Junckes Filho 
wrote:

> Hey Romain, it is actually a mapping issue. I created the PR but the
> microprofile metrics TCK seems to be broken on TomEE, so I am not sure if
> the PR is reliable.
> https://github.com/apache/geronimo-metrics/pull/2
>
> I will try to check what is going on with the TCK on TomEE, if you have
> any tips let me know.
>
>
>
>
>
> On Wed, Nov 21, 2018 at 7:59 PM Romain Manni-Bucau 
> wrote:
>
>> Hi Ivan
>>
>> It is a bug in tomee scanning I think
>>
>>
>> Le mer. 21 nov. 2018 21:35, Ivan Junckes Filho  a
>> écrit :
>>
>> > Hey guys, I was writing an example of metrics gauge (WIP).
>> >
>> > https://github.com/apache/tomee/pull/213
>> >
>> > And I found a bug when trying access a gauge with "Accept:
>> > application/json".
>> >
>> > Just to let you know that I will work on a fix for this:
>> >
>> > 21-Nov-2018 17:24:08.811 WARNING [http-nio-8080-exec-4]
>> > org.apache.cxf.jaxrs.model.OperationResourceInfoComparator.compare Both
>> >
>> org.apache.geronimo.microprofile.metrics.common.jaxrs.MetricsEndpoints#getJson
>> > and
>> >
>> org.apache.geronimo.microprofile.metrics.jaxrs.CdiMetricsEndpoints#getJson
>> > are equal candidates for handling the current request which can lead to
>> > unpredictable results
>> > 21-Nov-2018 17:26:52.183 SEVERE [http-nio-8080-exec-4]
>> > org.apache.cxf.jaxrs.utils.JAXRSUtils.logMessageHandlerProblem Problem
>> with
>> > writing the data, class java.util.Collections$SingletonMap, ContentType:
>> > application/json
>> > 21-Nov-2018 17:26:52.184 WARNING [http-nio-8080-exec-4]
>> > org.apache.cxf.phase.PhaseInterceptorChain.doDefaultLogging Interceptor
>> for
>> > {
>> >
>> http://jaxrs.common.metrics.microprofile.geronimo.apache.org/}MetricsEndpoints
>> > has thrown exception, unwinding now
>> >  org.apache.cxf.interceptor.Fault
>> > at
>> >
>> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.handleWriteException(JAXRSOutInterceptor.java:396)
>> > at
>> >
>> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.serializeMessage(JAXRSOutInterceptor.java:272)
>> > at
>> >
>> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.processResponse(JAXRSOutInterceptor.java:122)
>> > at
>> >
>> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.handleMessage(JAXRSOutInterceptor.java:84)
>> > at
>> >
>> org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:308)
>> > at
>> >
>> org.apache.cxf.interceptor.OutgoingChainInterceptor.handleMessage(OutgoingChainInterceptor.java:90)
>> > at
>> >
>> org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:308)
>> > at
>> >
>> org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitiationObserver.java:121)
>> > at
>> >
>> org.apache.cxf.transport.http.AbstractHTTPDestination.invoke(AbstractHTTPDestination.java:267)
>> > at
>> >
>> org.apache.openejb.server.cxf.rs.CxfRsHttpListener.doInvoke(CxfRsHttpListener.java:253)
>> > at
>> >
>> org.apache.tomee.webservices.CXFJAXRSFilter.doFilter(CXFJAXRSFilter.java:94)
>> > at
>> >
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
>> > at
>> >
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
>> > at
>> org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53)
>> > at
>> >
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
>> > at
>> >
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
>> > at org.apache.openejb.server.httpd.EEFilter.doFilter(EEFilter.java:65)
>> > at
>> >
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
>> > at
>> >
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
>> > at
>> >
>> org.apache.tomee.micropro

[jira] [Created] (GERONIMO-6658) Issue @Gauge Accept: application/json

2018-11-22 Thread Ivan Junckes Filho (JIRA)
Ivan Junckes Filho created GERONIMO-6658:


 Summary: Issue @Gauge Accept: application/json
 Key: GERONIMO-6658
 URL: https://issues.apache.org/jira/browse/GERONIMO-6658
 Project: Geronimo
  Issue Type: Bug
  Security Level: public (Regular issues)
Reporter: Ivan Junckes Filho


Trying access a gauge /metrics/application/ with "Accept: 
application/json" I get the error below:
 
21-Nov-2018 17:24:08.811 WARNING [http-nio-8080-exec-4] 
org.apache.cxf.jaxrs.model.OperationResourceInfoComparator.compare Both 
org.apache.geronimo.microprofile.metrics.common.jaxrs.MetricsEndpoints#getJson 
and org.apache.geronimo.microprofile.metrics.jaxrs.CdiMetricsEndpoints#getJson 
are equal candidates for handling the current request which can lead to 
unpredictable results
21-Nov-2018 17:26:52.183 SEVERE [http-nio-8080-exec-4] 
org.apache.cxf.jaxrs.utils.JAXRSUtils.logMessageHandlerProblem Problem with 
writing the data, class java.util.Collections$SingletonMap, ContentType: 
application/json
21-Nov-2018 17:26:52.184 WARNING [http-nio-8080-exec-4] 
org.apache.cxf.phase.PhaseInterceptorChain.doDefaultLogging Interceptor for 
{[http://jaxrs.common.metrics.microprofile.geronimo.apache.org/}MetricsEndpoints|http://jaxrs.common.metrics.microprofile.geronimo.apache.org/%7DMetricsEndpoints]
 has thrown exception, unwinding now
 org.apache.cxf.interceptor.Fault
at 
org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.handleWriteException(JAXRSOutInterceptor.java:396)
at 
org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.serializeMessage(JAXRSOutInterceptor.java:272)
at 
org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.processResponse(JAXRSOutInterceptor.java:122)
at 
org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.handleMessage(JAXRSOutInterceptor.java:84)
at 
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:308)
at 
org.apache.cxf.interceptor.OutgoingChainInterceptor.handleMessage(OutgoingChainInterceptor.java:90)
at 
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:308)
at 
org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitiationObserver.java:121)
at 
org.apache.cxf.transport.http.AbstractHTTPDestination.invoke(AbstractHTTPDestination.java:267)
at 
org.apache.openejb.server.cxf.rs.CxfRsHttpListener.doInvoke(CxfRsHttpListener.java:253)
at org.apache.tomee.webservices.CXFJAXRSFilter.doFilter(CXFJAXRSFilter.java:94)
at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53)
at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at org.apache.openejb.server.httpd.EEFilter.doFilter(EEFilter.java:65)
at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at org.apache.tomee.microprofile.jwt.MPJWTFilter.doFilter(MPJWTFilter.java:64)
at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at 
org.apache.geronimo.microprofile.opentracing.microprofile.server.OpenTracingFilter.doFilter(OpenTracingFilter.java:126)
at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at 
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:199)
at 
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96)
at org.apache.tomee.catalina.OpenEJBValve.invoke(OpenEJBValve.java:44)
at 
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:490)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:139)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92)
at 
org.apache.tomee.catalina.OpenEJBSecurityListener$RequestCapturer.invoke(OpenEJBSecurityListener.java:97)
at 
org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:668)
at 
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:74)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343)
at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:408)
at 
org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)
at 
org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractPro

Re: Metrics Gauge Example and Bug

2018-11-22 Thread Ivan Junckes Filho
Hey Romain, it is actually a mapping issue. I created the PR but the
microprofile metrics TCK seems to be broken on TomEE, so I am not sure if
the PR is reliable.
https://github.com/apache/geronimo-metrics/pull/2

I will try to check what is going on with the TCK on TomEE, if you have any
tips let me know.





On Wed, Nov 21, 2018 at 7:59 PM Romain Manni-Bucau 
wrote:

> Hi Ivan
>
> It is a bug in tomee scanning I think
>
>
> Le mer. 21 nov. 2018 21:35, Ivan Junckes Filho  a
> écrit :
>
> > Hey guys, I was writing an example of metrics gauge (WIP).
> >
> > https://github.com/apache/tomee/pull/213
> >
> > And I found a bug when trying access a gauge with "Accept:
> > application/json".
> >
> > Just to let you know that I will work on a fix for this:
> >
> > 21-Nov-2018 17:24:08.811 WARNING [http-nio-8080-exec-4]
> > org.apache.cxf.jaxrs.model.OperationResourceInfoComparator.compare Both
> >
> org.apache.geronimo.microprofile.metrics.common.jaxrs.MetricsEndpoints#getJson
> > and
> >
> org.apache.geronimo.microprofile.metrics.jaxrs.CdiMetricsEndpoints#getJson
> > are equal candidates for handling the current request which can lead to
> > unpredictable results
> > 21-Nov-2018 17:26:52.183 SEVERE [http-nio-8080-exec-4]
> > org.apache.cxf.jaxrs.utils.JAXRSUtils.logMessageHandlerProblem Problem
> with
> > writing the data, class java.util.Collections$SingletonMap, ContentType:
> > application/json
> > 21-Nov-2018 17:26:52.184 WARNING [http-nio-8080-exec-4]
> > org.apache.cxf.phase.PhaseInterceptorChain.doDefaultLogging Interceptor
> for
> > {
> >
> http://jaxrs.common.metrics.microprofile.geronimo.apache.org/}MetricsEndpoints
> > has thrown exception, unwinding now
> >  org.apache.cxf.interceptor.Fault
> > at
> >
> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.handleWriteException(JAXRSOutInterceptor.java:396)
> > at
> >
> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.serializeMessage(JAXRSOutInterceptor.java:272)
> > at
> >
> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.processResponse(JAXRSOutInterceptor.java:122)
> > at
> >
> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.handleMessage(JAXRSOutInterceptor.java:84)
> > at
> >
> org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:308)
> > at
> >
> org.apache.cxf.interceptor.OutgoingChainInterceptor.handleMessage(OutgoingChainInterceptor.java:90)
> > at
> >
> org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:308)
> > at
> >
> org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitiationObserver.java:121)
> > at
> >
> org.apache.cxf.transport.http.AbstractHTTPDestination.invoke(AbstractHTTPDestination.java:267)
> > at
> >
> org.apache.openejb.server.cxf.rs.CxfRsHttpListener.doInvoke(CxfRsHttpListener.java:253)
> > at
> >
> org.apache.tomee.webservices.CXFJAXRSFilter.doFilter(CXFJAXRSFilter.java:94)
> > at
> >
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
> > at
> >
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
> > at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53)
> > at
> >
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
> > at
> >
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
> > at org.apache.openejb.server.httpd.EEFilter.doFilter(EEFilter.java:65)
> > at
> >
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
> > at
> >
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
> > at
> >
> org.apache.tomee.microprofile.jwt.MPJWTFilter.doFilter(MPJWTFilter.java:64)
> > at
> >
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
> > at
> >
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
> > at
> >
> org.apache.geronimo.microprofile.opentracing.microprofile.server.OpenTracingFilter.doFilter(OpenTracingFilter.java:126)
> > at
> >
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
> > at
> >
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
> > at
> >
> org.apache.catalina.core.StandardWrapperValv

Metrics Gauge Example and Bug

2018-11-21 Thread Ivan Junckes Filho
Hey guys, I was writing an example of metrics gauge (WIP).

https://github.com/apache/tomee/pull/213

And I found a bug when trying access a gauge with "Accept:
application/json".

Just to let you know that I will work on a fix for this:

21-Nov-2018 17:24:08.811 WARNING [http-nio-8080-exec-4]
org.apache.cxf.jaxrs.model.OperationResourceInfoComparator.compare Both
org.apache.geronimo.microprofile.metrics.common.jaxrs.MetricsEndpoints#getJson
and
org.apache.geronimo.microprofile.metrics.jaxrs.CdiMetricsEndpoints#getJson
are equal candidates for handling the current request which can lead to
unpredictable results
21-Nov-2018 17:26:52.183 SEVERE [http-nio-8080-exec-4]
org.apache.cxf.jaxrs.utils.JAXRSUtils.logMessageHandlerProblem Problem with
writing the data, class java.util.Collections$SingletonMap, ContentType:
application/json
21-Nov-2018 17:26:52.184 WARNING [http-nio-8080-exec-4]
org.apache.cxf.phase.PhaseInterceptorChain.doDefaultLogging Interceptor for
{
http://jaxrs.common.metrics.microprofile.geronimo.apache.org/}MetricsEndpoints
has thrown exception, unwinding now
 org.apache.cxf.interceptor.Fault
at
org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.handleWriteException(JAXRSOutInterceptor.java:396)
at
org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.serializeMessage(JAXRSOutInterceptor.java:272)
at
org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.processResponse(JAXRSOutInterceptor.java:122)
at
org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.handleMessage(JAXRSOutInterceptor.java:84)
at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:308)
at
org.apache.cxf.interceptor.OutgoingChainInterceptor.handleMessage(OutgoingChainInterceptor.java:90)
at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:308)
at
org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitiationObserver.java:121)
at
org.apache.cxf.transport.http.AbstractHTTPDestination.invoke(AbstractHTTPDestination.java:267)
at
org.apache.openejb.server.cxf.rs.CxfRsHttpListener.doInvoke(CxfRsHttpListener.java:253)
at
org.apache.tomee.webservices.CXFJAXRSFilter.doFilter(CXFJAXRSFilter.java:94)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at org.apache.openejb.server.httpd.EEFilter.doFilter(EEFilter.java:65)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at
org.apache.tomee.microprofile.jwt.MPJWTFilter.doFilter(MPJWTFilter.java:64)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at
org.apache.geronimo.microprofile.opentracing.microprofile.server.OpenTracingFilter.doFilter(OpenTracingFilter.java:126)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:199)
at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96)
at org.apache.tomee.catalina.OpenEJBValve.invoke(OpenEJBValve.java:44)
at
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:490)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:139)
at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92)
at
org.apache.tomee.catalina.OpenEJBSecurityListener$RequestCapturer.invoke(OpenEJBSecurityListener.java:97)
at
org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:668)
at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:74)
at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343)
at
org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:408)
at
org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)
at
org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:770)
at
org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1415)
at
org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at
org.apache.tomcat.util.threads.TaskThread$Wrappi

Re: Re: TomEE8 RC2: MP Metrics @Counted throws 500

2018-11-20 Thread Ivan Junckes Filho
@César Hernandez  , FYI the 500 / null pointer
doesn't happen in the master. So it should be fixed in the next release of
geronimo-metrics /  TomEE MP.

If you want to check a working example of metrics see
https://github.com/apache/tomee/pull/207.

On Tue, Nov 20, 2018 at 1:11 PM MoreFlavor  wrote:

> Hello Ivan Junckes Filho,
> https://www.morebeer.com/category/kit-week.html?ref=2C
>
> Cheers
>
> Mike Albrecht
> Customer Service Representative
> MoreFlavor! Inc.
> 1-800-600-0033
>
> On Tue, Nov 20 at 3:28 AM , Ivan Junckes Filho 
> wrote:
> Hey Cesar, I was able to make it work with my example. Take a look there
>
> I found a bug with geronimo-metrics-1.0.0 throwing a null pointer when the
> app metric is not found instead of returning a blank page. I am not sure if
> it happens in master. I will be looking into it.
>
> On Mon, Nov 19, 2018 at 8:49 PM César Hernández Mendoza <
> cesargu...@gmail.com> wrote:
>
> > >
> > > Did you clean up your lib folder to kot provide mp libs?
> >
> > No, I didn't clean up the lib folder intentionally but now that I'm
> > looking again this thread. I may have one more chance to test in the
> > project I shared.
> > I'm going to try to specify in arquilliam.xml [1] the microprofile
> > classifier and try to use Arquillian remote instead of embed in the pom
> > file [2].
> >
> > [1]
> >
> >
> https://github.com/cesarhernandezgt/tomee-mp-metrics-examples/blob/master/src/test/resources/arquillian.xml
> > [2]
> >
> >
> https://github.com/cesarhernandezgt/tomee-mp-metrics-examples/blob/master/pom.xml
> > ]
> >
> >
> >
> > El mar., 16 oct. 2018 a las 14:58, Romain Manni-Bucau (<
> > rmannibu...@gmail.com>) escribió:
> >
> > > Did you clean up your lib folder to kot provide mp libs?
> > >
> > > Le mar. 16 oct. 2018 19:18, César Hernández Mendoza <
> > cesargu...@gmail.com>
> > > a écrit :
> > >
> > > > Hi Romain,
> > > >
> > > > On this commit to master:
> > > >
> > > >
> > >
> >
> https://github.com/cesarhernandezgt/tomee-mp-metrics-examples/commit/37e40dfc4fbdc65e95f90f3651b186aa2652c89f
> > > >
> > > > I added @ApplicationScoped to the resource, removed the monotonic and
> > > added
> > > > beans.xml but still, the issue arises
> > > >
> > > >
> > > > El lun., 15 oct. 2018 a las 16:21, Romain Manni-Bucau (<
> > > > rmannibu...@gmail.com>) escribió:
> > > >
> > > > > Hey César,
> > > > >
> > > > > not sure the link with monotonic - there is none - but the issue is
> > > when
> > > > > using a name which does not exist then the endpoint fail with a 500
> > > > >
> > > > > Your endpoint not being a CDI bean it does not support MP metrics
> so
> > > just
> > > > > adding @ApplicationScoped is enough to fix it.
> > > > > On another side i'll try to make the endpoint not failing this way
> on
> > > > > geronimo-metrics side.
> > > > >
> > > > > Romain Manni-Bucau
> > > > > @rmannibucau <https://twitter.com/rmannibucau> | Blog
> > > > > <https://rmannibucau.metawerx.net/> | Old Blog
> > > > > <http://rmannibucau.wordpress.com> | Github <
> > > > > https://github.com/rmannibucau> |
> > > > > LinkedIn <https://www.linkedin.com/in/rmannibucau> | Book
> > > > > <
> > > > >
> > > >
> > >
> >
> https://www.packtpub.com/application-development/java-ee-8-high-performance
> > > > > >
> > > > >
> > > > >
> > > > > Le lun. 15 oct. 2018 à 22:58, César Hernández Mendoza <
> > > > > cesargu...@gmail.com>
> > > > > a écrit :
> > > > >
> > > > > > Thanks for the reply, this is the repo I created with the minimal
> > > > > > configuration to show the issue:
> > > > > > https://github.com/cesarhernandezgt/tomee-mp-metrics-examples
> > > > > >
> > > > > > El lun., 15 oct. 2018 a las 13:18, Romain Manni-Bucau (<
> > > > > > rmannibu...@gmail.com>) escribió:
> > > > > >
> > > > > > > Can you push your app on github with tomee maven plugin set up?
> > > Will
> > > > be

Re: TomEE8 RC2: MP Metrics @Counted throws 500

2018-11-20 Thread Ivan Junckes Filho
Hey Cesar, I was able to make it work with my example. Take a look there

I found a bug with geronimo-metrics-1.0.0 throwing a null pointer when the
app metric is not found instead of returning a blank page. I am not sure if
it happens in master. I will be looking into it.

On Mon, Nov 19, 2018 at 8:49 PM César Hernández Mendoza <
cesargu...@gmail.com> wrote:

> >
> > Did you clean up your lib folder to kot provide mp libs?
>
> No, I didn't clean up the lib folder intentionally but now that I'm
> looking again this thread. I may have one more chance to test in the
> project I shared.
>  I'm going to try to specify in arquilliam.xml [1] the microprofile
> classifier and try to use Arquillian remote instead of embed in the pom
> file [2].
>
> [1]
>
> https://github.com/cesarhernandezgt/tomee-mp-metrics-examples/blob/master/src/test/resources/arquillian.xml
> [2]
>
> https://github.com/cesarhernandezgt/tomee-mp-metrics-examples/blob/master/pom.xml
> ]
>
>
>
> El mar., 16 oct. 2018 a las 14:58, Romain Manni-Bucau (<
> rmannibu...@gmail.com>) escribió:
>
> > Did you clean up your lib folder to kot provide mp libs?
> >
> > Le mar. 16 oct. 2018 19:18, César Hernández Mendoza <
> cesargu...@gmail.com>
> > a écrit :
> >
> > > Hi Romain,
> > >
> > > On this commit to master:
> > >
> > >
> >
> https://github.com/cesarhernandezgt/tomee-mp-metrics-examples/commit/37e40dfc4fbdc65e95f90f3651b186aa2652c89f
> > >
> > > I added @ApplicationScoped to the resource, removed the monotonic and
> > added
> > > beans.xml but still, the issue arises
> > >
> > >
> > > El lun., 15 oct. 2018 a las 16:21, Romain Manni-Bucau (<
> > > rmannibu...@gmail.com>) escribió:
> > >
> > > > Hey César,
> > > >
> > > > not sure the link with monotonic - there is none - but the issue is
> > when
> > > > using a name which does not exist then the endpoint fail with a 500
> > > >
> > > > Your endpoint not being a CDI bean it does not support MP metrics so
> > just
> > > > adding @ApplicationScoped is enough to fix it.
> > > > On another side i'll try to make the endpoint not failing this way on
> > > > geronimo-metrics side.
> > > >
> > > > Romain Manni-Bucau
> > > > @rmannibucau  |  Blog
> > > >  | Old Blog
> > > >  | Github <
> > > > https://github.com/rmannibucau> |
> > > > LinkedIn  | Book
> > > > <
> > > >
> > >
> >
> https://www.packtpub.com/application-development/java-ee-8-high-performance
> > > > >
> > > >
> > > >
> > > > Le lun. 15 oct. 2018 à 22:58, César Hernández Mendoza <
> > > > cesargu...@gmail.com>
> > > > a écrit :
> > > >
> > > > > Thanks for the reply, this is the repo I created with the minimal
> > > > > configuration to show the issue:
> > > > > https://github.com/cesarhernandezgt/tomee-mp-metrics-examples
> > > > >
> > > > > El lun., 15 oct. 2018 a las 13:18, Romain Manni-Bucau (<
> > > > > rmannibu...@gmail.com>) escribió:
> > > > >
> > > > > > Can you push your app on github with tomee maven plugin set up?
> > Will
> > > be
> > > > > > easier to check.
> > > > > >
> > > > > > Le lun. 15 oct. 2018 19:46, César Hernández Mendoza <
> > > > > cesargu...@gmail.com>
> > > > > > a écrit :
> > > > > >
> > > > > > >
> > > > > > >> I noticed that on my previous email I paste I paste the
> > exception
> > > > from
> > > > > > > the HTTP response and not the one from the log (attached).
> > > > > > >
> > > > > > > Some other things I did without success:
> > > > > > > * Added `geronimo.metrics.jaxrs.activated=true` to tomee
> > > > > > system.properties.
> > > > > > > * Make the Resource @ApplicationScoped
> > > > > > > * Debugged geronimo-metrics code and for some reason I couldn't
> > > > > identify
> > > > > > > so far, this is where we get the Nullpointer:
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
> https://github.com/apache/geronimo-metrics/blob/master/src/main/java/org/apache/geronimo/microprofile/metrics/jaxrs/PrometheusFormatter.java#L55
> > > > > > > it  seems like if the annotation was not added.
> > > > > > > * The same issue arise when you try to use @Gauge annotation. I
> > > > haven't
> > > > > > > check the others types of metrics.
> > > > > > >
> > > > > > >
> > > > > > > El dom., 14 oct. 2018 a las 23:01, Romain Manni-Bucau (<
> > > > > > > rmannibu...@gmail.com>) escribió:
> > > > > > >
> > > > > > >> Hi César,
> > > > > > >>
> > > > > > >> the actual error is in the cause - available in logs.
> > > > > > >>
> > > > > > >> Romain Manni-Bucau
> > > > > > >> @rmannibucau  |  Blog
> > > > > > >>  | Old Blog
> > > > > > >>  | Github <
> > > > > > >> https://github.com/rmannibucau> |
> > > > > > >> LinkedIn  | Book
> > > > > > >> <
> > > > > > >>
> > > > > >
> > > > >
> > > >
> > >
> >
> https://www.packtpub.com/application-devel

Re: TomEE8 RC2: MP Metrics @Counted throws 500

2018-11-19 Thread Ivan Junckes Filho
Hey guys, I also had the same issue here.

The application metrics do not work. Base and Vendor metrics are fine.

I am troubleshooting to see if I can find the issue. I will let you know if
I find something.

Please if you already had the chance to look into this let me know.

On Tue, Oct 16, 2018 at 5:58 PM Romain Manni-Bucau 
wrote:

> Did you clean up your lib folder to kot provide mp libs?
>
> Le mar. 16 oct. 2018 19:18, César Hernández Mendoza 
> a écrit :
>
> > Hi Romain,
> >
> > On this commit to master:
> >
> >
> https://github.com/cesarhernandezgt/tomee-mp-metrics-examples/commit/37e40dfc4fbdc65e95f90f3651b186aa2652c89f
> >
> > I added @ApplicationScoped to the resource, removed the monotonic and
> added
> > beans.xml but still, the issue arises
> >
> >
> > El lun., 15 oct. 2018 a las 16:21, Romain Manni-Bucau (<
> > rmannibu...@gmail.com>) escribió:
> >
> > > Hey César,
> > >
> > > not sure the link with monotonic - there is none - but the issue is
> when
> > > using a name which does not exist then the endpoint fail with a 500
> > >
> > > Your endpoint not being a CDI bean it does not support MP metrics so
> just
> > > adding @ApplicationScoped is enough to fix it.
> > > On another side i'll try to make the endpoint not failing this way on
> > > geronimo-metrics side.
> > >
> > > Romain Manni-Bucau
> > > @rmannibucau  |  Blog
> > >  | Old Blog
> > >  | Github <
> > > https://github.com/rmannibucau> |
> > > LinkedIn  | Book
> > > <
> > >
> >
> https://www.packtpub.com/application-development/java-ee-8-high-performance
> > > >
> > >
> > >
> > > Le lun. 15 oct. 2018 à 22:58, César Hernández Mendoza <
> > > cesargu...@gmail.com>
> > > a écrit :
> > >
> > > > Thanks for the reply, this is the repo I created with the minimal
> > > > configuration to show the issue:
> > > > https://github.com/cesarhernandezgt/tomee-mp-metrics-examples
> > > >
> > > > El lun., 15 oct. 2018 a las 13:18, Romain Manni-Bucau (<
> > > > rmannibu...@gmail.com>) escribió:
> > > >
> > > > > Can you push your app on github with tomee maven plugin set up?
> Will
> > be
> > > > > easier to check.
> > > > >
> > > > > Le lun. 15 oct. 2018 19:46, César Hernández Mendoza <
> > > > cesargu...@gmail.com>
> > > > > a écrit :
> > > > >
> > > > > >
> > > > > >> I noticed that on my previous email I paste I paste the
> exception
> > > from
> > > > > > the HTTP response and not the one from the log (attached).
> > > > > >
> > > > > > Some other things I did without success:
> > > > > > * Added `geronimo.metrics.jaxrs.activated=true` to tomee
> > > > > system.properties.
> > > > > > * Make the Resource @ApplicationScoped
> > > > > > * Debugged geronimo-metrics code and for some reason I couldn't
> > > > identify
> > > > > > so far, this is where we get the Nullpointer:
> > > > > >
> > > > >
> > > >
> > >
> >
> https://github.com/apache/geronimo-metrics/blob/master/src/main/java/org/apache/geronimo/microprofile/metrics/jaxrs/PrometheusFormatter.java#L55
> > > > > > it  seems like if the annotation was not added.
> > > > > > * The same issue arise when you try to use @Gauge annotation. I
> > > haven't
> > > > > > check the others types of metrics.
> > > > > >
> > > > > >
> > > > > > El dom., 14 oct. 2018 a las 23:01, Romain Manni-Bucau (<
> > > > > > rmannibu...@gmail.com>) escribió:
> > > > > >
> > > > > >> Hi César,
> > > > > >>
> > > > > >> the actual error is in the cause - available in logs.
> > > > > >>
> > > > > >> Romain Manni-Bucau
> > > > > >> @rmannibucau  |  Blog
> > > > > >>  | Old Blog
> > > > > >>  | Github <
> > > > > >> https://github.com/rmannibucau> |
> > > > > >> LinkedIn  | Book
> > > > > >> <
> > > > > >>
> > > > >
> > > >
> > >
> >
> https://www.packtpub.com/application-development/java-ee-8-high-performance
> > > > > >> >
> > > > > >>
> > > > > >>
> > > > > >> Le lun. 15 oct. 2018 à 06:24, César Hernández Mendoza <
> > > > > >> cesargu...@gmail.com>
> > > > > >> a écrit :
> > > > > >>
> > > > > >> > Any opinion on this issue?
> > > > > >> > Base on your expertise-instinct do you think this is not Tomee
> > but
> > > > > >> > geronimo MP Metrics related?
> > > > > >> >
> > > > > >> > El vie., 12 oct. 2018 a las 17:27, César Hernández Mendoza (<
> > > > > >> > cesargu...@gmail.com>) escribió:
> > > > > >> >
> > > > > >> > > Hi,
> > > > > >> > >
> > > > > >> > > Within a JAX-RS resource I annotated the following method:
> > > > > >> > >
> > > > > >> > > @Counted(name = "cesar", absolute = true, monotonic = true)
> > > > > >> > > @GET
> > > > > >> > > public String message() {
> > > > > >> > > return "Hi Microprofile JWT!";
> > > > > >> > > }
> > > > > >> > >
> > > > > >> > >
> > > > > >> > > Metric endpoint
> http://localhost:8181/moviefu

Re: [VOTE] Geronimo Validation 2.0 (spec) v1.0

2018-10-01 Thread Ivan Junckes Filho
+1

On Mon, Oct 1, 2018 at 8:02 AM Roberto Cortez  wrote:

> +1
>
> On 30 Sep 2018, at 16:38, Romain Manni-Bucau 
> wrote:
>
> Hi guys,
>
> To enable BVal and TomEE releases, I'd like to release our validation spec
> bundle.
>
> Here is the staging repo:
> https://repository.apache.org/content/repositories/orgapachegeronimo-1071
> The dist (dev) area is:
> https://dist.apache.org/repos/dist/dev/geronimo/specs/validation/ (rev
> 29801)
> The tag is:
> http://svn.apache.org/repos/asf/geronimo/specs/tags/geronimo-validation_2.0_spec-1.0/
> (rev 1842396)
> My key is the same as usual.
>
> Vote will be open for 3 days or until we cancel it or we get 3 +1 binding
> votes.
>
> Romain Manni-Bucau
> @rmannibucau  |  Blog
>  | Old Blog
>  | Github
>  | LinkedIn
>  | Book
> 
>
>
>


Re: [VOTE] release geronimo-jbatch_1.0-1.0

2013-12-03 Thread Ivan
+1, thanks Mark.


2013/12/2 Mark Struberg 

> Anyone else likes to vote?
> We are still low on votes.
>
> All the people who discussed on the java6 vs java7 question for JavaEE7:
> this question is solved. compiling with target java6 is perfectly fine.
> Please cast your votes now.
>
> txs and LieGrue,
> strub
>
>
>
>   --
>  *From:* Mark Struberg 
> *To:* geronimo-dev 
> *Sent:* Monday, 25 November 2013, 16:53
> *Subject:* [VOTE] release geronimo-jbatch_1.0-1.0
>
> Good evening!
>
> I'd like to call a VOTE on releasing the geronimo jbatch 1.0 API.
>
> The API is already used in Apache BatchEE and passes the JSR-352 JBatch
> TCK.
>
> The staging repo is
> https://repository.apache.org/content/repositories/orgapachegeronimo-005/
>
> The source release is here
>
> https://repository.apache.org/content/repositories/orgapachegeronimo-005/org/apache/geronimo/specs/geronimo-jbatch_1.0_spec/1.0/geronimo-jbatch_1.0_spec-1.0-source-release.zip
>
> The tag can be found here
>
> https://svn.apache.org/repos/asf/geronimo/specs/tags/geronimo-jbatch_1.0_spec-1.0/
>
> [+1] ship it
> [+0] meh, don't care
> [-1] nope, because ${reason}
>
> Here is my +1
>
> LieGrue,
> strub
>
>
>
>
>


-- 
Ivan


Re: [VOTE] Release stax-api-1.2 spec v 1.2

2013-11-28 Thread Ivan
+1, Thanks Guillaume for helping this.


2013/11/28 Daniel Kulp 

>
> +1 (non-binding)
>
> This is a big problem as underlying causes (like IOExceptions and such)
> are lost which makes various issues hard to debug and resolve.
>
> Dan
>
>
>
> On Nov 27, 2013, at 11:04 AM, Guillaume Nodet 
> wrote:
>
> I've uploaded a release at
>
> https://repository.apache.org/content/repositories/orgapachegeronimo-014/
> to fix the following issue:
>   https://issues.apache.org/jira/browse/GERONIMO-6509
>
> Please review and vote,
>
> Cheers,
> Guillaume
>
>
> --
> Daniel Kulp
> dk...@apache.org - http://dankulp.com/blog
> Talend Community Coder - http://coders.talend.com
>
>


-- 
Ivan


[jira] [Updated] (GERONIMO-6488) Use GEronimoClassLoader for classloader injection for GBeans

2013-08-22 Thread Ivan (JIRA)

 [ 
https://issues.apache.org/jira/browse/GERONIMO-6488?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Ivan updated GERONIMO-6488:
---

Attachment: geronimo-kernel-3.0.1.jar
GERONIMO-6488.patch

> Use GEronimoClassLoader for classloader injection for GBeans
> 
>
> Key: GERONIMO-6488
> URL: https://issues.apache.org/jira/browse/GERONIMO-6488
> Project: Geronimo
>  Issue Type: Bug
>  Security Level: public(Regular issues) 
>  Components: core
>Affects Versions: 3.0.1
>Reporter: Ivan
>Assignee: Ivan
> Fix For: 3.0.2
>
> Attachments: GERONIMO-6488.patch, geronimo-kernel-3.0.1.jar
>
>
> To support jar url classloader, originally, we had EquonixClassLoader from 
> xbean, later, we use Equonix hook to create a GeronimoClassLoader on Geronimo 
> side. So, for a web application, its context classloader will use 
> EquonixClassLoader and GeronimoClassLoader is used for loading web 
> application classes. This would bring issues in some special scenarios.
> http://apache-geronimo.328035.n3.nabble.com/Classes-generated-on-runtime-javassist-classloader-issue-td3987081.html

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Commented] (GERONIMO-6488) Use GEronimoClassLoader for classloader injection for GBeans

2013-08-22 Thread Ivan (JIRA)

[ 
https://issues.apache.org/jira/browse/GERONIMO-6488?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13747448#comment-13747448
 ] 

Ivan commented on GERONIMO-6488:


I attached a patched jar file, you may replace that in Geronimo server, the 
directory is repository\org\apache\geronimo\framework\geronimo-kernel\3.0.1

> Use GEronimoClassLoader for classloader injection for GBeans
> 
>
> Key: GERONIMO-6488
> URL: https://issues.apache.org/jira/browse/GERONIMO-6488
> Project: Geronimo
>  Issue Type: Bug
>  Security Level: public(Regular issues) 
>  Components: core
>Affects Versions: 3.0.1
>Reporter: Ivan
>Assignee: Ivan
> Fix For: 3.0.2
>
> Attachments: GERONIMO-6488.patch, geronimo-kernel-3.0.1.jar
>
>
> To support jar url classloader, originally, we had EquonixClassLoader from 
> xbean, later, we use Equonix hook to create a GeronimoClassLoader on Geronimo 
> side. So, for a web application, its context classloader will use 
> EquonixClassLoader and GeronimoClassLoader is used for loading web 
> application classes. This would bring issues in some special scenarios.
> http://apache-geronimo.328035.n3.nabble.com/Classes-generated-on-runtime-javassist-classloader-issue-td3987081.html

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Updated] (GERONIMO-6488) Use GEronimoClassLoader for classloader injection for GBeans

2013-08-22 Thread Ivan (JIRA)

 [ 
https://issues.apache.org/jira/browse/GERONIMO-6488?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Ivan updated GERONIMO-6488:
---

  Component/s: core
  Description: 
To support jar url classloader, originally, we had EquonixClassLoader from 
xbean, later, we use Equonix hook to create a GeronimoClassLoader on Geronimo 
side. So, for a web application, its context classloader will use 
EquonixClassLoader and GeronimoClassLoader is used for loading web application 
classes. This would bring issues in some special scenarios.

http://apache-geronimo.328035.n3.nabble.com/Classes-generated-on-runtime-javassist-classloader-issue-td3987081.html

  was:To support jar url classloader, originally, we had EquonixClassLoader 
from xbean, later, we use Equonix hook to create a GeronimoClassLoader on 
Geronimo side. So, for a web application, its context classloader will use 
EquonixClassLoader and GeronimoClassLoader is used for loading web application 
classes. This would bring issues in some special scenarios.

Affects Version/s: 3.0.1
Fix Version/s: 3.0.2
 Assignee: Ivan

> Use GEronimoClassLoader for classloader injection for GBeans
> 
>
> Key: GERONIMO-6488
> URL: https://issues.apache.org/jira/browse/GERONIMO-6488
> Project: Geronimo
>  Issue Type: Bug
>  Security Level: public(Regular issues) 
>  Components: core
>Affects Versions: 3.0.1
>Reporter: Ivan
>Assignee: Ivan
> Fix For: 3.0.2
>
>
> To support jar url classloader, originally, we had EquonixClassLoader from 
> xbean, later, we use Equonix hook to create a GeronimoClassLoader on Geronimo 
> side. So, for a web application, its context classloader will use 
> EquonixClassLoader and GeronimoClassLoader is used for loading web 
> application classes. This would bring issues in some special scenarios.
> http://apache-geronimo.328035.n3.nabble.com/Classes-generated-on-runtime-javassist-classloader-issue-td3987081.html

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Created] (GERONIMO-6488) Use GEronimoClassLoader for classloader injection for GBeans

2013-08-22 Thread Ivan (JIRA)
Ivan created GERONIMO-6488:
--

 Summary: Use GEronimoClassLoader for classloader injection for 
GBeans
 Key: GERONIMO-6488
 URL: https://issues.apache.org/jira/browse/GERONIMO-6488
 Project: Geronimo
  Issue Type: Bug
  Security Level: public (Regular issues)
Reporter: Ivan


To support jar url classloader, originally, we had EquonixClassLoader from 
xbean, later, we use Equonix hook to create a GeronimoClassLoader on Geronimo 
side. So, for a web application, its context classloader will use 
EquonixClassLoader and GeronimoClassLoader is used for loading web application 
classes. This would bring issues in some special scenarios.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Resolved] (GERONIMO-6486) @Resource SessionContext is not working

2013-08-17 Thread Ivan (JIRA)

 [ 
https://issues.apache.org/jira/browse/GERONIMO-6486?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Ivan resolved GERONIMO-6486.


Resolution: Not A Problem

JIRA system is mostly for defects only, not asking questions. If you found that 
it does not work, you may need to show us the steps to reproducing the issues. 
Thanks.

> @Resource SessionContext is not working
> ---
>
> Key: GERONIMO-6486
> URL: https://issues.apache.org/jira/browse/GERONIMO-6486
> Project: Geronimo
>  Issue Type: Bug
>  Security Level: public(Regular issues) 
> Environment: Geronimo 3.0.0
>Reporter: Nayela Manzoor
>
> I think, I am missing some geronimo 3.0 dependencies. Can you please tell me 
> what geronimo jars I need to make @Resource SessionContext work?
> Thanks,
> Nayela

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Commented] (GERONIMO-6486) @Resource SessionContext is not working

2013-08-17 Thread Ivan (JIRA)

[ 
https://issues.apache.org/jira/browse/GERONIMO-6486?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13742931#comment-13742931
 ] 

Ivan commented on GERONIMO-6486:


I did not see any jar files are required to support SessionContext injections 
with Resource annotation.

> @Resource SessionContext is not working
> ---
>
> Key: GERONIMO-6486
> URL: https://issues.apache.org/jira/browse/GERONIMO-6486
> Project: Geronimo
>  Issue Type: Bug
>  Security Level: public(Regular issues) 
> Environment: Geronimo 3.0.0
>Reporter: Nayela Manzoor
>
> I think, I am missing some geronimo 3.0 dependencies. Can you please tell me 
> what geronimo jars I need to make @Resource SessionContext work?
> Thanks,
> Nayela

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Resolved] (GERONIMO-6487) @Resource SessionContext is not working in Geronimo 3.0.0

2013-08-17 Thread Ivan (JIRA)

 [ 
https://issues.apache.org/jira/browse/GERONIMO-6487?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Ivan resolved GERONIMO-6487.


Resolution: Cannot Reproduce

JIRA system is mostly for defects only, not asking questions. If you found that 
it does not work for you, you may need to show us the steps to reproducing the 
issues. Thanks.

> @Resource SessionContext is not working in Geronimo 3.0.0
> -
>
> Key: GERONIMO-6487
> URL: https://issues.apache.org/jira/browse/GERONIMO-6487
> Project: Geronimo
>  Issue Type: Bug
>  Security Level: public(Regular issues) 
> Environment: Both Windows and Unix
>Reporter: Nayela Manzoor
>
> Can I please get the jar needed in geronimo 3.0 to make @Resource 
> SessionContext work?
> Thanks,
> Nayela

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


Re: Geronimo.Axis2 NullPointerException GeronimoFactoryRegistry

2013-08-13 Thread Ivan
n(ThreadPool.java:344)
>
>  at
> java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
>
>  at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
>
>  at java.lang.Thread.run(Thread.java:662)
>
> Caused by: javax.xml.ws.WebServiceException: java.lang.NullPointerException
>
>  at
> org.apache.axis2.jaxws.ExceptionFactory.createWebServiceException(ExceptionFactory.java:175)
>
>  at
> org.apache.axis2.jaxws.ExceptionFactory.makeWebServiceException(ExceptionFactory.java:70)
>
>  at
> org.apache.axis2.jaxws.ExceptionFactory.makeWebServiceException(ExceptionFactory.java:128)
>
>  at
> org.apache.axis2.jaxws.server.EndpointController.handleRequest(EndpointController.java:312)
>
>  at
> org.apache.axis2.jaxws.server.EndpointController.invoke(EndpointController.java:103)
>
>  at
> org.apache.axis2.jaxws.server.JAXWSMessageReceiver.receive(JAXWSMessageReceiver.java:169)
>
>  ... 37 more
>
> Caused by: java.lang.NullPointerException
>
>  at
> org.apache.geronimo.axis2.GeronimoEndpointLifecycleManagerFactory.createEndpointLifecycleManager(GeronimoEndpointLifecycleManagerFactory.java:33)
>
>  at
> org.apache.axis2.jaxws.server.ServiceInstanceFactoryImpl.createServiceInstance(ServiceInstanceFactoryImpl.java:48)
>
>  at
> org.apache.axis2.jaxws.server.EndpointController.handleRequest(EndpointController.java:247)
>
>  ... 39 more
>
>
>
> I use geronimo version 2.2.1 and geronimo.axis2 version is also 2.2.1.
>
> It seems like GeronimoFactoryRegistry is never set and therefore it's null
> and causes this exception. I have virtual hosts setup with geronimo can
> that have something to do with this? Or is this caused because I am missing
> something from my geronimo setup?
>
>
> Thanks in advance!
>
>
>



-- 
Ivan


Re: [ANNOUNCE] Jarek Gawor has been appointed as the the PMC Chair of the Geronimo Project

2013-07-30 Thread Ivan
Hi, Kevan, thanks for your great work, and do learn a lot from you.

Hi, Jarek, I prefer to say 'thanks' rather than 'congrats', as PMC chair
means much effort for you ;-)


2013/7/31 Kevan Miller 

> All,
> Due to recent changes in my life, I've had less and less time to devote to
> the Geronimo project. Last month, I told the PMC that I wished to step down
> from my PMC Chair duties.
>
> The Geronimo PMC unanimously nominated Jarek Gawor to become the PMC
> Chair. I'm happy to announce that at this month's board meeting, the ASF
> Board appointed Jarek the new PMC Chair of the Geronimo project.
>
> As anyone following the Geronimo project should know, Jarek has been
> bringing a tremendous amount to the project in multiple ways. Please take a
> moment to thank Jarek for taking on this new role.
>
> Finally, to all the PMC members, committers, contributors, and users --
> thanks for making my job as PMC chair so easy and enjoyable. It's been a
> pleasure working with you.
>
> --kevan




-- 
Ivan


Re: Query About Apache Geronimo

2013-07-17 Thread Ivan
Hi,

Are you saying for serving HTTP requests or other things ?

Thanks.


2013/7/16 Grandhi Subrahmanya 

> Hi Experts,
>
> I am using Apache Geronimo Application server, I want to customize
> queuing in Geronimo like, All the requests are stored in Application server
> queue and it release one by one. That means, Application server serves only
> one request at a time. once previous one is completed next request will be
> release. I want to set like this.
>
> I hope, you understand what I am trying.
>
> can you suggest me, which ways are better to solve this.
>
> Thanks
>
> --
>
> G.Subrahmanyam,
> +91-8867111831
>
>


-- 
Ivan


Re: JDK 7 Classloading Behavior Change

2013-07-04 Thread Ivan
 at
>> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1121)
>> at
>> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:614)
>> at java.lang.Thread.run(Thread.java:769)
>>
>> The reason this fails is that the bundle's classloader's parent loader is
>> the JVM's boot classloader, not the ext loader - so it cannot load the
>> com.sun.* classes that it needs (and that it could in JDK6).
>>
>> One solution to this is to add the following line to
>> /etc/system.properties:
>> osgi.parentClassloader=ext
>>
>> This forces the bundle's to search the ext loader (in addition to the
>> boot loader) on boot delegated loads.
>>
>> I'm wondering if there should be a more permanent fix...  here are a few
>> suggestions:
>> 1) Work with the JDK teams to revert back to the old behavior - I have a
>> ticket open with JDK support, but they apparently moved the com.sun.*
>> classes to the ext loader for a security issue, so it may be a hard sell to
>> get them to move it back.
>> 2) Update the default system.properties to include
>> osgi.parentClassloader=ext
>> 3) Modify the ClassLoaderHook's getBundleClassLoaderParent() method to
>> return the ext loader ( ClassLoader.getSystemClassLoader().getParent() ).
>>
>> If #1 is not an option, then I think I like optino #2 better than #3, as
>> it allows users to change it easily if they want a different behavior.
>>
>> Does anybody have strong opinions?  Or other suggestions?
>>
>> Thanks, Andy
>>
>
>


-- 
Ivan


[jira] [Commented] (GERONIMO-6473) el_2.2 spec pass index of vararg not the real params

2013-07-01 Thread Ivan (JIRA)

[ 
https://issues.apache.org/jira/browse/GERONIMO-6473?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13696866#comment-13696866
 ] 

Ivan commented on GERONIMO-6473:


Seems that this has been fixed in GERONIMO-6476.

> el_2.2 spec pass index of vararg not the real params
> 
>
> Key: GERONIMO-6473
> URL: https://issues.apache.org/jira/browse/GERONIMO-6473
> Project: Geronimo
>  Issue Type: Bug
>  Security Level: public(Regular issues) 
>  Components: specs
>Reporter: chunlinyao
> Fix For: 1.x
>
>
> The line no 442
> Array.set(targetArray, i, expressionFactory.coerceToType(iCurrentIndex + i, 
> componentClassType));
> Should be:
> Array.set(targetArray, i, expressionFactory.coerceToType(params[iCurrentIndex 
> + i], componentClassType));

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Resolved] (GERONIMO-6473) el_2.2 spec pass index of vararg not the real params

2013-07-01 Thread Ivan (JIRA)

 [ 
https://issues.apache.org/jira/browse/GERONIMO-6473?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Ivan resolved GERONIMO-6473.


   Resolution: Duplicate
Fix Version/s: 1.x

> el_2.2 spec pass index of vararg not the real params
> 
>
> Key: GERONIMO-6473
> URL: https://issues.apache.org/jira/browse/GERONIMO-6473
> Project: Geronimo
>  Issue Type: Bug
>  Security Level: public(Regular issues) 
>  Components: specs
>Reporter: chunlinyao
> Fix For: 1.x
>
>
> The line no 442
> Array.set(targetArray, i, expressionFactory.coerceToType(iCurrentIndex + i, 
> componentClassType));
> Should be:
> Array.set(targetArray, i, expressionFactory.coerceToType(params[iCurrentIndex 
> + i], componentClassType));

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Created] (GERONIMO-6475) Legacy JNDI context usage support

2013-06-30 Thread Ivan (JIRA)
Ivan created GERONIMO-6475:
--

 Summary: Legacy JNDI context usage support
 Key: GERONIMO-6475
 URL: https://issues.apache.org/jira/browse/GERONIMO-6475
 Project: Geronimo
  Issue Type: Bug
  Security Level: public (Regular issues)
  Components: naming
Affects Versions: 3.0.1
Reporter: Ivan
Assignee: Ivan
 Fix For: 3.0.2


One tradition usage for JNDI API is that, the users could configure a factory 
class while creating the Context instance, and the jar file contains the 
context factory is shipped in the user application. 

Hashtable env = new Hashtable();
env.put(Context.INITIAL_CONTEXT_FACTORY, "org.apache.myContextFactory");
InitialContext ctx = new InitialContext(env);

While moving to OSGi, the typical scenario above will not work, as the current 
JNDI lookup follows the JNDI OSGi spec, except that the configured factory 
could be loaded from JRE, we will always return the default XBean context.

I could saw two solutions for this, 

a. Enable the leagacy JNDI support from Aries

http://svn.apache.org/repos/asf/aries/tags/jndi-0.3/jndi-legacy-support/src/main/java/org/apache/aries/jndi/legacy/support/LegacyInitialContextFinder.java

b. Add the similar logic in our DefaultInitialContextFactoryBuilder.

I would prefer the option b, considering the logic is so simple, and there is 
no need to import another  jar file, also, we may not suffer the potential 
ordering issue, since the current DefaultInitialContextFactoryBuilder will 
always return one context instance.

Another reason is that, in my opinion, once the users have specified the 
context factory and we failed to create the jndi context, there is no need to 
for the next step trying, also, the log should be print to notify the users for 
the errors.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


Legacy JNDI support ?

2013-06-27 Thread Ivan
Hi,

One tradition usage for JNDI API is that, the users could configure a
factory class while creating the Context instance, and the jar file
contains the context factory is shipped in the user application.

Hashtable env = new Hashtable();
env.put(Context.INITIAL_CONTEXT_FACTORY, "org.apache.myContextFactory");
InitialContext ctx = new InitialContext(env);

While moving to OSGi, the typical scenario above will not work, as the
current JNDI lookup follows the JNDI OSGi spec, except that the configured
factory could be loaded from JRE, we will always return the default XBean
context.

I could saw two solutions for this,

a. Enable the leagacy JNDI support from Aries

http://svn.apache.org/repos/asf/aries/tags/jndi-0.3/jndi-legacy-support/src/main/java/org/apache/aries/jndi/legacy/support/LegacyInitialContextFinder.java

b. Add the similar logic in our DefaultInitialContextFactoryBuilder.

I would prefer the option b, considering the logic is so simple, and there
is no need to import another  jar file, also, we may not suffer the
potential ordering issue, since the current
DefaultInitialContextFactoryBuilder will always return one context instance.

Thoughts ?

-- 
Ivan


[jira] [Resolved] (GERONIMO-6469) EJB annotations are not working in Geronimo 3.0

2013-06-04 Thread Ivan (JIRA)

 [ 
https://issues.apache.org/jira/browse/GERONIMO-6469?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Ivan resolved GERONIMO-6469.


Resolution: Cannot Reproduce
  Assignee: Ivan

Nayela, I went ahead to change this as could not reproduce, you may reopen this 
if have a sample to reproduce that.
Thanks.

> EJB annotations are not working in Geronimo 3.0
> ---
>
> Key: GERONIMO-6469
> URL: https://issues.apache.org/jira/browse/GERONIMO-6469
> Project: Geronimo
>  Issue Type: Bug
>  Security Level: public(Regular issues) 
>Reporter: Nayela Manzoor
>Assignee: Ivan
>
> EJB annotations, for exampe, EJB, Stateless, aroundinvoke are not working in 
> Geronimo 3.0. I have current application running well in Geronimo 2.0.1. I 
> deployed it on Geronimo 3.0 and got many issues due to EJB annotation 
> failures. I had to replace EJB annotations with descriptors in ejb-jar file.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Resolved] (GERONIMO-6471) IllegalStateException : Cause already initialized is thrown while mail provider failed to connect or sent the messages

2013-06-04 Thread Ivan (JIRA)

 [ 
https://issues.apache.org/jira/browse/GERONIMO-6471?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Ivan resolved GERONIMO-6471.


Resolution: Fixed

> IllegalStateException : Cause already initialized is thrown while mail 
> provider failed to connect or sent the messages
> --
>
> Key: GERONIMO-6471
> URL: https://issues.apache.org/jira/browse/GERONIMO-6471
> Project: Geronimo
>  Issue Type: Bug
>  Security Level: public(Regular issues) 
>  Components: mail
>Affects Versions: 3.0.1
>Reporter: Ivan
>Assignee: Ivan
> Fix For: 3.0.2
>
>
> If the Geronimo mail failed to connect or send the messages, it would thrown 
> the exception below. The most issue here is that, MessagingException uses a 
> legacy chain throwable, and a next exception is maintained in the codes, 
> while our codes would call initCause to configure the root cause for the 
> first time, this may bring issue if the original MessagingException is 
> initialized with null root cause.
> java.lang.IllegalStateException: Cause already initialized
>   at java.lang.Throwable.initCause(Throwable.java:275)
>   at 
> javax.mail.MessagingException.setNextException(MessagingException.java:51)
>   at javax.mail.Transport.send(Transport.java:109)
>   at javax.mail.Transport.send(Transport.java:48)
>   at 
> com.mybankersbank.gateway.email.GatewayEmailBean.sendEmail(GatewayEmailBean.java:297)
>   at sun.reflect.GeneratedMethodAccessor1221.invoke(Unknown Source)
>   at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>   at java.lang.reflect.Method.invoke(Method.java:600)
>   at 
> org.apache.openejb.core.interceptor.ReflectionInvocationContext$Invocation.invoke(ReflectionInvocationContext.java:158)

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Commented] (GERONIMO-6471) IllegalStateException : Cause already initialized is thrown while mail provider failed to connect or sent the messages

2013-06-04 Thread Ivan (JIRA)

[ 
https://issues.apache.org/jira/browse/GERONIMO-6471?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13675527#comment-13675527
 ] 

Ivan commented on GERONIMO-6471:


Commit the changes to trunk at rev. 1489683

> IllegalStateException : Cause already initialized is thrown while mail 
> provider failed to connect or sent the messages
> --
>
> Key: GERONIMO-6471
> URL: https://issues.apache.org/jira/browse/GERONIMO-6471
> Project: Geronimo
>  Issue Type: Bug
>  Security Level: public(Regular issues) 
>  Components: mail
>Affects Versions: 3.0.1
>    Reporter: Ivan
>Assignee: Ivan
> Fix For: 3.0.2
>
>
> If the Geronimo mail failed to connect or send the messages, it would thrown 
> the exception below. The most issue here is that, MessagingException uses a 
> legacy chain throwable, and a next exception is maintained in the codes, 
> while our codes would call initCause to configure the root cause for the 
> first time, this may bring issue if the original MessagingException is 
> initialized with null root cause.
> java.lang.IllegalStateException: Cause already initialized
>   at java.lang.Throwable.initCause(Throwable.java:275)
>   at 
> javax.mail.MessagingException.setNextException(MessagingException.java:51)
>   at javax.mail.Transport.send(Transport.java:109)
>   at javax.mail.Transport.send(Transport.java:48)
>   at 
> com.mybankersbank.gateway.email.GatewayEmailBean.sendEmail(GatewayEmailBean.java:297)
>   at sun.reflect.GeneratedMethodAccessor1221.invoke(Unknown Source)
>   at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>   at java.lang.reflect.Method.invoke(Method.java:600)
>   at 
> org.apache.openejb.core.interceptor.ReflectionInvocationContext$Invocation.invoke(ReflectionInvocationContext.java:158)

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Updated] (GERONIMO-6471) IllegalStateException : Cause already initialized is thrown while mail provider failed to connect or sent the messages

2013-06-03 Thread Ivan (JIRA)

 [ 
https://issues.apache.org/jira/browse/GERONIMO-6471?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Ivan updated GERONIMO-6471:
---

Affects Version/s: (was: 3.0.2)
Fix Version/s: 3.0.2

> IllegalStateException : Cause already initialized is thrown while mail 
> provider failed to connect or sent the messages
> --
>
> Key: GERONIMO-6471
> URL: https://issues.apache.org/jira/browse/GERONIMO-6471
> Project: Geronimo
>  Issue Type: Bug
>  Security Level: public(Regular issues) 
>  Components: mail
>Affects Versions: 3.0.1
>Reporter: Ivan
>Assignee: Ivan
> Fix For: 3.0.2
>
>
> If the Geronimo mail failed to connect or send the messages, it would thrown 
> the exception below. The most issue here is that, MessagingException uses a 
> legacy chain throwable, and a next exception is maintained in the codes, 
> while our codes would call initCause to configure the root cause for the 
> first time, this may bring issue if the original MessagingException is 
> initialized with null root cause.
> java.lang.IllegalStateException: Cause already initialized
>   at java.lang.Throwable.initCause(Throwable.java:275)
>   at 
> javax.mail.MessagingException.setNextException(MessagingException.java:51)
>   at javax.mail.Transport.send(Transport.java:109)
>   at javax.mail.Transport.send(Transport.java:48)
>   at 
> com.mybankersbank.gateway.email.GatewayEmailBean.sendEmail(GatewayEmailBean.java:297)
>   at sun.reflect.GeneratedMethodAccessor1221.invoke(Unknown Source)
>   at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>   at java.lang.reflect.Method.invoke(Method.java:600)
>   at 
> org.apache.openejb.core.interceptor.ReflectionInvocationContext$Invocation.invoke(ReflectionInvocationContext.java:158)

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Created] (GERONIMO-6471) IllegalStateException : Cause already initialized is thrown while mail provider failed to connect or sent the messages

2013-06-03 Thread Ivan (JIRA)
Ivan created GERONIMO-6471:
--

 Summary: IllegalStateException : Cause already initialized is 
thrown while mail provider failed to connect or sent the messages
 Key: GERONIMO-6471
 URL: https://issues.apache.org/jira/browse/GERONIMO-6471
 Project: Geronimo
  Issue Type: Bug
  Security Level: public (Regular issues)
  Components: mail
Affects Versions: 3.0.1, 3.0.2
Reporter: Ivan
Assignee: Ivan


If the Geronimo mail failed to connect or send the messages, it would thrown 
the exception below. The most issue here is that, MessagingException uses a 
legacy chain throwable, and a next exception is maintained in the codes, while 
our codes would call initCause to configure the root cause for the first time, 
this may bring issue if the original MessagingException is initialized with 
null root cause.

java.lang.IllegalStateException: Cause already initialized
at java.lang.Throwable.initCause(Throwable.java:275)
at 
javax.mail.MessagingException.setNextException(MessagingException.java:51)
at javax.mail.Transport.send(Transport.java:109)
at javax.mail.Transport.send(Transport.java:48)
at 
com.mybankersbank.gateway.email.GatewayEmailBean.sendEmail(GatewayEmailBean.java:297)
at sun.reflect.GeneratedMethodAccessor1221.invoke(Unknown Source)
at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:600)
at 
org.apache.openejb.core.interceptor.ReflectionInvocationContext$Invocation.invoke(ReflectionInvocationContext.java:158)

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


Re: [VOTE] Geronimo devtools maven-eclipsepde-plugin 1.2 release

2013-05-30 Thread Ivan
+1


2013/5/30 Shawn Jiang 

> +1
>
>
> On Wed, May 29, 2013 at 2:46 PM, Forrest Xia  wrote:
>
>> Hi all,
>>
>> To make Geronimo eclipse plugin compiled on Mac OS, we need to release a
>> new maven-eclipsepde-plugin 1.2.
>>
>> Here are artifacts for vote:
>> Source code:
>>
>> https://repository.apache.org/content/repositories/orgapachegeronimo-030/org/apache/geronimo/devtools/maven-eclipsepde-plugin/1.2/maven-eclipsepde-plugin-1.2-sources.jar
>>
>> svn tag:
>>
>> http://svn.apache.org/repos/asf/geronimo/devtools/maven-plugins/tags/maven-plugins-1.2/
>>
>> NOTE: please build it with maven 2.2.1 and Java 6.
>>
>> Vote will be at most open for 72 hours.
>> [ ] +1  approve
>> [ ] +0  no opinion
>> [ ] -1  disapprove (and reason why)
>>
>>
>> --
>> Thanks!
>>
>> Regards, Forrest
>>
>
>
>
> --
> Shawn
>



-- 
Ivan


  1   2   3   4   5   6   7   8   9   10   >