plugin/dnstap: support FQDN TCP endpoint (#5377)

* plugin/dnstap: support FQDN TCP endpoint

Signed-off-by: lob <pengyu@pingcap.com>

* plugin/dnstap: remove unused variable

Signed-off-by: lob <pengyu@pingcap.com>
This commit is contained in:
lobshunter
2022-05-13 02:13:26 +08:00
committed by GitHub
parent 092c144491
commit dbb8a12394
4 changed files with 12 additions and 5 deletions

View File

@@ -17,6 +17,8 @@ func TestConfig(t *testing.T) {
{"dnstap dnstap.sock full", "dnstap.sock", true, "unix", false},
{"dnstap unix://dnstap.sock", "dnstap.sock", false, "unix", false},
{"dnstap tcp://127.0.0.1:6000", "127.0.0.1:6000", false, "tcp", false},
{"dnstap tcp://[::1]:6000", "[::1]:6000", false, "tcp", false},
{"dnstap tcp://example.com:6000", "example.com:6000", false, "tcp", false},
{"dnstap", "fail", false, "tcp", true},
}
for i, tc := range tests {