Remove OvsdbConfigurationService
[ovsdb.git] / openstack / net-virt / src / main / java / org / opendaylight / ovsdb / openstack / netvirt / api / ConfigurationService.java
1 /*
2  * Copyright (C) 2014 Red Hat, Inc.
3  *
4  * This program and the accompanying materials are made available under the
5  * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6  * and is available at http://www.eclipse.org/legal/epl-v10.html
7  *
8  *  Authors : Dave Tucker
9  */
10
11 package org.opendaylight.ovsdb.openstack.netvirt.api;
12
13 import java.net.UnknownHostException;
14 import org.opendaylight.yang.gen.v1.urn.tbd.params.xml.ns.yang.network.topology.rev131021.network.topology.topology.Node;
15
16 import org.apache.commons.lang3.tuple.Pair;
17
18 import java.net.InetAddress;
19 import java.util.Map;
20
21 /**
22  * The ConfigurationService handles the configuration of the OpenStack Neutron Integration
23  * It exposes a set of Configuration variables and helper functions for obtaining node-specific
24  * configuration from the Open_vSwitch table of an OVS instance.
25  */
26 public interface ConfigurationService {
27
28     /**
29      * Returns the name configured name of the Integration Bridge
30      */
31     public String getIntegrationBridgeName();
32
33     /**
34      * Configures the name of the Integration Bridge
35      */
36     public void setIntegrationBridgeName(String integrationBridgeName);
37
38     /**
39      * Returns the name configured name of the Network Bridge
40      */
41     public String getNetworkBridgeName();
42
43     /**
44      * Configures the name of the Network Bridge
45      */
46     public void setNetworkBridgeName(String networkBridgeName);
47
48     /**
49      * Returns the name configured name of the ExternalBridge
50      */
51     public String getExternalBridgeName();
52
53     /**
54      * Configures the name of the External Bridge
55      */
56     public void setExternalBridgeName(String externalBridgeName);
57
58     /**
59      * Returns the key used to access the Tunnel Endpoint configuration from Open vSwitch
60      */
61     public String getTunnelEndpointKey();
62
63     /**
64      * Sets the key used to access the Tunnel Endpoint configuration from Open vSwitch
65      */
66     public void setTunnelEndpointKey(String tunnelEndpointKey);
67
68     /**
69      * Returns a Map of patch port names where the key is a tuple of source bridge and destination bridge
70      */
71     public Map<Pair<String, String>, String> getPatchPortNames();
72
73     /**
74      * Sets the Map of source/destination bridges to patch port name
75      */
76     public void setPatchPortNames(Map<Pair<String, String>, String> patchPortNames);
77
78     /**
79      * Get the name of a patch port
80      * @param portTuple a {@link org.apache.commons.lang3.tuple.Pair} where L
81      *                  is the source bridge and R the destination bridge
82      * @return the name of the patch port
83      */
84     public String getPatchPortName(Pair portTuple);
85
86     /**
87      * Returns the key used to access the Tunnel Endpoint configuration from Open vSwitch
88      */
89     public String getProviderMappingsKey();
90
91     /**
92      * Sets the key used to access the Tunnel Endpoint configuration from Open vSwitch
93      */
94     public void setProviderMappingsKey(String providerMappingsKey);
95
96     /**
97      * Gets the default provider mapping
98      */
99     public String getDefaultProviderMapping();
100
101     /**
102      * Sets the default provider mapping
103      */
104     public void setDefaultProviderMapping(String providerMapping);
105
106     /**
107      * Gets the tunnel endpoint address for a given Node
108      * @param node a {@link org.opendaylight.controller.sal.core.Node}
109      * @return the tunnel endpoint
110      * @see java.net.InetAddress
111      */
112     public InetAddress getTunnelEndPoint(Node node);
113
114     /**
115      * Returns the OpenFlow version to be used by the {@link NetworkingProvider}
116      * Default is OpenFlow 1.0. OVS versions greater than 1.10.0 will use OpenFlow 1.3
117      * @param node the node to query
118      * @return the OpenFlow version to use
119      */
120     public String getOpenflowVersion(Node node);
121
122     /**
123      * Returns the MacAddress to be used for the default gateway by the {@link L3ForwardingProvider}
124      * There is no default.
125      * @param node the node to query
126      * @return the MacAddress to use for the default gateway; or null if none is configured.
127      */
128     public String getDefaultGatewayMacAddress(Node node);
129 }