ferruzzi commented on code in PR #66608:
URL: https://github.com/apache/airflow/pull/66608#discussion_r3461287183
##########
airflow-core/src/airflow/api_fastapi/execution_api/routes/connections.py:
##########
@@ -49,15 +54,19 @@ async def has_connection_access(
router = APIRouter(
+ route_class=ExecutionAPIRoute,
responses={status.HTTP_404_NOT_FOUND: {"description": "Connection not
found"}},
- dependencies=[Depends(has_connection_access)],
)
log = logging.getLogger(__name__)
@router.get(
"/{connection_id}",
+ dependencies=[
+ Security(require_auth, scopes=["token:execution", "token:workload"]),
Review Comment:
What's the right fix here? Between this comment and Kaxil's, is there a way
to make this work within the existing token types or do we need a new token
type entirely, maybe, instead of trying to shoe-horn what he is trying to do
into a system that wasn't built for it?
Also, I clearly need to brush up on the tokens and their intended uses. I
didn't know about that intentional down-scoping.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]