-
Bug
-
Resolution: Won't Do
-
Major
-
None
-
1.35.0
-
None
-
False
-
-
False
-
-
When we have an OpenAPI document like this:
/: <--- root path
get:
operationId: test
tags:
- Greeting Resource
responses:
"200":
description: OK
security:
- BearerToken: [ ]
that for example is configured this way:
quarkus.oidc-client.BearerToken.auth-server-url=http://localhost:8281/auth/realms/kogito/protocol/openid-connect/auth quarkus.oidc-client.BearerToken.token-path=http://localhost:8281/auth/realms/kogito/protocol/openid-connect/token quarkus.oidc-client.BearerToken.discovery-enabled=false quarkus.oidc-client.BearerToken.client-id=kogito-app quarkus.oidc-client.BearerToken.grant.type=client quarkus.oidc-client.BearerToken.credentials.client-secret.method=basic quarkus.oidc-client.BearerToken.credentials.client-secret.value=secret #propagation enabled quarkus.openapi-generator.rest_service_yaml.auth.BearerToken.token-propagation=true #the service url ends with test quarkus.rest-client.rest_service_yaml.url=https://localhost:8443/test
That bearer token propagation is not produced, because the openapi operationId test, is declared for the root path.
This is the bug.
NOTE:
we have the following valid workaround, by doing the following translation:
# Remove the path test from the property configuration quarkus.rest-client.rest_service_yaml.url=https://localhost:8443
/test: <--- give the operation the path test
get:
operationId: test
tags:
- Greeting Resource
responses:
"200":
description: OK
security:
- BearerToken: [ ]
With this small translation the propagation works fine.