In the era of smart cities, efficient resource allocation is critical for seamless task execution and minimizing latency. This study introduces a hybrid computing framework integrated with SUMO (Simulation of Urban Mobility) to address real-time allocation challenges across distributed and centralized edge servers. The framework ensures reliable connectivity between IoT devices and edge servers in urban environments. In the simulation, self-organizing IoT devices generate computational tasks, transmitted to self-adaptive edge servers strategically deployed in high-traffic areas, while the main server manages system-wide load balancing. The framework integrates two algorithms: RAIDER (Resource Allocation and Integration for Distributed Edge Routing), which optimizes task distribution among edge servers, and TRAX (Task Resource Allocation eXecutor), which clusters tasks and balances load at the main server. Results show that RAIDER reduces bandwidth by 13%, power consumption by 11.4%, and latency by 25% compared to greedy approaches. TRAX achieves 62.3% lower delay and 89% reduced variability under heavy workloads, ensuring stable performance at scale. These results validate the framework’s ability to optimize resource use across the computing infrastructure, providing a strong foundation for managing future urban demands. © 2025 IEEE.