Autonomous Coworking Space 🏢
🏢 Overview
This project is an autonomous coworking space management system developed for the Software Engineering for Autonomous Systems course at the University of L'Aquila.
At its core, it implements a MAPE-K (Monitor, Analyze, Plan, Execute, Knowledge) feedback loop to continuously observe workspace conditions and adapt behavior without manual intervention.
🦾 Repository
Code and documentation: github.com/gianlucarea/autonomous-cwspace
Why I built it
Coworking environments have many moving parts: room conditions, occupancy patterns, device coordination, and operational constraints. The project explores how an autonomic architecture can coordinate these signals and apply adaptive decisions in real time.
Rather than treating monitoring and control as separate concerns, the system models them as a closed loop where sensing, analysis, planning, and execution are explicitly connected.
🛠️ Architecture
MAPE-K Loop (Managing System)
- →Monitor: Telegraf collects metrics from MQTT Broker and stores them in InfluxDB knowledge base
- →Analyzer: Java application that analyzes system state and identifies needed adjustments
- →Planner: Spring Boot application that creates action plans (with optional proactive planner variant)
- →Executor: Java application that executes planned actions and controls the environment
- →Knowledge: InfluxDB time-series database storing all system metrics and state
Managed System
- →cwspace-environment: Node.js application simulating office rooms and environmental conditions
- →node-red: IoT platform simulating sensors and actuators throughout the workspace
Monitoring & Control
- →Mosquitto MQTT Broker: Central message broker for all component communication (port 1883, 9001)
- →Grafana Dashboard: Real-time visualization and monitoring of system performance and metrics (port 3000)
How the system works
The managed environment emits telemetry through MQTT. Monitoring components collect and persist that data, then analysis and planning services evaluate system state and generate corrective actions. The executor applies those actions back to the environment, closing the loop.
This structure makes the platform easier to reason about because each responsibility is isolated while still operating as part of one adaptive control pipeline.
🚀 Key Features
- →Autonomous Management: MAPE-K loop continuously monitors and optimizes workspace conditions
- →Real-Time Monitoring: Live dashboards and metrics via Grafana
- →IoT Integration: Simulated sensors and actuators via Node-RED
- →Time-Series Data: Store and analyze metrics with InfluxDB
- →MQTT Communication: Efficient message-based inter-component communication
- →Modular Design: Separate containerized services for scalability
- →Docker Deployment: Complete containerized setup via docker-compose
Engineering focus
- →Applying autonomic computing concepts to a realistic multi-service setup
- →Building clear communication boundaries between services via MQTT
- →Using time-series observability to support adaptive decisions
- →Keeping the stack reproducible with containerized local deployment
🔧 Getting Started
Requirements: Docker and Docker Compose
Configuration: The system exposes the following ports:
- →8081: Planner service
- →1883, 9001: Mosquitto MQTT Broker
- →8086: InfluxDB
- →3000: Grafana dashboard
Running:
# Build all images
docker-compose build
# Start all containers
docker-compose up -d
# Stop containers
docker-compose down
📚 Learn More
For deeper details, see Documentation/Report.pdf plus Documentation/Images/ and Documentation/Diagrams/ in the repository.
What I learned
- →How to design an end-to-end MAPE-K loop with clear component responsibilities
- →How to structure event-driven communication in distributed systems
- →How observability tools like InfluxDB and Grafana support adaptive behavior analysis
🤝 Contributing
Contributions are welcome. If you want to improve architecture modules, simulation fidelity, or documentation quality, feel free to open a pull request.
- →Fork the repository.
- →Create a new branch:
git checkout -b feature-name. - →Make your changes and commit them:
git commit -m 'Add new feature'. - →Push to the branch:
git push origin feature-name. - →Open a Pull Request.
Please ensure your code follows the existing style and includes appropriate documentation.
📧 Contact
For questions, feedback, or collaboration opportunities, feel free to reach out:
- →LinkedIn: Gianluca Rea
- →Email: gianlucarea.work@gmail.com
This project reflects my interest in autonomous systems, distributed backend design, and practical control-loop engineering.