Skip to content

Aclp logs support#799

Open
pskupien-akamai wants to merge 33 commits into
linode:devfrom
pskupien-akamai:aclp-logs-destination
Open

Aclp logs support#799
pskupien-akamai wants to merge 33 commits into
linode:devfrom
pskupien-akamai:aclp-logs-destination

Conversation

@pskupien-akamai
Copy link
Copy Markdown

📝 Description

Adds support for monitor logs functionality
What does this PR do and why is this change necessary?

  1. Adds full SDK support for monitor Logs API. This includes both the destinations and streams.
  2. This is a new feature not yet supported in the official version of SDK, but is built upon ready-to-merge pull request in linode_api4-python.
  3. Adds integration tests and documentation for newly implemented features.
    1. Full e2e test for streams require a stream to complete provisioning - based on experience during development this can take up to an hour. Similarly to what's already present for database related tests, an environment variable (RUN_ACLP_LOGS_STREAM_TESTS) needs to be set as true or yes to enable testing the Stream portion of the API.
    2. Logs Destination is tested only for akamai storage bucket cases - custom https storage endpoints are not tested but supported.

✔️ How to Test

This feature is based on ready-to-merge pull request in linode_api4-python. To test this feature before the merge it's required to install this package via running terminal command which enables LogsDestination components:
pip install --upgrade --force-reinstall "git+https://github.com/linode/linode_api4-python.git@refs/pull/686/head#egg=linode_api4"

How do I run the relevant unit/integration tests?

  1. Follow usual installation/setup steps
  2. run make test-int TEST_SUITE="monitor_logs_destination" to test logs destinations
  3. before running stream tests you need to run export RUN_ACLP_LOGS_STREAM_TESTS=true
  4. run make test-int TEST_SUITE="monitor_logs_stream" to test streams

Notes:

  • Stream integration tests by default are skipped if no export RUN_ACLP_LOGS_STREAM_TESTS=true is provided

pskupien-akamai and others added 30 commits May 8, 2026 11:17
…tion-api-signed' into DPS-42284-ACLP-Logs-Streams-API-internal-review
…gned' into DPS-42284-ACLP-Logs-Streams-API-internal-review
…I-internal-review

ACLP Logs - Implement streams api + tests
…-aclp-logs-destination-api-revert-requirements

revert requirements.txt
…-aclp-logs-destination-api-signed

Dps 42283 aclp sdk ansible aclp logs destination api signed
@pskupien-akamai pskupien-akamai requested review from a team as code owners May 15, 2026 08:29
@pskupien-akamai pskupien-akamai requested review from jriddle-linode and psnoch-akamai and removed request for a team May 15, 2026 08:29
@yec-akamai yec-akamai requested review from yec-akamai and removed request for jriddle-linode May 19, 2026 13:23
Comment thread plugins/modules/monitor_logs_stream.py Outdated
Comment on lines +54 to +56
"This can be ``audit_logs`` for logs consisting of all of the control plane "
"operations for the services in your Linodes, or ``lke_audit_logs`` for log data "
"for your Linode Kubernetes Engine (LKE) enterprise clusters.",
Comment on lines +181 to +183
def _get_stream(
self, stream_id: Optional[int], label: Optional[str]
) -> Any:
Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed by adding return self.fail(...)

self._handle_present()
return self.results

def _wait_for_status(self, stream: Any, force: bool = False) -> Any:
Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed by adding return self.fail(...)

@yec-akamai yec-akamai requested a review from Copilot May 19, 2026 13:48
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds Ansible collection support for Akamai Cloud Linode “Monitor Logs” (ACLP logs) by introducing new modules for Logs Destinations and Logs Streams, along with generated docs and integration coverage.

Changes:

  • Adds CRUD/info/list/history modules for Monitor Logs Destinations and Streams.
  • Adds integration test suites for destinations and (optionally gated) streams, plus CI/Makefile wiring for the stream-test flag.
  • Updates collection documentation (README module index + per-module docs/specdoc fragments).

Reviewed changes

Copilot reviewed 31 out of 31 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
tests/integration/targets/monitor_logs_stream/tasks/main.yaml New end-to-end integration coverage for stream lifecycle (guarded by RUN_ACLP_LOGS_STREAM_TESTS).
tests/integration/targets/monitor_logs_destination/tasks/main.yaml New integration coverage for destination lifecycle and list/info/history behaviors.
README.md Adds new Monitor Logs modules to the documented module list.
plugins/modules/monitor_logs_stream.py Implements create/update/delete for Logs Streams, including optional wait/polling.
plugins/modules/monitor_logs_stream_list.py Adds list module for streams via the shared ListModule helper.
plugins/modules/monitor_logs_stream_info.py Adds info module for streams by ID/label via InfoModule.
plugins/modules/monitor_logs_stream_history.py Adds list/history module for stream history.
plugins/modules/monitor_logs_destination.py Implements create/update/delete for Logs Destinations, including type-specific details handling and wait.
plugins/modules/monitor_logs_destination_list.py Adds list module for destinations via the shared ListModule helper.
plugins/modules/monitor_logs_destination_info.py Adds info module for destinations by ID/label via InfoModule.
plugins/modules/monitor_logs_destination_history.py Adds list/history module for destination history.
plugins/module_utils/linode_helper.py Adds api_filter_for_aclp_logs_services to support logs endpoints filtering + ordering.
plugins/module_utils/doc_fragments/monitor_logs_stream.py Specdoc examples + result samples for stream module.
plugins/module_utils/doc_fragments/monitor_logs_stream_list.py Specdoc examples + result samples for stream list module.
plugins/module_utils/doc_fragments/monitor_logs_stream_info.py Specdoc examples for stream info module.
plugins/module_utils/doc_fragments/monitor_logs_stream_history.py Specdoc examples + result samples for stream history module.
plugins/module_utils/doc_fragments/monitor_logs_destination.py Specdoc examples + result samples for destination module.
plugins/module_utils/doc_fragments/monitor_logs_destination_list.py Specdoc examples + result samples for destination list module.
plugins/module_utils/doc_fragments/monitor_logs_destination_info.py Specdoc examples + result samples for destination info module.
plugins/module_utils/doc_fragments/monitor_logs_destination_history.py Specdoc examples + result samples for destination history module.
Makefile Writes run_aclp_logs_stream_tests into integration config for gating stream tests.
docs/modules/monitor_logs_stream.md Generated module docs for stream.
docs/modules/monitor_logs_stream_list.md Generated module docs for stream list.
docs/modules/monitor_logs_stream_info.md Generated module docs for stream info.
docs/modules/monitor_logs_stream_history.md Generated module docs for stream history.
docs/modules/monitor_logs_destination.md Generated module docs for destination.
docs/modules/monitor_logs_destination_list.md Generated module docs for destination list.
docs/modules/monitor_logs_destination_info.md Generated module docs for destination info.
docs/modules/monitor_logs_destination_history.md Generated module docs for destination history.
.github/workflows/integration-tests.yml Adds workflow input/env wiring for RUN_ACLP_LOGS_STREAM_TESTS.
.github/workflows/integration-tests-pr.yml Adds workflow_dispatch input/env wiring for RUN_ACLP_LOGS_STREAM_TESTS on PR runs.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread tests/integration/targets/monitor_logs_destination/tasks/main.yaml Outdated
Comment thread docs/modules/monitor_logs_destination_info.md Outdated
Comment thread plugins/modules/monitor_logs_destination.py Outdated
Comment thread plugins/modules/monitor_logs_destination.py Outdated
Comment thread plugins/modules/monitor_logs_destination.py
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

communitiy-contributor new-feature for new features in the changelog.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants