By Aleshan Maistry, Digital Principal at Synthesis
The logistics industry operates as a complex, global network, reliant on the precise orchestration of countless moving parts. In this era of data-driven decision-making, technologies like Confluent and Kafka have emerged as lighthouses guiding logistics businesses towards streamlined operations, enhanced efficiency, and a new way of interpreting and reacting to data.
Within the logistics domain, we will delve into our experiences and learnings from leveraging Confluent Cloud and KSQL. This journey will reveal both the remarkable potential of these tools and the limitations they sometimes bring to light.
A tale of efficiency and limits
Confluent Cloud, positioned as a managed solution, has garnered attention for its ability to simplify even the most complex data streaming tasks. Our foray into this realm led us to a series of revelations – ones that illuminated the path ahead while occasionally presenting us with formidable challenges.
Bandwidth boundaries
KSQL’s pull queries hold great promise in facilitating seamless data retrieval. Yet, we found ourselves ensnared in bandwidth limits that acted as gatekeepers to data accessibility. Confluent implemented an hourly bandwidth on all pull queries, once this limit is reached all queries being executed would timeout. This caused all our applications to timeout when retrieving data. Confluent’s response was to raise these limits, however even with the raised limits we still ran into them often. The monitoring capabilities also limited us from pinpointing the application and query that was eating up all the bandwidth. The solution to this problem was to host KSQL locally and continue to use Confluent Cloud to host Kafka. With KSQL running locally the bandwidth issues became a thing of the past.
Persistence predicaments
Within the logistics realm, the ability to perform complex queries in a timely manner is paramount. However, Confluent Cloud’s limit of 20 persistence queries proved restrictive for our purposes. Collaborating with a client unveiled that this threshold barely scratched the surface of their requirements. This compelled us to seek a resolution by liaising with Confluent once more, driving a collaborative process of tweaking the architecture to align with these ever-evolving needs. This firsthand encounter highlighted the dynamic nature of the logistics industry and the corresponding need for tools that can seamlessly adapt.
Navigating complex lookup landscapes
In an era where logistics have transcended mere transportation to encompass intricate supply chain ecosystems, the ability to instantaneously access relevant data has emerged as a cornerstone of success. While Kafka and KSQL provide immense value, our journey taught us that the road gets rougher when complex search scenarios come into play.
Complex lookups, diminishing returns
KSQL’s knack for key-value lookups shines brightly, but we encountered rough seas when dealing with intricate search patterns. Our logistics use case demanded not just key-based queries, but also complex WHERE clauses to sift through the data for precise information. However, as the data corpus expanded, performance dwindled, rendering results increasingly impractical. This prompted a pivot towards MongoDB, a database solution that allowed the introduction of indexes, thereby reviving the performance and offering a practical solution to complex queries – something KSQL’s architecture currently lacks.
Character constraints
Logistics often entails grappling with massive and intricate datasets. Our encounter with KSQL queries presented a challenge – a limitation of 2000 characters. This restriction forced us to adapt, dissecting larger queries into smaller components and subsequently resorting to joins. While this workaround kept us afloat, it also resulted in a heightened consumption of persistence queries. This experience reemphasized the necessity for query adaptability, particularly in scenarios where data is voluminous and intricate.
Weaving success through Insight
The trajectory we charted within the realm of Confluent Cloud and KSQL speaks volumes about their potential, while also unearthing their limitations within the dynamic logistics industry. The architectures that were initially put forward were tweaked constantly to deliver the best most efficient solution to our client. The addition of MongoDB and moving KSQL to a locally hosted solution allowed us to still use KSQL and get its benefits. The addition of MongoDB and linking it to Kafka via Kafka connectors also enabled us to index and perform complex queries thus getting the best of both worlds.
Charting the course ahead
In an industry where time is a currency, and efficiency holds the key to maintaining the supply chain’s delicate balance, the convergence of Confluent and Kafka offers promise. At Synthesis, our journey through the intricacies of Confluent Cloud and KSQL has laid bare their strengths and limitations, underscoring the need for adaptable solutions that accommodate the diverse and complex logistics landscape. As we reflect on our experiences, we recognize the boundless potential for Confluent and Kafka to reshape the logistics industry. They provide innovative solutions to the multifaceted challenges that define our era.