# Enhancing Sustainable IoT Systems Through a Goal-Oriented Requirements Analysis Framework
## 4 Goal-Oriented Requirements Analysis Approach for IoT Software Systems
### Application Example: IoT System for Monitoring Air Quality
#### 4.2.5 QVT for Model-to-Model Transformations
Most significantly, the effort of the developers required to implement the GORA version was reduced by 54.4% in terms of lines of handwritten code. This supports the claim that model-driven approaches increase productivity by automating routine logic generation. Furthermore, the GORA implementation exhibited zero execution or transformation errors in all test runs, indicating a higher degree of reliability and correctness in the generated code. These results collectively support the hypothesis that the GORA methodology offers tangible sustainability and engineering benefits for smart home IoT applications centered on user-driven environmental goals. ### Validation Procedure

The validation process comprises three primary phases: the Docker-based environment configuration, system execution, and performance visualization. In the setup phase, two distinct containerized stacks were deployed, one representing the baseline implementation and the other the GORA-based system. To ensure experimental fairness and comparability, both environments were configured with identical service architectures and parameters. Each stack incorporated an instance of InfluxDB, which is responsible for recording critical run-time metrics, including per-container CPU and memory utilization, as well as timestamp differentials between simulated sensor inputs and their corresponding actuator responses. During the execution phase, each system was run continuously for a period of two hours under identical environmental simulation conditions. MQTT messages were instrumented with timestamps at both the publishing and consumption points, facilitating precise measurements of end-to-end response latency and enabling identification of communication or processing anomalies. For the visualization phase, Grafana dashboards were employed, and these were interfaced with the respective InfluxDB instances. These dashboards rendered real-time visualizations of key system performance indicators, including energy consumption trends and latency distributions. This facilitated a side-by-side comparative analysis of the \begin{table}
\begin{tabular}{c|c|c|c} \hline \hline
**Metric** & **Baseline (Manual)** &
\begin{tabular}{c} **GORA-Based** \\ **(Automated)** \\ \end{tabular} & **Improvement** \\ Energy Consumption (mWh/h) & 338 & **274** & \(\downarrow\)18.9\% \\ System Latency (ms) & 226 & **174** & \(\downarrow\)23.0\% \\ Memory Usage (MB) & 93 & **85** & \(\downarrow\)08.6\% \\ Developer Effort (LOC) & 312 & **142** & \(\downarrow\)54.4\% \\ Code Error Rate (per 10 runs) & 4 & **0** & \(\downarrow\)100\% \\ \hline \hline \end{tabular}
\end{table} 
Table 1: Performance comparison between GORA and baseline IoT implementation. baseline and GORA-based approaches, with a particular emphasis on sustainability and system efficiency. The empirical results presented in Section 5.3 validate the effectiveness of the GORA methodology in enhancing sustainability within simulated IoT deployments. The findings demonstrate that model-driven code, when derived from explicit high-level goals, not only meets functional requirements, but also delivers measurable improvements at the system level. The complete experimental project structure, including configuration files and datasets, has been made publicly available through FigShare to support replicability and further research [35]. This repository includes the following. * [noitemsep]
* docker/docker-compose.yml: Placeholder for orchestrating MQTT broker, Node-RED, InfluaxDB, and Grafana. * node_red_flows/gora_flow.json & baseline_flow.json: Separate flows for goal-oriented and baseline systems. * python_gora_code/iot_system.py: Python code generated from GORA (placeholder). * grafana_dashboards/*.json: Dashboard templates to visualize performance metrics. The dashboard template supports real-time visualization of performance indicators collected during the experimental validation of the GORA methodology.