Skip to content

Commit cbb137f

Browse files
authored
Merge branch 'dev' into wrap-host
2 parents 7937b12 + d6a836d commit cbb137f

4 files changed

Lines changed: 10 additions & 11 deletions

File tree

src/main/Cargo.lock

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/main/core/support/configuration.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -665,7 +665,6 @@ const ONE_GBIT_SWITCH_TOPOLOGY: &str = r#"<?xml version="1.0" encoding="utf-8"?>
665665
<key attr.name="packet_loss" attr.type="double" for="edge" id="edge_packet_loss" />
666666
<key attr.name="jitter" attr.type="double" for="edge" id="edge_jitter" />
667667
<key attr.name="latency" attr.type="double" for="edge" id="edge_latency" />
668-
<key attr.name="type" attr.type="string" for="node" id="node_type" />
669668
<key attr.name="bandwidth_up" attr.type="string" for="node" id="node_bandwidth_up" />
670669
<key attr.name="bandwidth_down" attr.type="string" for="node" id="node_bandwidth_down" />
671670
<key attr.name="country_code" attr.type="string" for="node" id="node_country_code" />
@@ -678,7 +677,6 @@ const ONE_GBIT_SWITCH_TOPOLOGY: &str = r#"<?xml version="1.0" encoding="utf-8"?>
678677
<data key="node_country_code">XX</data>
679678
<data key="node_bandwidth_down">1 Gbit</data>
680679
<data key="node_bandwidth_up">1 Gbit</data>
681-
<data key="node_type">net</data>
682680
</node>
683681
<edge source="poi-1" target="poi-1">
684682
<data key="edge_latency">1.0</data>

src/main/routing/topology.c

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -578,7 +578,8 @@ static gboolean _topology_checkGraphAttributes(Topology* top) {
578578
/* we use a string because there is an error in igraph boolean attribute code. */
579579
isSuccess = isSuccess && _topology_checkAttributeType(name, type, IGRAPH_ATTRIBUTE_STRING);
580580
} else {
581-
warning("graph attribute '%s' is unsupported and will be ignored", name);
581+
error("graph attribute '%s' is unsupported", name);
582+
isSuccess = FALSE;
582583
}
583584
}
584585

@@ -609,7 +610,8 @@ static gboolean _topology_checkGraphAttributes(Topology* top) {
609610
} else if(_topology_isValidVertexAttributeKey(name, VERTEX_ATTR_PACKETLOSS)) {
610611
isSuccess = isSuccess && _topology_checkAttributeType(name, type, IGRAPH_ATTRIBUTE_NUMERIC);
611612
} else {
612-
debug("vertex attribute '%s' is unsupported and will be ignored", name);
613+
error("vertex attribute '%s' is unsupported", name);
614+
isSuccess = FALSE;
613615
}
614616
}
615617

@@ -651,7 +653,8 @@ static gboolean _topology_checkGraphAttributes(Topology* top) {
651653
} else if(_topology_isValidEdgeAttributeKey(name, EDGE_ATTR_PACKETLOSS)) {
652654
isSuccess = isSuccess && _topology_checkAttributeType(name, type, IGRAPH_ATTRIBUTE_NUMERIC);
653655
} else {
654-
debug("edge attribute '%s' is unsupported and will be ignored", name);
656+
error("edge attribute '%s' is unsupported", name);
657+
isSuccess = FALSE;
655658
}
656659
}
657660

src/test/tor/minimal/tor-minimal.yaml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ topology:
66
<key attr.name="packet_loss" attr.type="double" for="edge" id="d9" />
77
<key attr.name="jitter" attr.type="double" for="edge" id="d8" />
88
<key attr.name="latency" attr.type="double" for="edge" id="d7" />
9-
<key attr.name="type" attr.type="string" for="node" id="d5" />
109
<key attr.name="bandwidth_up" attr.type="string" for="node" id="d4" />
1110
<key attr.name="bandwidth_down" attr.type="string" for="node" id="d3" />
1211
<key attr.name="country_code" attr.type="string" for="node" id="d2" />
@@ -19,7 +18,6 @@ topology:
1918
<data key="d2">US</data>
2019
<data key="d3">1 Gbit</data>
2120
<data key="d4">1 Gbit</data>
22-
<data key="d5">net</data>
2321
</node>
2422
<edge source="poi-1" target="poi-1">
2523
<data key="d7">50.0</data>

0 commit comments

Comments
 (0)