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

nri-mssql - Ability to override instance name through configuration #166

Open
david-garcia-garcia opened this issue Jul 10, 2024 · 1 comment
Labels
feature request Categorizes issue or PR as related to a new feature or enhancement.

Comments

@david-garcia-garcia
Copy link

david-garcia-garcia commented Jul 10, 2024

Description

Currently, the entity name is constructed internally by the integration like this:

ms-instance:a7c4e04d109d:instance=a7c4e04d109d

Looking at the source code, this comes from:

const instanceNameQuery = "select COALESCE( @@SERVERNAME, SERVERPROPERTY('ServerName'), SERVERPROPERTY('MachineName')) as instance_name"

When working with dockerized/kuberentes environments, this stops making any sense:

  • ServerName becomes an ephemeral concept, autoasigned by the environment and can change frequently when moving MSSQL pods.

image

The aim of the feature request is to add a configuration item that can be used to override the construct used to produce the inventory key manually.

Maybe something like this:

integrations:
# Integración de solo inventario, no requiere mucha frecuencia...
- name: nri-mssql
  env:
    HOSTNAME: ${HOSTNAME}
    USERNAME: ${USERNAME}
    PASSWORD: ${PASSWORD}
    ENABLE_SSL: true
    TRUST_SERVER_CERTIFICATE: true
    TIMEOUT: 8
    INVENTORY: true
    OVERRIDE_SERVERNAME: {myimaginaryserver}
    OVERRIDE_INSTANCENAME: {myinstance}
  interval: 20s
  labels:
    environment:
    role: mssql
  inventory_source: config/mssql

Acceptance Criteria

Describe Alternatives

Adding labels to the integration, and constructing the MSSQL panels on NR based on labels, which makes the out-of-the-box panels and inventories useless.

Dependencies

Additional context

Estimates

For Maintainers Only or Hero Triaging this bug

Suggested Priority (P1,P2,P3,P4,P5):
Suggested T-Shirt size (S, M, L, XL, Unknown):

@david-garcia-garcia david-garcia-garcia added the feature request Categorizes issue or PR as related to a new feature or enhancement. label Jul 10, 2024
@workato-integration
Copy link

@workato-integration workato-integration bot changed the title Ability to override instance name through configuration nri-mssql - Ability to override instance name through configuration Aug 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request Categorizes issue or PR as related to a new feature or enhancement.
Projects
None yet
Development

No branches or pull requests

1 participant