# An Aspect-Oriented Approach to Time-Constrained Strategies in Smart City IoT Applications
## 2 Existing Approaches
### Fog Computing  
One method which seeks to achieve the same offloading benefits without the associated complexity of mobile physical platforms is fog computing [21; 22; 23; 24]. The exact definition of fog computing is yet to be formally set, but, generally, it can be described as \"a paradigm that extends the cloud and integrates edge and IoT, while providing a new, horizontally scalable highly virtualized layer that distributes computing, control and networking capabilities\" [22]. In [24], the authors describe the relationship between fog and cloud computing as a \"computational paradigm that aims to bring the benefits of the cloud closer to end devices...highly integrated with the cloud, but with the processing also being carried out at the edge of the network, enabling the execution of applications that [previously] were not possible due to the high latency that existed between the devices and the cloud\".  
An example of a smart city architecture using fog nodes as an intermediary between the smart city cloud and deployed IoT devices is shown in Figure 2. This architecture creates a middleware tier called the 'fog' between the high-cost, high-capability cloud, and the constrained edge device. Thus, some of the real-time decision-making logic may be carried out in the fog node, close to the edge devices, while complex, data-intensive applications can run in the cloud with an acceptable level of latency.  
The essential characteristics of fog computing include the contextual location awareness, low latency, geographical distribution, heterogeneity, interoperability and federation, real-time interactions, scalability, and agility of federated, fog-node clusters [25]. Many smart cities applications of IoT technology aim for a close temporal connection between the data gathered by IoT sensors and their use in the environment [23]. To this end, in [23], the authors present a scalable model to \"process data close to sensors and distributed in the fog while data are stored in the cloud\" [23]. Thus, fog computing presents a promising approach to managing the WoV problem for data in smart city applications of IoT.  
In [21], the authors propose a framework named PIAF (Processing Intelligent Agent running on Fog infrastructure) for maximizing the distribution of time-critical data streams processing on the fog infrastructure using MAS. The PIAF workflow comprises the following steps: the selection of the time-critical data stream, splitting the data stream into sub-tasks, prioritization, allocation, execution, tracking, and storage [21].  
Figure 2: Smart city architecture with fog computing.  
However, a limitation of this approach is that there \"is no unique architecture that can be deployed to represent all industries' structures and behaviors\" [21]. We, thus, find that, while fog computing provides a promising approach to handling time-constrained data, there is still the question of how to manage the domain-specific behavioral aspect--the decision-making strategy which functions on these data--as it is distributed across the IoT devices.