@Override protected String featureValueOf(Flow flow) { return flow.getIngressInterface(); } }
/** * Does a basic validation of input to {@link * TracerouteEngineImplContext#buildTracesAndReturnFlows()} * * @param configurations {@link Map} of {@link Configuration}s * @param flow {@link Flow} for which input validation is to be done */ static void validateInputs(Map<String, Configuration> configurations, Flow flow) { String ingressNodeName = flow.getIngressNode(); checkArgument( ingressNodeName != null, "Cannot construct flow trace since ingressNode is not specified"); Configuration ingressNode = configurations.get(ingressNodeName); checkArgument( ingressNode != null, "Node %s is not in the network, cannot perform traceroute", ingressNodeName); String ingressIfaceName = flow.getIngressInterface(); if (ingressIfaceName != null) { checkArgument( ingressNode.getAllInterfaces().get(ingressIfaceName) != null, "%s interface does not exist on the node %s", ingressIfaceName, ingressNodeName); } checkArgument( flow.getDstIp() != null, "Cannot construct flow trace since dstIp is not specified"); }
List<Hop> hops = new ArrayList<>(); Stack<Breadcrumb> breadcrumbs = new Stack<>(); String ingressInterfaceName = flow.getIngressInterface(); if (ingressInterfaceName != null) { TransmissionContext transmissionContext =
String ingressInterfaceName = flow.getIngressInterface(); if (ingressInterfaceName != null) { Edge edge =
filter, flow, flow.getIngressInterface(), c.getIpAccessLists(), c.getIpSpaces(), c.getIpSpaceMetadata()); FilterResult result = filter.filter(flow, flow.getIngressInterface(), c.getIpAccessLists(), c.getIpSpaces()); Integer matchLine = result.getMatchLine(); String lineDesc = "no-match";