Skip to content

feat: add FederatedLogSetup, AwsConnection, and FederatedLogPartition entity support to pipelinecontrol#1377

Open
voorepreethi wants to merge 1 commit intonewrelic:mainfrom
voorepreethi:fedLogsSetup
Open

feat: add FederatedLogSetup, AwsConnection, and FederatedLogPartition entity support to pipelinecontrol#1377
voorepreethi wants to merge 1 commit intonewrelic:mainfrom
voorepreethi:fedLogsSetup

Conversation

@voorepreethi
Copy link
Copy Markdown

@voorepreethi voorepreethi commented Mar 10, 2026

Summary
Adds support for three new entity types in the pipelinecontrol package: FederatedLogSetupEntity, AwsConnectionEntity, and FederatedLogPartitionEntity. These enable full lifecycle management of federated log infrastructure resources via the Entity Management API.

Changes
New API Methods
Federated Log Setup

EntityManagementCreateFederatedLogSetup / WithContext — create a Federated Log Setup entity
EntityManagementUpdateFederatedLogSetup / WithContext — update an existing Federated Log Setup entity
Federated Log Partition

EntityManagementCreateFederatedLogPartition / WithContext — create a Federated Log Partition entity
EntityManagementUpdateFederatedLogPartition / WithContext — update an existing Federated Log Partition entity
AWS Connection

EntityManagementCreateAwsConnection / WithContext — create an AWS Connection entity
Search

GetEntitySearch / WithContext — search entities with filters and cursor-based pagination

Tests
Unit Tests (27 total)
Federated Log Setup (6)

Create: success, with-context, error
Update: success, with-context, error
Federated Log Partition (6)

Create: success, with-context, error
Update: success, with-context, error
AWS Connection (3)

Create: success, with-context, error
GetEntity (2)

Returns FederatedLogSetupEntity type assertion
Returns AwsConnectionEntity type assertion
GetEntitySearch (4)

Success, with-context, empty results, error

Integration Tests
TestIntegrationEntityManagement_FederatedLogSetup_CRUD — full create/read/update/delete cycle (gated by RUN_FEDERATED_LOG_SETUP_TEST=true)
TestIntegrationEntityManagement_FederatedLogSetup_Create — standalone create test with real credentials (gated by env vars)

@voorepreethi voorepreethi changed the title Fed logs setup feat: fed logs setup Mar 10, 2026
@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented Mar 10, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 31.92%. Comparing base (25308d5) to head (4256acc).
⚠️ Report is 9 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1377      +/-   ##
==========================================
- Coverage   33.04%   31.92%   -1.12%     
==========================================
  Files         136      140       +4     
  Lines        6256     6737     +481     
==========================================
+ Hits         2067     2151      +84     
- Misses       3990     4386     +396     
- Partials      199      200       +1     
Flag Coverage Δ
unit 31.92% <100.00%> (-1.12%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@voorepreethi voorepreethi force-pushed the fedLogsSetup branch 7 times, most recently from f04274e to 3630c2a Compare March 13, 2026 11:28
@voorepreethi voorepreethi changed the title feat: fed logs setup feat: add FederatedLogSetup, AwsConnection, and FederatedLogPartition entity support to pipelinecontrol Mar 13, 2026
@voorepreethi voorepreethi force-pushed the fedLogsSetup branch 5 times, most recently from 4cd4961 to 45098aa Compare March 16, 2026 06:08
@voorepreethi voorepreethi force-pushed the fedLogsSetup branch 2 times, most recently from 67711f6 to f7ba608 Compare March 24, 2026 08:34
…dLogPartition support with update/delete mutations and tests
Copy link
Copy Markdown

@maya-jha maya-jha left a comment

Choose a reason for hiding this comment

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

Can you please mention which files are auto generated and which files are updated by you?

- name: entityManagementCreateFederatedLogSetup
max_query_field_depth: 4
- name: entityManagementCreateAwsConnection
max_query_field_depth: 3
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

how do we decide this?

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.

This is the reason : max_query_field_depth = deepest nesting level in the GraphQL response. AwsConnection has 3 levels (entity → credential → assumeRole), FederatedLogSetup and FederatedLogPartition have 4 levels (entity → metadata → createdBy → __typename). Tutone uses this to know how deep to generate fields.

require.Error(t, err)
require.Nil(t, result)
}

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Is this file auto generated?

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.

No

Copy link
Copy Markdown

@maya-jha maya-jha left a comment

Choose a reason for hiding this comment

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

I see fleet related entity here: https://github.com/newrelic/newrelic-client-go/tree/30c29f31adbfcfcd7c9f41b9da6b4473284c9e6c/pkg/fleetcontrol . Can we get some guidance from the owning team of this repo whether we should create a new folder for federated logs? How much effort required if we move to a dedicated folder?

@voorepreethi
Copy link
Copy Markdown
Author

Files are not autogenerated. Code is .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants