blob: 599a615ec6ed65301fcc638d64320cbdfb38d922 [file] [log] [blame]
Jian Li43244382021-01-09 00:19:02 +09001/*
2 * Copyright 2021-present Open Networking Foundation
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16package org.onosproject.kubevirtnetworking.api;
17
18import org.onlab.packet.MacAddress;
19
20/**
21 * Provides constants used in KubevirtNetworking.
22 */
23public final class Constants {
24
25 private Constants() {
26 }
27
28 public static final String KUBEVIRT_NETWORKING_APP_ID =
29 "org.onosproject.kubevirtnetworking";
30 public static final String DEFAULT_GATEWAY_MAC_STR = "fe:00:00:00:00:02";
31 public static final MacAddress DEFAULT_GATEWAY_MAC =
32 MacAddress.valueOf(DEFAULT_GATEWAY_MAC_STR);
33
34 // flow table index
35 public static final int STAT_INBOUND_TABLE = 0;
36 public static final int VTAP_INBOUND_TABLE = 1;
37 public static final int STAT_FLAT_OUTBOUND_TABLE = 10;
38 public static final int DHCP_TABLE = 5;
39 public static final int VTAG_TABLE = 30;
40 public static final int PRE_FLAT_TABLE = 31;
41 public static final int FLAT_TABLE = 32;
42 public static final int ARP_TABLE = 35;
43 public static final int ACL_EGRESS_TABLE = 40;
44 public static final int ACL_INGRESS_TABLE = 44;
45 public static final int CT_TABLE = 45;
46 public static final int ACL_RECIRC_TABLE = 43;
47 public static final int JUMP_TABLE = 50;
48 public static final int ROUTING_TABLE = 60;
49 public static final int STAT_OUTBOUND_TABLE = 70;
50 public static final int VTAP_OUTBOUND_TABLE = 71;
51 public static final int FORWARDING_TABLE = 80;
52 public static final int ERROR_TABLE = 100;
53
Jian Li556709c2021-02-03 17:54:28 +090054 // tenant integration bridge flow table index
55 public static final int TENANT_INBOUND_TABLE = 0;
56 public static final int TENANT_DHCP_TABLE = 5;
57 public static final int TENANT_FORWARDING_TABLE = 80;
58
Jian Li43244382021-01-09 00:19:02 +090059 // flow rule priority
60 public static final int PRIORITY_SWITCHING_RULE = 30000;
Jian Lica20b712021-01-18 00:19:31 +090061 public static final int PRIORITY_DHCP_RULE = 42000;
Jian Lif97a07e2021-01-13 18:05:00 +090062
63 // CLI item length
64 public static final int CLI_ID_LENGTH = 30;
65 public static final int CLI_NAME_LENGTH = 30;
66 public static final int CLI_IP_ADDRESSES_LENGTH = 50;
67 public static final int CLI_IP_ADDRESS_LENGTH = 25;
Jian Li3ba5c582021-01-14 11:30:36 +090068 public static final int CLI_IP_ADDRESS_AVAILABILITY = 15;
Jian Lif97a07e2021-01-13 18:05:00 +090069 public static final int CLI_MAC_ADDRESS_LENGTH = 25;
70 public static final int CLI_PORTS_LENGTH = 20;
71 public static final int CLI_NAMESPACE_LENGTH = 15;
Jian Liac31f652021-01-17 02:18:30 +090072 public static final int CLI_STATUS_LENGTH = 15;
Jian Lif97a07e2021-01-13 18:05:00 +090073 public static final int CLI_PHASE_LENGTH = 15;
74 public static final int CLI_TYPE_LENGTH = 15;
75 public static final int CLI_TYPES_LENGTH = 30;
76 public static final int CLI_SEG_ID_LENGTH = 10;
77 public static final int CLI_LABELS_LENGTH = 30;
78 public static final int CLI_CONTAINERS_LENGTH = 30;
79 public static final int CLI_MARGIN_LENGTH = 2;
Jian Li43244382021-01-09 00:19:02 +090080}