-
Notifications
You must be signed in to change notification settings - Fork 327
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
control-plane: access logs #166
Conversation
2c23e9a
to
a1b6082
Compare
app/kumactl/cmd/get/get_meshes.go
Outdated
@@ -56,9 +56,14 @@ func printMeshes(meshes *mesh.MeshResourceList, out io.Writer) error { | |||
} | |||
mesh := meshes.Items[i] | |||
|
|||
accessLogs := table.OnOff(mesh.Spec.GetLogging().GetAccessLogs().GetEnabled()) | |||
if mesh.Spec.GetLogging().GetAccessLogs().GetEnabled() { | |||
accessLogs += " (" + mesh.Spec.GetLogging().GetAccessLogs().FilePath + ")" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should be GetFilePath()
for safety
app/kumactl/cmd/get/get_meshes.go
Outdated
@@ -46,7 +46,7 @@ func newGetMeshesCmd(pctx *getContext) *cobra.Command { | |||
|
|||
func printMeshes(meshes *mesh.MeshResourceList, out io.Writer) error { | |||
data := printers.Table{ | |||
Headers: []string{"NAME", "MTLS"}, | |||
Headers: []string{"NAME", "MTLS", "DP ACCESS LOGS"}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we rename it into ACCESS LOGS
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It was ACCESS LOGS initially, but Marco wanted to add DP
pkg/xds/envoy/envoy_test.go
Outdated
@@ -118,6 +118,38 @@ var _ = Describe("Envoy", func() { | |||
'@type': type.googleapis.com/envoy.config.filter.network.tcp_proxy.v2.TcpProxy | |||
cluster: localhost:8080 | |||
statPrefix: localhost:8080 | |||
`, | |||
}), | |||
Entry("without transparent proxying", testCase{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
test name could be more relevant
pkg/xds/server/components.go
Outdated
@@ -62,7 +62,9 @@ func DefaultDataplaneSyncTracker(rt core_runtime.Runtime, reconciler SnapshotRec | |||
envoyCtx := xds_context.Context{ | |||
ControlPlane: envoyCpCtx, | |||
Mesh: xds_context.MeshContext{ | |||
TlsEnabled: meshList.Items[0].Spec.Mtls.Enabled, | |||
TlsEnabled: meshList.Items[0].Spec.GetMtls().Enabled, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should be GetEnabled()
for safety
a1b6082
to
99083ec
Compare
Access logs that shows traffic. Due to L4, we are very limited what we can display
Format for now
refernce: https://www.envoyproxy.io/docs/envoy/latest/configuration/observability/access_log
Once we have outbound CDS, we can try
%UPSTREAM_CLUSTER%