This pull request introduces a new POP configuration setting to the sciDX API, allowing for conditional visibility of specific routes based on the POP environment variable.
Key Changes:
POP Configuration:
Added POP environment variable to .env_swagger, defaulting to False.
Integrated the POP setting in swagger_settings.py to control route visibility.
Route Visibility:
When POP is True, the POST /stream and GET /stream endpoints are hidden from the API.
When POP is False, all routes, including POST /stream and GET /stream, are visible.
Tests:
Added tests to verify the correct behavior of route visibility based on the POP setting.
Purpose:
This feature enables the API to be configured for use as a Point of Presence (POP) within the NDP project, where only a subset of the API's routes is needed.
This pull request introduces a new
POP
configuration setting to the sciDX API, allowing for conditional visibility of specific routes based on thePOP
environment variable.Key Changes:
POP Configuration:
POP
environment variable to.env_swagger
, defaulting toFalse
.POP
setting inswagger_settings.py
to control route visibility.Route Visibility:
POP
isTrue
, thePOST /stream
andGET /stream
endpoints are hidden from the API.POP
isFalse
, all routes, includingPOST /stream
andGET /stream
, are visible.Tests:
POP
setting.Purpose: This feature enables the API to be configured for use as a Point of Presence (POP) within the NDP project, where only a subset of the API's routes is needed.