Service and Resource Aware Flow Management Scheme for an SDN-Based Smart Digital Campus Environment

Recently, campuses have been embracing smart digital technologies in order to boost the efficiency of education and creativity. Thus, massive heterogeneous flows are generated as a result of multitude simultaneous access from several heterogeneous devices. This is putting pressure on campuses to make better management of their constrained resources and to ensure the required Quality of Service (QoS). In this paper, we propose a multi-flow management scheme over a software-defined smart digital campus network, named Service and Resource Aware Flow Management (SRAFM). Our approach offers a unified fully-programmable architecture, a distributed end-host-based flow characterization plane, and a centralized software-defined optimization model to efficiently manage heterogeneous flows. Network functionalities, including QoS aware routing and resource allocation optimization, are formulated as a mixed-integer linear programming problem. Due to its NP-hard complexity, we propose an approximation algorithm in a decomposed fashion based on Lagrangian Dual Decomposition (LDD) and subgradient methods to find an optimal solution for flow management. We evaluate our scheme from different aspects, including the number of simultaneous heterogeneous flows, QoS provisioning, characterization impacts, and network scalability. Compared to the well-known benchmarks in QoS aware routing and optimization problem, SWAY and LARAC, our simulation results conducted with a large number of flows over a small-scale network show promising performance. The proposed scheme significantly improves the cost reduction by 51% as compared to LARAC, the end-to-end delay by 21% and 34%, the bandwidth availability by 27% and 36%, and the QoS violation by 11% and 29% as compared to SWAY and LARAC, respectively.

The smart digital campus, or modern campus, is equipped with thousands of heterogeneous Internet of Thing (IoT) and non-IoT devices that autonomously interact with each other to unleash or use a massive number of services appropriate for smart living and learning applications. With this unlimited development of heterogeneous devices and services, the campus network size keeps scaling up, while massive heterogeneous traffic flows continue to grow inexorably. Accordingly, network resources and bandwidth acquire an unprecedented demand. For example, in [3], Sivanathan et al. showed that when there is an activity from IoT devices and non-IoT devices, the campus network load peaks at around 17 Mbps. Meanwhile, the average load is 400 Kbps with IoT devices. Another study produced by attractive for addressing many network optimization problems, such as dynamic flow control, flexible network resource management, and QoS provisioning [16]- [19].
The above-mentioned issues and the adoption of software-defined based implementation motivate us to focus on the following questions: How can an efficient fully-programmable SDN-based solution for the smart digital campus be designed? How can the different requirements of each network traffic flow within a set of hundreds, even thousands of flows, be addressed? What are the network policies that proactively automate the management process of a set of heterogeneous flows while fulfilling the required QoS, improving available resources, and minimizing the routing cost?
To answer these questions, in this paper, we propose a multi-flow management scheme over a software-defined smart digital campus network named Service and Resource Aware Flow Management (SRAFM). The proposed scheme is different from existing works for two reasons. First, it offers a whole solution in terms of architecture, flow characterization, and QoS aware routing and resource optimization to manage the masses of heterogeneous flows generated from thousands of interconnected devices. Thus, over a unified fully-programmable architecture, SRAFM implements a distributed end-host-based flow characterization solution and a centralized software-defined optimization model for service and resource-aware routing problem. Second, in terms of QoS aware routing and resource optimization problem, SRAFM provides an optimal solution for an entire set of simultaneous flows in the network, which is more challenging than most prior schemes that often address this issue with a flowper-flow strategy. Furthermore, regarding the network in terms of flow-per-flow management cannot guarantee a global optimal allocation in the network; in some special cases, it may reduce the network performance by wrong routing decisions in advance.
The major contributions of this work can be summarized as follows: 1) Design of a smart campus programmable architecture for flexible flow characterization and management: We discuss the design challenges to deploy a unified fully-programmable architecture that controls wired and wireless software defined-based smart campus networks. Since flow characterization presents a fundamental network functionality to support QoS aware routing and optimization, we provide an overview of the different types of services and their QoS requirements on the basis of delay and bandwidth characterization. Accordingly, we identify the design challenges confronting the characterization of a large number of heterogeneous flows in a fully-programmable architecture, and we propose a distributed end-host-based plane for flow characterization based on a combined approach of device and service identifications. While designing this specific network-level in the architecture, we take into consideration the end-user's privacy, the processing time, the controller overhead, and the network bandwidth consumption. 2) QoS aware routing and optimization: SRAFM controls not only delay-sensitive flows, as do prior works, but all smart campus network flows to ensure service QoS requirements, to control bandwidth-hungry services, and to optimize network resource allocation. We propose a centralized optimization framework that manages flows based on an SDN proactive and reactive strategy and optimizes the system cost in terms of joining resource cost and path loss. Since the formulated multi-constraints optimization problem is NP-hard, the Log-det approximation function [20] is used to relax the problem. Then, by using the Lagrangian Dual Decomposition approach, we decompose the relaxed problem into per-flow sub-problems that can be solved simultaneously in a decomposed fashion. Accordingly, the SRAFM routing strategy finds an optimal solution not only for each flow independently but for the whole set of flows while performing coordination between their various requirements and the available resources. 3) Simulation results: We evaluate the proposed scheme through various simulation aspects, including the number of simultaneous heterogeneous flows, QoS requirements, characterization impacts, and network scalability. We compare our scheme to the SWAY [13] and Lagrange Relaxation based Aggregated Cost (LARAC) [21] algorithms, the well-known benchmarks in QoS aware routing and optimization problem. Our simulation results conducted with a large number of flows over a small-scale network show promising performance. Thus, SRAFM achieves 51% in terms of cost reduction as compared to LARAC. In addition, it improves the end-to-end delay by 21% and 34%, the bandwidth availability by 27% and 36%, and the QoS violation by 11% and 29%, as compared to SWAY and LARAC, respectively. To evaluate the system cost, we consider only LARAC, since SWAY adopts two different cost functions with different metrics in the same network. The remainder of this paper is organized as follows. Section II reviews related relevant works from the perspective of QoS aware routing and optimization over a software-defined-based environment. Section III discusses the software-defined smart campus network, the unified fully-programmable architecture, and the strategies to deploy flexible multi-flow characterization and optimization solutions. Sections IV and V respectively present the optimization problem and the proposed QoS-aware routing algorithms. The SRAFM operational scenario and the analysis of the results are presented in Sections VI and VII, respectively. Finally, we conclude and discuss future work in Section VIII.

II. RELATED WORK
In the context of smart digital campus networks, many research studies have been proposed to design and build smart digital campus networks with the appropriate technologies (e.g., traffic profiling, prediction of student attendance, etc.) to move towards digital education [1]- [3], [5]. However, none of these works target service and resource-aware traffic management and optimization. On the other hand, in the context of QoS provisioning and resource optimization over smart networks, the body of literature is vast [22], and it covers different SDN-based networks, such as smart home networks [23], [24] and industrial networks [25], [26]. However, the management of a large number of heterogeneous flows to improve service and network performance over smart digital campus networks is still an open issue with many challenges.
While few research works deal with QoS provisioning and resource optimization over SDN-based smart digital campus networks, industrial companies, such as Cisco [6], Campus Management Corp [7], Ruckus [9], and Huawei [27] have revolutionized how to design, build and manage smart campus networks to move towards digital education. Thus, the remainder of this section reviews some relevant related works from the perspective of QoS-aware routing and optimization problems in SDN-based environments, particularly the most common aspect, i.e., the delay-constrained leastcost (DCLC) routing problem.
In [28] and [29], Egilmez et al. propose an optimization model to ensure end-to-end multi-level QoS for video streaming service over SDN-based networks. They treat the base layer of video bit streams as a level-1 QoS flow, while packets of enhancement layers are treated as level-2 QoS or as best-effort flows. The rest of the network traffic is also managed as best-effort flows. They pose optimization QoS routing as a constrained shortest path problem in which delay and packet-loss are considered as QoS requirements, and they use the LARAC scheme [21] as a QoS routing algorithm. In [30], Yu et al. propose a QoS routing scheme for video streaming traffic over SDN networks. Similar to the previous works, [30] also treats the base layer and enhancement layer of video bit streams separately as two levels of QoS flows. However, the proposed routing solution is based mainly on the shortest path algorithm to route the base layer packets (level-1 QoS flows), if it meets the delay variation constraints. Otherwise, a QoS routing algorithm is invoked to select the required path. Despite the fact that [28], [29], and [30] cover several critical issues in terms of multi-level QoS, they do not consider different types of network services. In other words, their proposed schemes address problems for a specific service, i.e., video streaming, which might not fit the large number of heterogeneous services in smart networks.
In [31], Guck et al. provide a comprehensive survey of QoS routing algorithms in SDN-based networks. They implemented 26 DCLC algorithms and compared their VOLUME 8, 2020 run-time and cost efficiency within a four-dimensional (4D) evaluation framework. The four dimensions correspond to the type of topology, two forms of scalability of topology, and the tightness of the delay constraint. They conclude with the outperformance of two routing algorithms in the vast majority of the evaluations, namely, LARAC [21] and Search Space Reduction Delay-Cost-Constrained Routing (SSR+DCCR) [32]. All the evaluated algorithms, in [31], are devised to deal with single metric routing schemes (i.e., delay). However, a multi-metric QoS routing optimization should be considered to fulfill heterogeneous service requirements. In other words, the QoS provisioning problem should not take into consideration only time sensitive traffic in which the delay is a highly critical parameter, but also small IoT flows and mission-critical data that need different QoS requirements. Furthermore, bandwidth-hungry flows should be under the control of specific engineering policies, because transferring such type of traffic using only the best-effort mechanism, as in [28], [29] and [30], can create congestion and degrade the performance of critical applications when the same network resources are shared.
In [13], Saha et al. propose two different QoS routing strategies to address the issue of heterogeneous flows. One is devised to deal with delay-sensitive flows, and the other is devised to deal with loss-sensitive flows. Both of the deployed algorithms are based on the Yens K-shortest paths algorithm [33], which is included in the comparison performed by [31]. However, because of the different deployed strategies to deal with the two classes of traffic, the authors consider two different cost functions. Thus, they minimize the delay metric for delay-sensitive traffic and the loss metric for loss-sensitive traffic, subject to different constraints. By contrast, we consider that every flow is sensitive to loss, and we propose an optimization problem that minimizes the operational cost of the selected path in addition to the loss-rate, according to the delay and bandwidth sensitivity metrics.
Finally, it is worth mentioning that the literature encloses a multitude of approaches that address the QoS-aware routing problem over the SDN-based environment, using different mechanisms such as machine learning [34], node characterization [35], queue scheduling [25], multi-path selection [36], etc. However, to the best of our knowledge, all these proposed works are based on a per-flow approach, i.e., using the current state of the network, the optimal routing solution is selected independently for each flow, and not for all flows in the system. Though this flow-by-flow technique can reach a fast routing decision, it cannot provide a global optimal solution for the whole set; in some cases, it violates service requirements and network performance due to previous decisions.

III. A SMART DIGITAL CAMPUS NETWORK
In this work, we propose a multi-flow management scheme called Service and Resource Aware Flow Management (SRAFM) for the smart digital campus network.
This proposed scheme requires being deployed in a flexible programmable architecture. In addition, the large number of services leads us to design a specific network-level in the architecture to analyze the nature of heterogeneous flows before performing traffic routing and resource optimization.
Thus, in this section, we propose the software-defined smart campus architecture, a unified fully-programmable architecture, which manages the heterogeneous wired and wireless network components. Then, we discuss the characteristics of the network services in terms of delay and bandwidth requirements, and we discuss the distributed endhost-based plane for flow characterization.

A. SOFTWARE-DEFINED CAMPUS ARCHITECTURE
As depicted in Figure 1, the software-defined campus network is based on a fully-programmable paradigm in which all the network devices in each layer (i.e., access, aggregation, core, and wireless backhaul layers) are controlled and programmed by the centralized control plane [27]. This control plane can include one or multiple controllers to handle the increased management complexity of large-scale wired and wireless networks. Thus, it is possible to control and manage the wired network over the access, aggregation, and core layers with one SDN controller, or to slice network views in a way that each layer is managed via a different SDN controller. On the other hand, to manage the wireless backhaul layer, it is important to note that SDN has been designed for wired networks; but wireless networks have different requirements, and there is not yet a consensus or standard on how to program wireless forwarding elements [16]. The two main challenges of software-defined wireless implementation are the configuration of the wireless forwarding elements by the control plane, and the interaction between the access layer and the programmable wireless backhaul forwarding elements. For these purposes, significant research studies and industrial implementations have been proposed as an extension of the SDN paradigm to incorporate mobile-specific functionalities. For example, in [42], Huawei presents Huawei's agile campus network solution, a fully-programmable architecture that includes an access controller and programmable agile switches enabling unified wired and wireless traffic forwarding. In [43], Nunez et al. propose featuring the wireless backhaul forwarding elements and the typical SDN controller with wireless agent extensions that enable the management of packets and forwarding rules in a technology-agnostic manner. In [44], Seppanen et al. propose a network abstraction approach by hiding the wireless network from the SDN layer. Thus, instead of controlling the wireless forwarding elements directly with the SDN controller, the whole wireless network is seen as a single SDN switch, controlled like a standard SDN device.
In our work, as shown in Figure 1, for the wireless backhaul layer management, a controller, named Software-Defined Radio (SDR) controller, is proposed to manage the data connections between the radio access elements (e.g., wireless access points), the Wireless Backhaul Forwarding Elements  (WBFE, such as base stations), and the operators' SDN enabled devices in the network. All programmability functionalities in the wireless data plane (such as defining forwarding rules and radio resource management) are implemented using the SDR controller. Then, a controller orchestrator is required to ensure the unified interaction of all the heterogeneous network technologies and operators, via the coordination between the different controllers, and the establishment of compatible configurations between the wired and wireless networks.
However, as detailed in [16], where Macedo et al. survey SDN, SDR, and network function virtualization (NFV) technologies, achieving unified management of wired and wireless programmable networks is certainly a big challenge, and it is fundamental that these technologies complement each other to develop a highly flexible programmable network. Thus, in our work, we focus on service management and resource optimization for the software-defined campus network, while assuming that the unified fully-programmable campus architecture is established. In other words, the technical interaction between the different controllers performed by the controller orchestrator and the required features over the wireless forwarding elements to ensure a unified programmable management process are beyond the scope of our current research project. We refer interested readers to [45]- [48] for more details about the design challenges of a unified fully-programmable architecture.

B. HETEROGENEOUS FLOW CHARACTERIZATION 1) SMART DIGITAL CAMPUS NETWORK TRAFFIC
As shown in Figure 1, over the smart digital campus network, different services related to two main axes, digital learning VOLUME 8, 2020 TABLE 1. Taxonomy of smart digital campus network services generated from IoT and non-IoT devices [37]. and smart campus environment, are generated from IoT and non-IoT devices [6]. Table 1

presents a taxonomy and examples of such services.
On the one hand, smart digital learning and innovation services are generated from IoT and non-IoT devices to maximize the potential of learning and research. For example, courses and training are offered by top faculty and leaders from the same university or around the world, and they are accessible to students anywhere and at any time due to innovative learning facilities such as IoT-based classrooms, virtual classes, IoT sensors for note sharing, etc. [7], [38].
On the other hand, smart campus building and living related services are generated mainly from IoT devices to offer a safe, green, and smart living environment. This axis includes certain security services, which report urgent alarm events via messages, high-resolution images, and videos [8]. It also includes various intelligent applications, such as smart access, building automation systems, smart parking, and payment. Besides, it provides services, such as heating adaptation, light-adjustment, and water conservation, which aim to transform the traditional campus environment into a model of a green institution at low cost by reducing energy and carbon footprint [9].

2) SERVICES' QoS REQUIREMENTS CHARACTERIZATION
Since the number of services generated from IoT and non-IoT devices is unlimited and network resources are constrained, we define a set of traffic classes with their appropriate QoS requirements and priority levels in the network.
As shown in Table 1, we characterize services' QoS requirements on the basis of delay and bandwidth sensitivities. Thus, we separate network campus services into two main sets: delay and bandwidth sensitive flows. We refer to these two sets, respectively, as F ds flows and F bs flows. Consequently, the whole set of campus network flows F is represented as follows: The delay-sensitive class includes video-based services and IoT services. All these services are characterized, firstly, by time constraints that have to be deterministically guaranteed. We define, within the F ds set, three levels of prioritization. The first one (Highly critical / Real-time) includes ultra-high-definition video-based services related, for examples, to security video surveillance, on-line course learning, video conferencing, etc. As shown in Table 1, real-time and high bandwidth are both the main characteristics of these services to ensure an efficient end-to-end delivery without interruptions and packet loss [37]- [39]. All the flows of this level will be managed proactively by the SRAFM scheme since they are regular and frequent in the network. The second level (Critical / Near real-time) includes IoT services that are generated, for examples, by building automation systems, connected lighting, smart parking, etc. As shown in Table 1, these irregular and infrequent services are characterized by near real-time (e.g., tolerable delay of 30 s) and low-rate requirements (i.e., each IoT device exchanges a small amount of data per-flow) [40], [41]. These smart IoT services require a critical priority level in the network, since competing with traditional flows (e.g., bulk transfers) can significantly affect the performance of these low-rate IoT applications [13]. Finally, the third level (Non critical / Real-time) includes non-critical video-based services, which are generated, for instances, by students playing online games and/or watching videos supplied by providers such as Youtube and Netflix [24].
However, the flows of this level require a strict end-to-end delay; for example, an online game requires less than 250 ms to run smoothly [49].
The F bs set includes services that utilize large amounts of bandwidth and place enormous strain on the network. As shown in Table 1, it includes a significant number of applications, such as peer-to-peer file sharing, large downloads, and software updates, which are very bandwidth-hungry services but not sensitive to delay. This set of flows is also called bulk transfers. The non-controlled management of these bandwidth-hungry applications creates network congestion and leads to performance degradation of the delay-sensitive flows, i.e., the F ds set. Consequently, these services should be managed through the network with a lower priority compared to the delay-sensitive services. We also categorize this class into two different levels. The first level (Critical / Non real-time) includes mission-critical data such as electronic books management, courses and administration's cloud-based resources transfer and storage, etc. The second level (Non-critical / Non real-time) involves non critical data, such as students' video downloads for offline viewing.

3) DISTRIBUTED END-HOST-BASED FLOW CHARACTERIZATION PLANE
Characterizing network flows with the appropriate performance levels and QoS requirements, as shown in Table 1, should be performed before flow management, since this impacts greatly routing decisions and resource allocation optimization. In this section, we discuss the services' massive data stream processing, particularly the challenges of the joint design of multi-flow characterization and management over a fully-programmable architecture, and we propose the distributed end-host-based plane for flow characterization.
With the programmable paradigm, multi-flow processing could be performed within either a centralized approach or a distributed approach. According to the centralized approach, since there is a lack of intelligence in the forwarding plane, thousands of heterogeneous flows are sent by forwarding devices to the centralized controller to be analyzed using flow characterization programs. Then, as illustrated in Figure 2(a), they are mapped to specific engineering policies, which are computed using traffic engineering and management programs. The centralized controller installs these computed rules over the programmable forwarding devices to enable the transfer of the corresponding flows [13], [50]. Nonetheless, with the continuous expansion in the flow number, data rates, and the requirements for detailed analysis, this approach seems to have limited scalability, and it leads to long processing time and heavy overhead that affect the performance of the delay-sensitive flows [50]- [52].
To overcome these problems, the distributed processing approach is proposed through the deployment of multiple processing nodes, such as a cluster of controllers or fog nodes, where each node controls only a specific part of the network's resources and its corresponding heterogeneous flows [50], [53]. As shown in Figure 2(b), this approach provides data processing as close as possible to the enddevices, which enables reducing the processing time and the overhead as compared to the centralized approach. However, the administrator needs to encounter many issues related to the users' privacy, security, placement of the processing nodes, delay in computing, and energy consumption. Furthermore, being connected to heterogeneous devices, managing the distributed processing nodes, the connections between them, and the heterogeneous networks will be burden unless SDN, SDR, and NFV technologies are applied [16], [53].
In our work, while taking into consideration the above concerns, we separate the flow characterization process from the traffic engineering and resource management process. We propose to perform flow characterization over each end-host in the campus network, based on a combined approach of a device (e.g., ID student laptop) and service (e.g., online gaming) identification, before forwarding flow through the network. We designate this approach as ''distributed'' since the characterization engine is not centralized over the centralized control plane but distributed over the end-hosts. This approach is developed as well in [54], where a shim layer is introduced over each end-host to detect the specific type of flow in a software-defined inter-data center network. The Differentiated Services Code Point (DSCP) bits are used to mark packets with the specific type of flow [55]. Thus, each non-intelligent forwarding device detects easily and directly the kind of the flow and decides to send it either to the destination using the proactively installed rules or to the centralized controller for path computation.
One of the benefits of characterizing flows by end-hosts is to protect users' privacy. In fact, accessing user data over a processing node (e.g., the SDN controller) and analyzing the corresponding flows may cause discomfort for end-users. Besides, characterizing flows before managing them through non-intelligent programmable devices enables saving network bandwidth and reducing processing time, since network flows are already characterized by sources, and consequently not all flows require the reactive intervention of the controller. Finally, this approach enables reducing controller tasks and improving controller efficiency. Section VI presents more details about the functional description of this approach in the SRAFM scheme over the software-defined smart campus network.

IV. QoS-AWARE ROUTING PROBLEM AND SRAFM OPTIMIZATION MODEL
In this section, we first outline the adopted network representation and related notations. Then, we present the SRAFM optimization model proposed, in this work, for a software-defined smart campus network. Table 2 summarizes the notations used in this work. Let us assume that the network topology is represented by a connected graph G = (V , E), where V is the set VOLUME 8, 2020  of all SDN-enabled devices (nodes), and E is the set of links. With the following aspects, we formulate the SRAFM optimization model for the QoS aware routing and resource optimization problem.

1) THE OBJECTIVE FUNCTION
Assuming that every network service is sensitive to packet loss, we formulate the objective function to optimize the routing decision while considering both aspects: the operational cost and the packet-loss. Thus, we aim to minimize the global system cost experienced by a set of simultaneous flows F, as follows: ( In the remainder of this section, we elaborate on each of the settings used in this objective function. Hence, the path operational cost, S p , is calculated by the sum of all the costs of the links belonging to path p, as shown in (3).
The end-to-end loss rate probability, Q p , on path p is calculated by the product of the individual packet loss ratios per link of all links belonging to path p [56], [57], as shown in (4).
The δ(r f ,p ), defined in (5), presents an identity function to determine whether or not a flow f is routed through a path p.
We use the monetary parameters α and β ∈ [0, 1] to model a multi-objective function enabling adjustment of the relative importance of the operational cost and the packet loss, depending on network and traffic characteristics [29], [58]. Besides, we use the weight factor w f ∈ [0, 1] to adjust the priority level of the flows within the same set. Thus, paths with lower latency and higher bandwidth are assigned to high priority services, as detailed in Section III-B.
2) SERVICE END-TO-END DELAY CONSTRAINT Equation (6) defines the end-to-end delay constraint, where the delay of the selected path D p , as defined in (7), should be less than or equal to a specified end-to-end delay threshold, D max f , required by flow f . 3

) SERVICE RATE AND NETWORK CAPACITY CONSTRAINTS
Equation (8) defines the flow throughput constraint, where the rate of flow f on selected path p should be more than or equal to R min f , the minimum requirement of flow f .
Equation (9) defines the capacity constraint associated with each link e ∈ E, where the total rates of all the flows f ∈ F going through a specified link e should not exceed the link's residual capacity.
f ∈F p∈P e r f ,p ≤ C res (e), e ∈ E.

B. OPTIMIZATION MODEL
The objective of the SRAFM scheme is to select appropriate paths to accommodate a set of characterized network flows while minimizing the total system cost, ensuring the required QoS for each flow, and maximizing the overall network performance. Thus, path selection depends on the flows' QoS requirements and the constrained available network resources.
We formulate the optimization problem as follows: f ∈F p∈P e r f ,p ≤ C res (e), ∀e ∈ E, (10d) Equation (10a) presents the objective function to be minimized while routing F ds and F bs sets of flows. Equations (10b) and (10c) present the delay and bandwidth Algorithm 1 Approximation Algorithm for SRAFM 1: Initialization: t = 0, r 0 f ,p = 1 − γ ; 2: Repeat: f ,p is the solution of the previous iteration, and γ > 0 is a small positive constant; 5: Replace δ(r f ,p ) in (10) by δ t (r f ,p ) to relax the problem; 6: Call Algorithm 2 to find r t f ,p ; 7: Until: and R min f characterize the QoS requirements of flow f in terms of delay and rate, respectively. Equation (10d) presents the capacity constraint associated with each link e ∈ E. Finally, in (10e), a single path routing decision is assumed for each flow. This assumption leads the controller to configure a small number of forwarding rules and simplifies our system in terms of time complexity since we regard a solution for a set of flows at the same time.

V. APPROXIMATION AND DECOMPOSITION FRAMEWORK FOR SOLVING SRAFM
In this section, we propose a centralized scheme to be deployed over the SDN application plane. This SRAFM scheme solves the formulated optimization problem. First, since the SRAFM problem is NP-hard, we relax it into a tractable problem. Then, we design a per-flow decomposed algorithm to find the optimal routing solution in the network for a set of characterized flows.

A. THE APPROXIMATION ALGORITHM
One of the difficulties of the primal problem (10) resides in the integrality condition of the binary variable δ(r f ,p ), which is activated only if a path p is selected to route flow f , as shown in (5). Relaxing this problem requires the relaxation of this variable by letting δ(r f ,p ) be a real variable in the range of [0,1]. For the SRAFM scheme, we approximate iteratively the original binary value δ(r f ,p ) into a real value using (11), a Log-det relaxation for approximation function [20], where r t−1 f ,p is the rate result of the (t − 1) th iteration and γ > 0 is a small positive constant.
As shown in Algorithm 1 -line 5, in each iteration t, the integer-valued function δ(r f ,p ) is replaced by the new δ t (r f ,p ) into the NP-hard original optimization problem (10) to formulate the tractable optimization problem, which will calculate the new rate value r t f ,p by invoking Algorithm 2, in Algorithm 1 -line 6. The relaxed problem is a convex optimization problem, which can guarantee the convergence as proven in [59]. Thus, these processes are repeated until the optimal rate value r * f ,p is achieved upon convergence, i.e., r t−1 f ,p ≈ r t f ,p = r * f ,p , with an adequately small 1 . The understanding of the approximation of the modified problem to the original problem upon convergence is proved as follows: Equation (12) shows that, upon convergence, δ t (r * f ,p ) of the optimal solution approximately approaches the binary function δ(r * f ,p ) of the original problem. As a result, the objective function involving δ t (r * f ,p ) eventually approximates that of the original problem.

B. THE DUAL DECOMPOSITION ALGORITHM
The original problem (10) becomes more tractable by applying the Log-det relaxation function. However, its computational complexity is still very high, since this relaxed problem encompasses a wide range of heterogeneous flows with different service requirements. Therefore, to improve the performance of the resolution, we advocate the Lagrangian Dual Decomposition (LDD) approach to find the optimal solution in an efficient decomposed strategy. In other words, we decompose the relaxed optimization problem into F-optimization sub-problems, also called per-flow optimization sub-problems, that can be solved simultaneously with low complexity. Hence, first, the SRAFM scheme independently solves an optimization sub-problem for each flow within the whole set. Then, it coordinates between all of them and the allocated constrained resources.
For instance, to find the rate solution of the t th iteration of Algorithm 1, the Lagrangian function of the relaxed primal problem in (10) can be formulated as follows, after decoupling the constraint in (10d): where λ e ≥ 0 presents the Lagrange multiplier associated with the link capacity. Consequently, the Lagrangian dual function is given by: min L(r f ,p , λ e ), s.t. (10b), (10c), (10e).
The dual problem is formulated as follows: For a fixed dual variable λ e , (14) is decomposed into Foptimization sub-problems, which can be solved with the following objective function: where the constant terms, in (13), can be removed, and the term r t−1 f ,p is the rate solution of the previous iteration of Algorithm 1, which is calculated by Algorithm 2. Thus, the whole tractable optimization problem is decomposed into per-flow optimization sub-problems and presented as follows: As shown in (17), each sub-problem is intended to select the path that has the minimum cost, which depends on the operational cost, the packet loss, and the rates of all its shared links. The dual variable, which depends on the flow rate variable, presents a penalty to prevent the allocation of flows into congested paths. Hence, flows are spread out into multiple different paths to obtain lower cost while ensuring the delay and bandwidth requirements using constraints (17b) -(17e), which are the remaining constraints of problem (10).
Finally, to solve the dual problem (15), the subgradient projection method is deployed [60]. Thus, the updating rule for the dual variable is formulated as follows: The λ (l+1) e reports the evolution of the rate values at each link e ∈ E, where κ is a non-negative step-size used to adjust the convergence of the dual decomposition algorithm [63]. The steps of Algorithm 2 can be summarized as follows. Given the value of δ t (r f ,p ) from Algorithm 1 and the set F of network flows, at each iteration, Algorithm 2 solves independently the per-flow optimization problems to find an optimal path p for each flow f ∈ F (lines 3 -5). Then, using the computed value r f ,p , Algorithm 2 (line 6) updates the Lagrangian multiplier λ e for each link e ∈ E using the subgradient method in (18). The algorithm goes in a loop until the change of dual values approximates the stop threshold (line 8). Accordingly, the rate result r f ,p is returned to Algorithm 1 (lines 6 -7) as the solution for its t th iteration (i.e., r t f ,p ) to check the convergence to the optimal-rate solution r * f ,p .

VI. SRAFM FUNCTIONAL DESCRIPTION
In this section, we discuss the different components included in the whole SRAFM scheme. Figure 3 presents an overview of the functional description of SRAFM.

A. DISTRIBUTED END-HOST-BASED FLOW CHARACTERIZATION PLANE
When end-users (e.g., students, professors, etc.) connect to the network using their user ID, traffic flows are actively characterized in order to be signaled for the non-intelligent forwarding devices. Flows are characterized on the basis of a combined approach of device-level (e.g., ID professors' devices, ID online-courses' devices, ID students' devices, etc.) and service-level (e.g., videoconferencing, skyping, online gaming, etc.). Then, to ensure an efficient and easy detection of each flow type by the SDN-forwarding device, the DSCP field (as one of the marking techniques) is used to mark the corresponding packets of each flow with the required priority level. Accordingly, the programmable forwarding element detects the type of each flow smoothly and forwards it either to the controller or to the destination using the corresponding engineering policies (actions), as shown in Figure 3.
As explained in Section III, this distributed end-host-based flow characterization plane enables protecting the privacy of end-users, reducing the processing time required for heterogeneous flow analysis, and reducing controller tasks.

B. SOFTWARE DEFINED-BASED PROACTIVE AND REACTIVE APPROACH FOR FLOW MANAGEMENT
In our work, the proactive and reactive SDN operational modes are deployed to manage heterogeneous network flows. It is worth mentioning that the existing controllers (e.g., Floodlight, OpenDaylight, NOX, etc.) are by default configured to use only the reactive mode. Meanwhile, the SDN-forwarding devices (e.g., OpenFlow Logical Switch) are by default featured to support both of the SDN modes [64].
With SRAFM, we propose a new controller design that supports proactive and reactive strategies, simultaneously, to manage the regular and irregular network flows, respectively. On the one hand, as explained in Section III-B, the regular and frequent flows of the F ds set (e.g., courses, video-conferences, and video-surveillance) could be managed within a proactive strategy since the controller is proactively aware of the state of the network and the required resources to ensure the best QoS for these highly critical flows. Hence, their rules are configured in advance in the network, so when they come to the non-intelligent forwarding devices, they are easily identified because of DSCP bits and directly transferred to the destination using a matching between the DSCP bits and the corresponding actions in the flow table, as shown in Figure 3. This SDN operational mode does not require invoking the controller to manage these demands. Consequently, it avoids the time and the amount of overhead needed during the negotiation between the SDN-forwarding devices and the controller to compute paths and configure the network. It also reduces latency and bandwidth consumption of frequent demands, which affect the control plane scalability significantly. On the other hand, the irregular and infrequent IoT flows, the non-critical flows of the F ds set, and the F bs flows are managed in the network using the SDN reactive approach. In other words, switching devices need to request the controller, when the first packet of each flow arrives, in order to compute the corresponding routing policy based on the current state of the network, the number of demands (i.e., flows), and the flows' QoS requirements.
To the best of our knowledge, none of the existing works, in the literature, considered both reactive and proactive SDN modes for heterogeneous flow management and resource optimization.

C. SOFTWARE-DEFINED CONTROLLER MODULES
The flow engineering policy (action) computation process is performed by mainly four SRAFM modules implemented on the SDN application plane. The first module is the topology manager and statistics collector module. It enables maintaining a global view of the network, which is an input to the path computation modules. It continuously monitors and stores information about all the links and devices currently up in the network. The efficiency of path calculation and resource allocation in the network relies on the accuracy of the network data collected by this function. Hence, many technologies and parameters need to be deployed and configured by the administrator in this functionality to discover and update the entire network state with an efficient strategy, such as the REST-API [65], the Link Layer Discovery Protocol (LLDP) [66], the interval at which network statistics are collected, etc.
The second module is the flow QoS requirement characterization module. On the basis of the DSCP bits, this module analyzes the specific flows' QoS requirements and priority levels, as explained in Section III. This analysis is also employed as an input for the per-flow path computation module to find the optimal solution and to map the set of flows to the appropriate network engineering policies. Accordingly, the per-flow path computation algorithm, which is the third main module in the controller, calculates the optimal solution for the set of characterized flows, based on the QoS requirements, the network topology status, and the Lagrange multipliers, as shown in Figure 3, and detailed in Sections IV and V. Finally, when the algorithm converges to the optimal solution, the SDN controller installs the action rules in the forwarding devices over the selected paths using the flow pusher module (the fourth module).

VII. PERFORMANCE EVALUATION
In this section, we evaluate our SRAFM scheme, first, in terms of running time, system cost, end-to-end delay, average rate allocation, and resource availability while comparing our proposed mechanisms to the state-of-the-art methods. Then, we discuss the percentages of QoS violation and flow rejection. In each of these experiments, we emphasize the importance of performing flow characterization over the distributed end-host-based plane.

A. SIMULATION SETTINGS AND BENCHMARKS 1) HARDWARE AND SIMULATION SETTINGS
All the experiments were carried out on a PC with an Intel Core i7 CPU @ 3.4 GHz with 16 GB memory. The simulations are performed using the modern programming environment, Julia software [67]- [71], through the mathematical language called Julia for Mathematical Programming (JuMP) [72] and the optimization solver called IPOPT [73]. According to the network topology, we consider Abilene from the SNDlib library, which consists of 12 nodes and 15 links [74]. Then, to evaluate the applicability of our proposed scheme over a large-scale network, we adopt AttMpls topology from the Internet Topology Zoo, which consists of 25 nodes and 57 links [13]. To evaluate the performance of our algorithms under different network conditions, initially, all links' capacities are set to 10 GB and maximum 30% of the links' capacities are randomly consumed. Initially, the delays of links have also been randomly set from 5 to 10 ms and we assume that this value includes the processing, transmission, and queuing delays. We set the operational cost metric randomly according to the load of each link [75], similarly for the delay and the packet-loss metrics [28], during flow allocation.

2) BENCHMARK SCHEMES
To evaluate our work, we use LARAC [21] and SWAY [13] algorithms as baselines. The LARAC algorithm is a single metric QoS routing scheme, i.e., a delay-constrained least-cost algorithm. It uses the Lagrange relaxation method to iteratively calculate the best QoS path on the basis of an aggregated concept of cost, which includes the operational cost and the delay [21]. The SWAY scheme is a multi-metric QoS routing approach that considers two different strategies to manage loss and delay-sensitive flows. Both of the SWAY algorithms are based on the Yens K-shortest paths algorithm [33]. Thus, SWAY minimizes the delay metric as a cost function for the delay-sensitive traffic and the loss metric as a second cost function for the loss-sensitive traffic, according to different constraints. In fact, we cannot implement exactly the same algorithms as SWAY since the types of traffic are different. Hence, we adopt only the same strategy of using two different algorithms for delay and bandwidth sensitive flows. Then, according to the type of flow (either ds or bs), SWAY alternates between the two algorithms.

3) HETEROGENEOUS FLOWS GENERATION
We randomly generate different smart campus services through the network with different QoS requirements, as detailed in Section III and shown in Tables 1 and 3. We generate 30% of the whole set of heterogeneous flows as IoT services, 50% as delay-sensitive, and 20% as bandwidth-hungry applications. As shown in Table 3, the rate requirements of the generated flows are set in the range of 150 Kbps to 100 Mbps. In addition, to evaluate the endto-end delay, the thresholds of the heterogeneous F ds services are set according to the type of traffic, either interactive applications in the range of 150 to 400 ms or IoT services, for which we use two different services with delay constraints of 2.6 s and 0.9 s, as shown in Table 3. It is noteworthy to mention that the values adopted in our simulation in terms of rate and delay present examples of characteristics for these services. For instance, an online game service could run smoothly with a delay less than 250 ms, as mentioned in Table 3, while an excellent online game (which is not our objective) requires less than 50 ms; also, the more players in an online game, the more data are exchanged between players [39]- [41], [49].  Table 4 evaluates the average running time by the number of flows over each topology for each routing strategy. We observe that SRAFM takes more time to select the optimal solution compared to the benchmark algorithms. This difference in terms of required time to achieve the optimal solution is due to the complexity of our algorithm compared to state-of-the-art ones. SRAFM performs coordination between the service quality requirements of the whole set of flows and the available network resources to select the best solution, while LARAC and SWAY select a local best path for each flow until the whole set of flows is achieved. Though these flow-per-flow routing strategies can obtain a fast solution to make a decision for all flows, they cannot reach an optimal routing decision for the whole set, because VOLUME 8, 2020 of the great number of rejected flows, as shown in Table 4 from the set of 1500 flows with the Abilene topology and the set of 1000 flows with the AttMpls topology.

1) SYSTEM RUNNING TIME EVALUATION
It is also worth mentioning that solving SRAFM with network topologies as Abilene and AttMpls is not difficult and provides a straightforward solution for a set of simultaneous flows. However, in a real network, the number of paths is extremely large, which makes this problem more complicated. Therefore, the use of parallel computation in multi-core systems and the deployment of the cluster-based distributed controller technology are advised to alleviate this challenge, especially over large-scale networks.

2) SYSTEM COST EVALUATION
In this section, we evaluate the average of the system cost according to the selected solutions. Since the SWAY algorithm takes into account two different cost functions (i.e., it minimizes the delay metric for delay-sensitive flows and the bandwidth utilization metric for bandwidth sensitive flows), we consider only the LARAC algorithm to evaluate the system cost of the SRAFM scheme. Figure 4 depicts the change in the average cost after the allocation of the whole set of flows.
As shown in Figure 4(a) and Figure 4(b), SRAFM shows its outperformance compared to the LARAC algorithm in terms of cost as a result of its distributed rate allocation approach. With the LARAC algorithm, path selection does not depend on the allocation of flow rates, and the cost function increases in accordance with the path operational cost and the delay that are updated after flow allocation has been performed [21]. SRAFM achieves 51% reduction in system cost as compared to LARAC. The system cost with LARAC does not increase compared to SRAFM from 1500 characterized flows and 1000 non-characterized flows, as shown in Figure 4(a) and Figure 4(b), respectively. This is indirectly dependent on the number of QoS violated flows, i.e., reaching the limitation level. In fact, at the limitation level, LARAC rejects all new flows as a result of QoS violation, so its system cost does not increase compared to the SRAFM scheme, which still accepts flows   and consequently its system cost continues to increase. For example, in Figure 4(b) with 2000 non-characterized flows, the system cost of SRAFM is greater than the cost of LARAC because of the flow acceptance by SRAFM, but its rejection by LARAC.
As shown in Figure 4(b), both of the algorithms (i.e., SRAFM and LARAC) reveal the necessity to perform traffic characterization before traffic management, which reduces the system's cost by an average of 47% compared to traffic management without the characterization process. Figures 5, 6, and 7 evaluate, respectively, the average of the end-to-end delay, the average of the flow rate allocation, and the lowest bandwidth availability after performing flow allocations over the Abilene topology. From these figures, it is evident that SRAFM obtains the highest network performance as compared to SWAY and LARAC, especially with the increasing number of flows.

3) QoS REQUIREMENT PROVISIONING AND FLOW VIOLATION
SRAFM reduces, on average, the end-to-end delay by 21% and 34% as compared to SWAY and LARAC, respectively. Traffic characterization improves the system end-to-end delay with more than 56%, as compared to the management of the heterogeneous flows without characterization, particularly with a huge set of flows.
Figures 6 and 7 evaluate the average rate allocation and the lowest available bandwidth after performing flows rate allocations in the network. SRAFM reduces on average the rate allocation as a result of the distributed approach by 32% and 48% as compared to SWAY and LARAC, respectively. SRAFM achieves an average improvement of 27% and 36% in terms of available bandwidth as compared to SWAY and LARAC, respectively. Furthermore, with the benchmarks schemes, the lowest available bandwidth achieves 0% with huge sets of flows (i.e., 1500 and 2000 flows), which is not the case with SRAFM. Finally, as shown in Figures 7(a) and 7(b), controlling bandwidth-hungry flows using flow characterization provides a 22% improvement in bandwidth availability and enables postponing network congestion in terms of flow numbers.
This improvement in terms of delay and bandwidth availability depends on the routing strategy of each algorithm. With SRAFM, the rate allocation on each path for each flow depends on the rate requirements of all the flows. In other words, the SRAFM algorithm allocates network flows distributively to network paths that have low bandwidth utilization due to the dual variable, which presents a penalty in the cost minimization function. Furthermore, with SRAFM, the selected solution is related to two constrained metrics, the delay and bandwidth thresholds. On the other hand, with the current state of the network, the benchmark algorithms perform flow-per-flow allocation for the whole set of flows. Thus, at a limitation level, the new services are rejected because of the paths' insufficient bandwidth (with the SWAY algorithm) and high latency (with both the SWAY and LARAC algorithms). Figure 8 evaluates the end-to-end delay, the average of rate allocation, and the lowest bandwidth availability, respectively, after the allocation of characterized flows over the AttMpls topology. From Figures 8(a), 8(b), and 8(c), it is evident that SRAFM obtains the highest network performance compared to SWAY and LARAC, and also compared to the small-scale Abilene topology. SRAFM achieves 47% and 56% reduction in end-to-end delay compared to SWAY and LARAC, respectively. Our algorithm achieves 14% reduction in end-to-end delay with the AttMpls topology compared to the Abilene network, with the huge sets of flows. In terms of rate allocation, with AttMpls, SRAFM reduces the average rate allocation by 62% and 74% compared to SWAY and LARAC, respectively, and by 49% compared to the Abilene network. With AttMpls, SRAFM also improves the lowest available bandwidth by 28% compared to the Abilene network. This improvement in terms of network performance with a large-scale network is related to the distributed rate allocation approach over the whole topology deployed by SRAFM and so for path delay, which is related not only to the number of links but also to the number of flows processed throughout the path. On the other hand, with local-based path selection strategies like SWAY and LARAC, the average rate allocation remains similar compared to the Abilene network, and the end-to-end delay increases because of the large-scale setting.
This SRAFM's distributed rate allocation approach has an improvement not only on the end-to-end delay and the rate allocation but also on the violated flows. Figure 9 and Table 5 show the outperformance of our proposed scheme in terms of flow violation as compared to the benchmark schemes in the Abilene and AttMpls networks, particularly with a massive number of flows.
As shown in Figure 9(a), with the Abilene topology, SWAY and LARAC achieve the limitation level from 1500 flows; but with the AttMpls topology, the limitation level is achieved     from 1000 characterized flows. With 2000 characterized flows in the Abilene topology, 11% and 29% of the whole set are rejected by SWAY and LARAC, respectively. In the AttMpls topology, likewise, 17% and 36% of the whole set are rejected by SWAY and LARAC, respectively. This increase in violated flows in the AttMpls topology compared to Abilene with SWAY and LARAC is due to the local rate allocation strategy and the increase in terms of endto-end delay. Meanwhile, the distributed rate allocation approach adopted by SRAFM enables an extenuated use of the topology resources, which leads to outperformance in terms of flow violation, with 0%. Figure 9(b) proves that traffic characterization diminishes significantly the percentage of rejected flows. Without flow characterization, SRAFM achieves the limitation level with a set of 1500 flows over the Abilene topology, and with a set of 2000 flows over the AttMpls topology. SRAFM reduces the percentage of QoS flow violations with 2000 flows by 30% and 58% in the Abilene network compared to SWAY and LARAC, respectively. In AttMpls, SRAFM reduces the percentage of QoS flow violations with 2000 flows by 41% and 71% compared to SWAY and LARAC, respectively.

VIII. CONCLUSION AND FUTURE DIRECTIONS
In this paper, we proposed a multi-flow management scheme for a software-defined smart digital campus network, taking into account the available network resources, the heterogeneous flow types, and their different QoS requirements. We presented a unified fully-programmable architecture, a distributed end-host-based flow characterization plane, a controller design with a proactive and reactive flow management strategy, and a centralized software-defined optimization model to manage the massive heterogeneous flows generated from thousands of interconnected devices.
We considered heterogeneous flows as either delaysensitive or bandwidth-hungry services, but all as losssensitive. We introduced an approximation algorithm to relax the NP-hard proposed optimization problem. Furthermore, a per-flow decomposed optimization algorithm was deployed using LDD and sub-gradient methods to calculate the optimal routing paths for the whole set of flows on the basis of a distributed rate allocation design. The simulation results showed the outperformance of our proposed scheme in terms of reduction in system cost, end-to-end delay, average rate allocation, and rejected flow percentages.
The proposed SRAFM solution for a smart campus environment could be implemented in a large variety of smart networks, such as hospitals, small and medium-sized enterprises (SMEs), governmental office buildings, etc. It is also possible to implement the SRAFM optimization model over a large IoT environment. However, in such an environment, the limited number of flow rules to be configured on an SDN-forwarding device should be taken into account. In fact, without the rule-constraint, even when the remaining available bandwidth of a specific link is sufficient to accommodate new flow rates, the maximum number of flow rules to be configured on an SDN-forwarding device remains a constraint. Thus, this creates a conflict of device forwarding rules overflow, which produces flow rejection, as shown in Figure 10.
Our future work will focus on the efficiency and scalability of the control plane, on the deployment of the cluster-based distributed controller technology, and on the deployment of the distributed flow characterization solution, since all these issues have significant impacts on network performance with massive data streams.
YOSRA NJAH received the B.Sc. and M.Sc. degrees in telecommunications from the National Engineering School of Tunis (ENIT), Tunisia, in 2012 and 2013, respectively. She is currently pursuing the Ph.D. degree with the Synchromedia Laboratory, École de Technologie Supérieure (ÉTS), University of Quebec, Montreal, Canada. She performed her engineering and master of research projects in HEIA-FR, the School of Engineering and Architecture of Fribourg, Switzerland, where she has worked on the development of an observatory based on honeypot and machine learning techniques for malicious behavior and attacks threats in the DarkNet. Her current research interests include programmable networks, optimization, and data analytics for Internetof-Things and inter-data center networks.