Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Azure add support for x-ms-AzureResourceId Header #2184

Open
floriankoch opened this issue May 19, 2020 · 1 comment · May be fixed by #2545
Open

Azure add support for x-ms-AzureResourceId Header #2184

floriankoch opened this issue May 19, 2020 · 1 comment · May be fixed by #2545
Assignees

Comments

@floriankoch
Copy link

To use the resoure permission model in Azure Log Analytics, the resourceId needs to be part of the REST call via the x-ms-AzureResourceId header

This was implementet in fluentd recently
yokawasa/fluent-plugin-azure-loganalytics#17

@edsiper edsiper self-assigned this May 20, 2020
floriankoch pushed a commit to floriankoch/fluent-bit that referenced this issue Aug 23, 2020
floriankoch pushed a commit to floriankoch/fluent-bit that referenced this issue Aug 26, 2020
floriankoch pushed a commit to floriankoch/fluent-bit that referenced this issue Aug 26, 2020
@github-actions
Copy link
Contributor

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.

@github-actions github-actions bot added Stale and removed Stale labels May 16, 2021
nif added a commit to nif/fluent-bit that referenced this issue Sep 6, 2021
…-AzureResourceId header

When AzureResourceId is defined, it will be hand over to Azure data-collector-api using
"x-ms-AzureResourceId" http header - as specified in azure documentation:

>> The resource ID of the Azure resource that the data should be associated with.
>> It populates the _ResourceId property and allows the data to be included in resource-context queries.

The documentation is available at:
https://docs.microsoft.com/en-us/azure/azure-monitor/logs/data-collector-api

_ResourceId is something like:
/subscriptions/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/resourceGroups/example-rg/providers/Microsoft.Insights/components/insights-test-01
or just id of some ResourceGroup:
/subscriptions/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/resourceGroups/example-rg

Log records with any _RessourceId (and also records without _RessourceId) are still visible
at the Log Analytics Workspace level. But only log records with corresponding _ResourceId
are visible at the ResourceGroup level - so it is easier to find required records later.
Also access policies can be implemented to allow user to access log records relevant
to some project but disallow access to log records from other projects.

initially suggested by Florian Koch <[email protected]>:
  fluent#2184

Signed-off-by: Evgeny Nifontov <[email protected]>
nif added a commit to nif/fluent-bit that referenced this issue Sep 6, 2021
…-AzureResourceId header

When AzureResourceId is defined, it will be hand over to Azure data-collector-api using
"x-ms-AzureResourceId" http header - as specified in azure documentation:

>> The resource ID of the Azure resource that the data should be associated with.
>> It populates the _ResourceId property and allows the data to be included in resource-context queries.

The documentation is available at:
https://docs.microsoft.com/en-us/azure/azure-monitor/logs/data-collector-api

_ResourceId is id of some resource in Azure:
/subscriptions/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/resourceGroups/example-rg/providers/Microsoft.Insights/components/insights-test-01
or just id of some ResourceGroup:
/subscriptions/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/resourceGroups/example-rg

Log records with any _RessourceId (and also records without _RessourceId) are still visible
at the Log Analytics Workspace level. But only log records with corresponding _ResourceId
are visible at the ResourceGroup level - so it is easier to find required records later.
Also access policies can be implemented to allow user to access log records relevant
to some project but disallow access to log records from other projects.

initially suggested by Florian Koch <[email protected]>:
  fluent#2184

Signed-off-by: Evgeny Nifontov <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants