AWS Partner Network (APN) Blog

Faster, cheaper, greener: Pick three — FundApps modernization journey

By Lea Mladineo, Staff Engineer – FundApps
By Toby O’Rourke, CTO – FundApps
By Islam Mahgoub, Sr. Solutions Architect – AWS
By Shubhankar Sumar, Sr. Solutions Architect – AWS

FundApps

FundApps, founded in 2010, is one of the pioneers in the regulatory technology space. Equipped with the insight that each and every asset manager needlessly struggles with the same tasks to comply with the same regulation, FundApps used the combination of cloud computing and regulatory expertise to launch the first Compliance-As-A-Service (CaaS) for financial institutions which enables compliance teams to respond efficiently to regulatory change, increase certainty, and reduce complexity associated with compliance processes. FundApps serves the FSI industry, including sectors such as investment banking, hedge funds, pension funds, and asset management.

Today, FundApps helps make compliance simple for over one hundred of the largest financial institutions and monitors over US$20 trillion daily in assets on behalf of their clients.

Originally, FundApps built their platform with a common architecture available in 2010, namely a monolithic application with a traditional three-tier architecture. As the business grew and more clients were onboarded, some challenges surfaced. FundApps decided to re-architect the platform and transform it to a cloud-native architecture on AWS. In this blog post, we dive deep into this transformational journey.

Background

FundApps’ clients can have tens of millions of individual positions, and each of those positions can have hundreds of properties attached to it. Those tens of millions of individual positions are subdivided into individual groups – portfolios, which represent their client’s internal structure — some of the clients have over 50k portfolios.

As illustrated in the diagram below, at the core of the FundApps platform is a highly complex, bespoke rule engine. Its purpose is to identify disclosure requirements for major shareholding, short selling and sensitive industries regulation across more than 100 global jurisdictions. There are over 500 rules which are defined and maintained by a team of regulatory experts. For the largest clients, the combination of positions, portfolios, and rules translates to around 20 million individual rule evaluations, with each evaluation encompassing millions of individual positions. This evaluation is run daily.

FundApps’s client workflow

Figure 1. FundApps’s client workflow

In the beginning, FundApps was built as a monolithic application using a commercial database with a farm of relatively large Windows machines as illustrated in the diagram below:

FundApps old monolithic architecture

Figure 2. FundApps old monolithic architecture

The challenges in the old architecture included cost inefficiencies because of over-provisioning and purchasing licenses for running proprietary relational databases, inefficient usage of databases by using it for storing BLOBs, self-managing databases and wasting time in patching, upgrading, etc., and lastly noisy neighbor problems caused by sharing compute and databases across tenants. These challenges made it very expensive to support larger and more complex clients and became a serious barrier to business and sales growth.

Solution overview

FundApps decided to modernize the platform by adopting cloud-native architecture and leveraging AWS serverless services. The below diagram illustrates the new architecture:

FundApps new architecture

Figure 3. FundApps new architecture

Compute

The main way of scaling the rule engine’s ability to process larger datasets is to distribute the work across multiple compute nodes. Let’s look at how the computation was re-architected from the view of one of the bigger parts of the rule engine parts that need to happen in sequence.

AWS Step Functions, a serverless workflow service, is used for orchestration — the work is partitioned into smaller chunks. Instructions about how the work is partitioned are stored in short-term storage in the form of JSON Lines in Amazon Simple Storage Service (Amazon S3), an object storage service offering industry-leading scalability and performance.

The rule engine distributes the work by queuing the pieces of work as messages in a task queue. Amazon Simple Queue Service (Amazon SQS), serverless queueing service, is used for implementing the task queue.

The workers, each acting as a mini rule engine, asynchronously pick the messages from the queue and independently process them. The workers run on AWS Fargate – a serverless compute engine for containers. Amazon Elastic Container Service (Amazon ECS), a fully managed containers orchestration service, is used for managing the worker containers running on AWS Fargate.

The progress of all of the pieces is tracked using Amazon DynamoDB, a fast and flexible NoSQL database service. When the workers complete all the instructions, the rule engine moves on to the next step.

At peak, FundApps runs around 80,000 Fargate containers across 360 tenant environments concurrently, each on its own isolation boundary, mitigating the noisy neighbor problem that existed in the old architecture.

Storage

In the old architecture, a SQL database was used as a persistence layer for all use cases, including the enriched position data stored in the form of large JSON files. Storing such large volumes of non-relational data placed a significant CPU and IO burden on the database.

Additionally, given the nature of FundApps clients’ business and the fact that multiple copies of the data are needed for high availability and data protection purposes, storing this data in an SQL database led to an increase in the overall volume of the SQL database at a very high pace – this caused backup issues and cost inefficiency. To put it into perspective, one of the volumes of data in one tenant’s SQL database was at 21 TB (or >80TB with replicas and backups), of which the enriched position data in JSON form was taking 19TB, i.e., 90% of the space.

FundApps decided to move the enriched position data in JSON form to Amazon S3. Amazon S3 Select, a feature that enables filtering content using SQL, allows FundApps to retrieve only the data of interest for the operation in hand from Amazon S3, keeping a smaller working set in memory and reducing cost and latency. The movement of this data to Amazon S3 decreased the pressure on the SQL database and reduced the volume of data stored there.

For any given client, the compute workload can be distributed across hundreds of containers. Writing tens of millions of rows to a traditional commercial database from 300 containers at the same time would require large and expensive servers to handle the peak write workload. Because the write peaks are “bursty” and sustained for a relatively short period, FundApps sought a storage solution which could scale up fast for write loads and afterwards, scale down to have an acceptable cost. Amazon Aurora Serverless V2, an on-demand, autoscaling configuration for Amazon Aurora, is a perfect fit for this use case.

By migrating to Amazon Aurora Serverless V2, FundApps eliminated the need for over-provisioning or spending time performing capacity planning – the diagram below shows how Aurora Serverless V2 scale out and in over time. Additionally, FundApps wanted to implement the silo isolation model (i.e., a fully siloed stack of resources per tenant) to address the noisy neighbor problem; Amazon Aurora Serverless V2 enabled a cost-efficient implementation of such model on the database layer.

Amazon Aurora Serverless V2 capacity utilization

Figure 4. Amazon Aurora Serverless V2 capacity utilization

Sustainability

As a BCorp, for FundApps, making the rule engine green is important and naturally impacts architectural decisions. Certified B Corporations, or B Corps, are companies verified by B Lab to meet high standards of social and environmental performance, transparency, and accountability.

Long-lived Windows boxes that were running the single process rule engines and self-managed commercial database were “always on” and over-provisioned, spending a lot of time sitting around and idling. Running them when not needed was a waste of power, which had a negative impact on the environment. Re-architecting FundApps platform to use AWS serverless services that scale up only when needed, reduces power waste and storage footprint.

Results and achieved benefits

The new architecture enabled both business growth and client growth, along with doing better for the environment.

Faster execution

For FundApps’ more complex clients, the rule engine runtime has gone down. Large clients have their runtimes reduced by up to 50% after migration to the new architecture. One customer observed that their file uploading process completed in 39 minutes, where it usually takes 1 hour and 40 minutes to complete, an improvement of 61%.

Increased cost efficiency

Being able to scale down Aurora instances when there is no load and moving a big portion of data to S3 brought storage costs down by 70% from the previous architecture. The diagram below depicts how the AWS charges are now following the actual usage of the system, rather than being static at a high-level catering for over-provisioned resources that sit idle most of the time.

AWS bill for the old architecture

Figure 5. AWS bill for the old architecture

AWS bill for the new architecture

Figure 6. AWS bill for the new architecture

Increased stability

The number of incidents caused by overloaded Windows boxes and noisy neighboring has gone down to zero. Client runtimes are more predictable.

Reduced maintenance overhead

The undifferentiated heavy lifting associated with managing self-hosted complex technology like SQL databases is eliminated, including the weekend work of security patching of Windows boxes previously used both for computation and storage.

By using different data persistence solutions, FundApps benefits from finer segregation of data and different permission levels, which increases visibility and simplifies operations.

Conclusion

In this blog post, we showed how FundApps has combined several purpose-built databases and storage services in their architecture to achieve optimal performance and cost efficiency, spending only 30% of their previous cost on the persistence layer. We also showed how AWS serverless services reduced management overhead and enabled the implementation of an elastic architecture that scales up and down based on demand, increasing cost efficiency and reducing energy waste.

Today, all FundApps clients are on the new architecture, harnessing the power of AWS managed and serverless services. By rearchitecting the rule engine, FundApps created possibilities for their business that were unthinkable before.

..


FundApps – AWS Partner Spotlight

FundApps is an AWS Advanced Technology Partner that provides automated compliance monitoring services to financial institutions, including some of the world’s largest asset managers, hedge funds and investment banks.

Contact FundApps | Partner Overview