Skip to content

Commit 52533db

Browse files
[DBMON-6787] Remove duplicated agent_hostname logic from sqlserver (#24271)
* [DBMON-6787] Remove duplicated agent_hostname logic from sqlserver Co-authored-by: Cursor <cursoragent@cursor.com> * Add changelog Co-authored-by: Cursor <cursoragent@cursor.com> --------- Co-authored-by: Cursor <cursoragent@cursor.com>
1 parent cf39c0e commit 52533db

2 files changed

Lines changed: 1 addition & 8 deletions

File tree

sqlserver/changelog.d/24271.fixed

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Remove duplicated agent_hostname logic now provided by the DatabaseCheck base class.

sqlserver/datadog_checks/sqlserver/sqlserver.py

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,6 @@ def __init__(self, name, init_config, instances):
146146
)
147147

148148
self._resolved_hostname = None
149-
self._agent_hostname = None
150149
self._database_hostname = None
151150
self._database_identifier = None
152151
self._connection = None
@@ -504,13 +503,6 @@ def debug_stats_kwargs(self, tags=None):
504503
"raw": True,
505504
}
506505

507-
@property
508-
def agent_hostname(self):
509-
# type: () -> str
510-
if self._agent_hostname is None:
511-
self._agent_hostname = datadog_agent.get_hostname()
512-
return self._agent_hostname
513-
514506
@property
515507
def connection(self):
516508
if self._connection is None:

0 commit comments

Comments
 (0)