Real-time online trajectory map-matching has emerged as a critical component in the era of location-based services (LBS) and intelligent transportation systems (ITS). It refers to the process of aligning a user’s GPS trajectory data with the corresponding road network in real-time. This technology has significant implications for various industries and applications. As our reliance on LBS and ITS continues to grow, the demand for faster, more accurate, and more reliable trajectory map-matching methods becomes increasingly important. Contemporary online map-matching predominantly employs stream processing techniques. Based on stream processing frameworks, we propose a heterogeneous hybrid architecture for map-matching. The architecture integrates Spark Streaming and graphics processing unit (GPU) heterogeneous computing for the first time. The hidden Markov model is employed as the map-matching algorithm, and Spark Streaming serves as the distributed processing platform. We conduct map-matching experiments using a GPS taxi trajectory dataset in Beijing’s Haidian District. The results demonstrate that in comparison to other analogous research, our framework’s performance has increased by over ten times, possessing a superior data processing capability and lower latency. This research provides a novel approach of stream-based heterogeneous computation for processing large-scale geographic data.