USER STORY
Optimizing Query Times in Payment Authorizations (Fintech)
Challenge
Paysure aimed to enhance their payment authorization process to manage complex data interactions efficiently and deliver timely responses within strict deadlines. This improvement was crucial for maintaining data integrity and preventing overspending due to concurrent transactions.
Solution
Memgraph’s in-memory graph database allowed Paysure to efficiently manage and query complex payment authorization datasets. This reduced query response times and simplified their system architecture.
Reading time: 6min
About Paysure Solutions
Paysure Solutions Ltd. specializes in providing integrated payment solutions for specific industries. They focus on frictionless payment processes for real-time financial transactions and control each payment with industry-specific rule sets.
Impact highlights
Speed and efficiency in payment processing
By using Memgraph, Paysure improved its ability to process payments rapidly and reduced the response time for payment authorization.
Improved system stability and reliability
Memgraph helped handle concurrent transactions, so Paysure saw enhanced system stability. The system can now handle complex queries and large volumes of transactions without faltering.
Consolidating multiple functions into a single query
Ability to streamline processes into a single query. The consolidation was possible because Memgraph can perform complex calculations and transactions atomically. This simplified the architecture significantly, reducing maintenance overhead and improving execution speed.
"For us, the speed was really critical in improving the user experience. If the query is slow, then we wouldn't be able to respond in time and the payment would get declined by the payment network."
Martin Vo, CTO at Paysure Solutions
Key Memgraph Features for Paysure
- Real-time processing. This was essential for meeting a strict time threshold for payment authorization.
- Graph database model. Memgraph enabled complex queries involving nested allowances and relationships, crucial for real-time decision-making in payment authorization.
- Deep path analysis. Enables exploration and a better understanding of complex relationships within large datasets in real-time.
Backstory
Before Paysure started using Memgraph, they wanted to improve their operational processes and remove limitations to its existing architecture. To manage payment authorization processes, Paysure primarily used PostgreSQL and Redis.
However, this setup required multiple stages of data handling, including fetching, locking, and updating, only adding layers of complexity and potential points of failure.
However, this setup required multiple stages of data handling, including fetching, locking, and updating, only adding layers of complexity and potential points of failure.
Challenge
The need to optimize payment authorization processes to handle high volume of data fields in real time.
Paysure had to process payment authorization requests, which involved receiving over 100 data fields from payment networks. This data needed to be processed within a very tight deadline to decide whether to approve or decline a transaction.
They also needed to ensure no overspending occurred, particularly when a user might attempt to authorize payments simultaneously at two terminals. This required the system to handle concurrent transactions intelligently to prevent duplicates or fraud.
Before implementing Memgraph, Paysure used a combination of technologies, including Redis and PostgreSQL, which led to a complex system architecture that was hard to maintain and prone to errors, particularly when dealing with real-time data synchronization and locking mechanisms.
The challenge was the need to execute complex queries across multiple systems. This added latency and complexity, impacting the user experience negatively due to slow response times.
Okay, so how did Paysure use Memgraph to help with these challenges?
They also needed to ensure no overspending occurred, particularly when a user might attempt to authorize payments simultaneously at two terminals. This required the system to handle concurrent transactions intelligently to prevent duplicates or fraud.
Before implementing Memgraph, Paysure used a combination of technologies, including Redis and PostgreSQL, which led to a complex system architecture that was hard to maintain and prone to errors, particularly when dealing with real-time data synchronization and locking mechanisms.
The challenge was the need to execute complex queries across multiple systems. This added latency and complexity, impacting the user experience negatively due to slow response times.
Okay, so how did Paysure use Memgraph to help with these challenges?
Why Memgraph?
Paysure realized that their previous approach to replicating a graph-like structure using traditional databases was probably wrong. They then began exploring alternative solutions to handle complex data relationships more naturally and efficiently.
Before settling on Memgraph, Paysure experimented with another graph database. However, they encountered stability issues and slow query responses. Unsatisfactory and slow support response time from this vendor led them to continue their search for a suitable solution.
- Real-time processing. The ability to process and analyze data in real-time was key. This feature allowed Paysure to make immediate decisions on payment authorizations, crucial for maintaining transaction flow and user satisfaction.
- Atomic transactions. Atomic transactions ensure that all parts of a transaction are completed successfully before committing the data, which is crucial for maintaining data integrity in systems that handle payments.
- Paysure used Memgraph’s support for the Cypher query language, which was specifically designed for graph databases. Cypher’s expressivity and flexibility allowed Paysure to tailor complex queries precisely to their needs, enabling efficient data management.
- Support and community. Paysure valued prompt and effective support, which they found lacking with their previous database provider. Memgraph has a proactive support and active Discord community to help with any questions or challenges during implementation.
"I guess everyone knows the selling points of Memgraph. That it is so fast and so powerful. But for us, speed was really critical for improving user experience."
Martin Vo, CTO at Paysure Solutions
Results
Reduced response times for processing transactions, which is a significant enhancement from the pre-implementation scenario.
Post-implementation, Memgraph simplified the architecture by consolidating multiple functions into a single query process. This change not only reduced the complexity but also minimized the points of failure, leading to an elimination of system downtimes that were previously a concern.
With Memgraph’s support for atomic transactions and ability to handle complex data relationships, Paysure can now efficiently manage multifaceted payment scenarios.
"What Memgraph meant for us was that we no longer needed a complex architecture with numerous workers and message queues, nor did we have to deal with failed messages, undelivered items, Redis, or ensuring that all parts were running with locking and logging timeouts. Instead, we could rely on a single solution—one manager, one query—handling everything for us."
Martin Vo, CTO at Paysure Solutions
Find out how Memgraph performs compared to Neo4j
Let's see how Memgraph fits into your environment