summaryrefslogtreecommitdiff
path: root/tests/ovn.at
diff options
context:
space:
mode:
authorLorenzo Bianconi <lorenzo.bianconi@redhat.com>2019-07-11 17:48:44 +0200
committerBen Pfaff <blp@ovn.org>2019-07-12 13:34:41 -0700
commit5e0d2837c64a12e573b80fff00cb91cdd86db9c2 (patch)
treea68f5b27b909fe82a6c28f7a87480d9dbf85ea01 /tests/ovn.at
parentf732a1ab9c574c1c17858a84cf7d25f294dfb151 (diff)
downloadopenvswitch-5e0d2837c64a12e573b80fff00cb91cdd86db9c2.tar.gz
OVN: introduce trigger_event() action
Add trigger_event() ovn action in order to allow ovs-vswitchd to report CMS related events. This commit introduces a new event, empty_lb_backends. This event is raised if a received packet is destined for a load balancer VIP that has no configured backend destinations. For this event, the event info includes the load balancer VIP, the load balancer UUID, and the transport protocol. The use case for this particular event is for the CMS to supply backend resources to handle this traffic. For example, in Openshift, this event can be used to spin up new containers to handle the incoming traffic. Signed-off-by: Mark Michelson <mmichels@redhat.com> Co-authored-by: Mark Michelson <mmichels@redhat.com> Signed-off-by: Lorenzo Bianconi <lorenzo.bianconi@redhat.com> Signed-off-by: Ben Pfaff <blp@ovn.org>
Diffstat (limited to 'tests/ovn.at')
-rw-r--r--tests/ovn.at10
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/ovn.at b/tests/ovn.at
index 95980f2f1..ae91ce366 100644
--- a/tests/ovn.at
+++ b/tests/ovn.at
@@ -1333,6 +1333,16 @@ tcp_reset { };
encodes as controller(userdata=00.00.00.0b.00.00.00.00)
has prereqs tcp
+# trigger_event
+trigger_event(event = "empty_lb_backends", vip = "10.0.0.1:80", protocol = "tcp", load_balancer = "12345678-abcd-9876-fedc-11119f8e7d6c");
+ encodes as controller(userdata=00.00.00.0f.00.00.00.00.00.00.00.00.00.01.00.0b.31.30.2e.30.2e.30.2e.31.3a.38.30.00.02.00.03.74.63.70.00.03.00.24.31.32.33.34.35.36.37.38.2d.61.62.63.64.2d.39.38.37.36.2d.66.65.64.63.2d.31.31.31.31.39.66.38.65.37.64.36.63)
+
+# Testing invalid vip results in extra error messages from socket-util.c
+trigger_event(event = "empty_lb_backends", vip = "10.0.0.1:80", protocol = "sctp", load_balancer = "12345678-abcd-9876-fedc-11119f8e7d6c");
+ Load balancer protocol 'sctp' is not 'tcp' or 'udp'
+trigger_event(event = "empty_lb_backends", vip = "10.0.0.1:80", protocol = "tcp", load_balancer = "bacon");
+ Load balancer 'bacon' is not a UUID
+
# Contradictionary prerequisites (allowed but not useful):
ip4.src = ip6.src[0..31];
encodes as move:NXM_NX_IPV6_SRC[0..31]->NXM_OF_IP_SRC[]