Exemplo n.º 1
0
Arquivo: node.go Projeto: rnd-ua/scope
func podParent(n report.Node) Parent {
	return Parent{
		ID:         render.MakePodID(n.Metadata[kubernetes.PodID]),
		Label:      n.Metadata[kubernetes.PodName],
		TopologyID: "pods",
	}
}
Exemplo n.º 2
0
func podNodeSummary(nmd report.Node) NodeSummary {
	return NodeSummary{
		ID:       render.MakePodID(nmd.Metadata[kubernetes.PodID]),
		Label:    nmd.Metadata[kubernetes.PodName],
		Linkable: true,
		Metadata: podNodeMetadata(nmd),
	}
}
Exemplo n.º 3
0
func podParent(n report.Node) Parent {
	podID, _ := n.Latest.Lookup(kubernetes.PodID)
	podName, _ := n.Latest.Lookup(kubernetes.PodName)
	return Parent{
		ID:         render.MakePodID(podID),
		Label:      podName,
		TopologyID: "pods",
	}
}
Exemplo n.º 4
0
			ID:           pseudoHostID2,
			LabelMajor:   fixture.UnknownClient3IP,
			Pseudo:       true,
			Node:         report.MakeNode().WithAdjacent(ServerHostRenderedID),
			EdgeMetadata: report.EdgeMetadata{},
		},
		render.TheInternetID: {
			ID:           render.TheInternetID,
			LabelMajor:   render.TheInternetMajor,
			Pseudo:       true,
			Node:         report.MakeNode().WithAdjacent(ServerHostRenderedID),
			EdgeMetadata: report.EdgeMetadata{},
		},
	}).Prune()

	ClientPodRenderedID = render.MakePodID("ping/pong-a")
	ServerPodRenderedID = render.MakePodID("ping/pong-b")

	RenderedPods = (render.RenderableNodes{
		ClientPodRenderedID: {
			ID:         ClientPodRenderedID,
			LabelMajor: "pong-a",
			LabelMinor: "1 container",
			Rank:       "ping/pong-a",
			Pseudo:     false,
			Children: report.MakeNodeSet(
				fixture.Report.Process.Nodes[fixture.ClientProcess1NodeID],
				fixture.Report.Process.Nodes[fixture.ClientProcess2NodeID],
				fixture.Report.Container.Nodes[fixture.ClientContainerNodeID],
				fixture.Report.ContainerImage.Nodes[fixture.ClientContainerImageNodeID],
				fixture.Report.Pod.Nodes[fixture.ClientPodNodeID],
Exemplo n.º 5
0
func podNodeSummary(nmd report.Node) NodeSummary {
	podID, _ := nmd.Latest.Lookup(kubernetes.PodID)
	podName, _ := nmd.Latest.Lookup(kubernetes.PodName)
	return baseNodeSummary(render.MakePodID(podID), podName, true, nmd)
}