pinpoint-apm/pinpoint · error · BindException

metric binding error. header=hostGroupName

Error message

metric binding error. header=hostGroupName:{} errorCount:{} {}

What it means

Warn log in TelegrafMetricController.saveSystemMetric: binding incoming Telegraf metric messages to metric definitions failed for some items; the message records the hostGroupName and errorCount plus details so partial ingestion loss can be traced.

Solutions

  1. Check that telegraf metric/field names match configured metric definitions
  2. Verify tenant/hostGroupName registration before ingestion
  3. Log and skip invalid samples while returning a summary so senders can fix labels
Defensive patterns

Strategy: fallback

When it happens

Trigger: Thrown at metric-module/metric/src/main/java/com/navercorp/pinpoint/metric/collector/controller/TelegrafMetricController.java:84 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of pinpoint-apm/pinpoint@744c3d3075 (2026-09-07). Data as JSON: /api/errors/ed73bd66fc135182. Report an issue: GitHub.

Appendix: source

Thrown at metric-module/metric/src/main/java/com/navercorp/pinpoint/metric/collector/controller/TelegrafMetricController.java:84

    public TelegrafMetricController(SystemMetricService systemMetricService,
                                    SystemMetricDataTypeService systemMetricMetadataService,
                                    SystemMetricTagService systemMetricTagService,
                                    TenantProvider tenantProvider) {
        this.systemMetricService = Objects.requireNonNull(systemMetricService, "systemMetricService");
        this.systemMetricMetadataService = Objects.requireNonNull(systemMetricMetadataService, "systemMetricMetadataService");
        this.systemMetricTagService = Objects.requireNonNull(systemMetricTagService, "systemMetricTagService");
        this.tenantProvider = Objects.requireNonNull(tenantProvider, "tenantProvider");
    }


    @PostMapping(value = "/telegraf")
    public ResponseEntity<String> saveSystemMetric(
            @RequestHeader(value = "hostGroupName") String hostGroupName,
            @RequestBody TelegrafMetrics telegrafMetrics, BindingResult bindingResult
    ) throws BindException {
        if (bindingResult.hasErrors()) {
            SimpleErrorMessage simpleErrorMessage = new SimpleErrorMessage(bindingResult);
            logger.warn("metric binding error. header=hostGroupName:{} errorCount:{} {}", hostGroupName, bindingResult.getErrorCount(), simpleErrorMessage);
            throw new BindException(bindingResult);
        }

        if (!isValidGroupName(hostGroupName)) {
            logger.warn("invalid hostGroupName='{}'", hostGroupName);
            return ResponseEntity.badRequest().body("invalid hostGroupName='" + hostGroupName + "'");
        }

        String hostName = getHost(telegrafMetrics);
        if (StringUtils.isEmpty(hostName)) {
            // hostname null check
            logger.info("hostName is empty. hostGroupName={}", hostGroupName);
            return ResponseEntity.badRequest().body("hostName is empty");
        }

        if (!isValidHostName(hostName)) {
            logger.warn("invalid hostName='{}', hostGroupName='{}'", hostName, hostGroupName);
        }

View on GitHub (pinned to 744c3d3075)