newrelic-experimental / newrelic-databricks-integration

This integration collects telemetry from Databricks (including Spark on Databricks) and/or Spark telemetry from any Spark deployment. See the Features section for supported telemetry types.
Apache License 2.0
2 stars 0 forks source link

ID attribute type in query.go should not include anything if column is the empty string #44

Open sdewitt-newrelic opened 1 week ago

sdewitt-newrelic commented 1 week ago

When collecting job cost info, I noticed that the run_as attribute is in the DatabricksJobCost event for the jobs_cost_frequent_failures query is present but empty. Yet the list_cost is not there at all. Both values come back from the SQL query as NULL so the behavior should be consistent, either both there and empty or both not there. I'd rather neither be there. The reason run_as is showing up is because there is not a col == "" check like there is in the columnToXYZ functions. Fix this so we do not include the attribute at all if the attribute value is the empty string.