Created by: andriy-dmytruk
Added ability to apply security roles on operations with the x-roles
extension as in this example:
post:
tags: [books]
summary: Create a new book
operationId: createBook
parameters:
- {name: bookName, in: path, required: true, schema: {type: string}}
requestBody:
content:
application/json: { schema: { $ref: "#/components/schemas/Book" } }
responses:
'200':
description: success
x-roles: ["admin"]
It will be added with Micronaut's @Secured
annotation. Also supports isAuthorized()
, isAnonymous()
and denyAll()
values that will be converted to Micronaut constants.
I ran the following to validate build:
./mvnw clean package
./bin/generate-samples.sh
./bin/utils/export_docs_generators.sh
./bin/meta-codegen.sh
./mvnw integration-test -P "java-micronaut-client,java-micronaut-server"
Java technical committee: @bbdouglas @sreeshas @jfiala @lukoyanov @cbornet @jeff9finger @karismann @Zomzog @lwlee2608