summaryrefslogtreecommitdiffhomepage
path: root/types/netlogtype
AgeCommit message (Collapse)AuthorFilesLines
2023-01-27all: update copyright and license headersWill Norris2-6/+4
This updates all source files to use a new standard header for copyright and license declaration. Notably, copyright no longer includes a date, and we now use the standard SPDX-License-Identifier header. This commit was done almost entirely mechanically with perl, and then some minimal manual fixes. Updates #6865 Signed-off-by: Will Norris <will@tailscale.com>
2022-12-16net/connstats: enforce maximum number of connections (#6760)Joe Tsai1-0/+9
The Tailscale logging service has a hard limit on the maximum log message size that can be accepted. We want to ensure that netlog messages never exceed this limit otherwise a client cannot transmit logs. Move the goroutine for periodically dumping netlog messages from wgengine/netlog to net/connstats. This allows net/connstats to manage when it dumps messages, either based on time or by size. Updates tailscale/corp#8427 Signed-off-by: Joe Tsai <joetsai@digital-static.net>
2022-11-09types/netlogtype: add constants for maximum serialized sizes of ↵Joe Tsai2-14/+82
ConnectionCounts (#6163) There is a finite limit to the maximum message size that logtail can upload. We need to make sure network logging messages remain under this size. These constants allow us to compute the maximum number of ConnectionCounts we can buffer before we must flush. Signed-off-by: Joe Tsai <joetsai@digital-static.net>
2022-10-28wgengine/netlog: embed the StableNodeID of the authoring node (#6105)Joe Tsai1-0/+6
This allows network messages to be annotated with which node it came from. Signed-off-by: Joe Tsai <joetsai@digital-static.net>
2022-10-27types/netlogtype: new package for network logging types (#6092)Joe Tsai1-0/+58
The netlog.Message type is useful to depend on from other packages, but doing so would transitively cause gvisor and other large packages to be linked in. Avoid this problem by moving all network logging types to a single package. We also update staticcheck to take in: https://github.com/dominikh/go-tools/commit/003d277bcf3bcc320b9fddf720cd0d49e0bfb782 Signed-off-by: Joe Tsai <joetsai@digital-static.net>