www.mongodb.com Open in urlscan Pro
2600:9000:211a:c400:7:7859:3840:93a1  Public Scan

Submitted URL: https://email.mongodb.com/u/click?_t=86ba93b39a0e415ea7cd8e8ed81051cd&_m=7b9c6c0e4f0145adb528fac68e8ef705&_e=v16gFtKwNBlSr...
Effective URL: https://www.mongodb.com/blog/post/building-with-patterns-a-summary?utm_source=Iterable&utm_medium=email&utm_campaign=cam...
Submission: On February 12 via manual from US — Scanned from DE

Form analysis 1 forms found in the DOM

GET https://www.mongodb.com/search

<form role="search" method="GET" action="https://www.mongodb.com/search" class="css-1c69emu">
  <div class="css-87svlz">
    <div class="css-36i4c2"><input type="text" placeholder="Search products, whitepapers, &amp; more..." class="css-etrcff"></div>
    <div class="css-v2nqhr">
      <div class="css-aef77t"><button role="button" type="button" class="css-14k7wrz"><span data-testid="selected-value" class="css-6k4l2y">General Information</span>
          <div class="css-109dpaz"><svg data-testid="icon" width="16" height="9" viewBox="0 0 16 9" fill="none" xmlns="http://www.w3.org/2000/svg" class="css-1yzkxhp">
              <path d="M1.06689 0.799988L8.00023 7.73332L14.9336 0.799988" stroke-linecap="round" stroke-linejoin="round" class="css-1tlq8q9"></path>
            </svg></div>
        </button>
        <div class="css-hn9qqo">
          <ul data-testid="options" role="listbox" class="css-ac9zo2">
            <li role="option" tabindex="0" class="css-11dtrvq">General Information</li>
            <li role="option" tabindex="0" class="css-11dtrvq">All Documentation</li>
            <li role="option" tabindex="0" class="css-11dtrvq">Realm Documentation</li>
            <li role="option" tabindex="0" class="css-11dtrvq">Developer Articles &amp; Topics</li>
            <li role="option" tabindex="0" class="css-11dtrvq">Community Forums</li>
            <li role="option" tabindex="0" class="css-11dtrvq">Blog</li>
            <li role="option" tabindex="0" class="css-11dtrvq">University</li>
          </ul>
        </div>
      </div><input type="hidden" id="addsearch" name="addsearch">
      <div class="css-1myrko"><button type="submit" tabindex="0" class=" css-13l1z36" data-track="true"><img alt="search icon" src="https://webimages.mongodb.com/_com_assets/cms/krc3hljsdwdfd2w5d-web-actions-search.svg?auto=format%252Ccompress"
            class="css-r9fohf"></button></div>
    </div>
  </div>
</form>

Text Content

New
{New}  
Announcing MongoDB Atlas Vector Search and Dedicated Search Nodes for genAI use
cases
General Information

 * General Information
 * All Documentation
 * Realm Documentation
 * Developer Articles & Topics
 * Community Forums
 * Blog
 * University


 * Products
   Platform
   AtlasBuild on a developer data platform
   Platform Services
   DatabaseDeploy a multi-cloud databaseSearchDeliver engaging search
   experiencesVector SearchDesign intelligent apps with GenAIStream Processing
   (Preview)Unify data in motion and data at rest
   Tools
   CompassWork with MongoDB data in a GUIIntegrationsIntegrations with
   third-party servicesRelational MigratorMigrate to MongoDB with confidence
   Self Managed
   Enterprise AdvancedRun and manage MongoDB yourselfCommunity EditionDevelop
   locally with MongoDB
   Build with MongoDB Atlas
   Get started for free in minutes
   Sign Up
   Test Enterprise Advanced
   Develop with MongoDB on-premises
   Download
   Try Community Edition
   Explore the latest version of MongoDB
   Download
 * Resources
   Documentation
   Atlas DocumentationGet started using AtlasServer DocumentationLearn to use
   MongoDBStart With GuidesGet step-by-step guidance for key tasks
   
   Tools and ConnectorsLearn how to connect to MongoDBMongoDB DriversUse drivers
   and libraries for MongoDB
   AI Resources HubGet help building the next big thing in AI with
   MongoDBarrow-right
   Connect
   Developer CenterExplore a wide range of developer resourcesCommunityJoin a
   global community of developersCourses and CertificationLearn for free from
   MongoDBWebinars and EventsFind a webinar or event near you
 * Solutions
   Use cases
   Artificial IntelligenceEdge ComputingInternet of
   ThingsMobilePaymentsServerless Development
   Industries
   Financial ServicesTelecommunicationsHealthcareRetailPublic
   SectorManufacturing
   Solutions LibraryOrganized and tailored solutions to kick-start
   projectsarrow-right
   Developer Data Platform
   Accelerate innovation at scale
   Learn morearrow-right
   Startups and AI Innovators
   For world-changing ideas and AI pioneers
   Learn morearrow-right
   Customer Case Studies
   Hear directly from our users
   See Storiesarrow-right
 * Company
   CareersStart your next adventureBlogRead articles and
   announcementsNewsroomRead press releases and news stories
   PartnersLearn about our partner ecosystemLeadershipMeet our executive
   teamCompanyLearn more about who we are
   Contact Us
   Reach out to MongoDB
   Let’s chatarrow-right
   Investors
   Visit our investor portal
   Learn morearrow-right
 * Pricing

SupportSign In
Try Free
menu-vertical


Home

News

Applied

QuickStart

Updates

Culture

Events

Artificial Intelligence

Engineering Blog

All


BUILDING WITH PATTERNS: A SUMMARY

Learn More About MongoDB at MongoDB University
Daniel Coupal and Ken W. Alger
April 26, 2019 | Updated: October 2, 2023
#Developer#University

This post is also available in: Deutsch, Français, Español, Português

As we wrap up the Building with Patterns series, it’s a good opportunity to
recap the problems the patterns that have been covered solve and highlight some
of the benefits and trade-offs each pattern has. The most frequent question that
is asked about schema design patterns, is “I’m designing an application to do X,
how do I model the data?” As we hope you have discovered over the course of this
blog series, there are a lot of things to take into consideration to answer
that. However, we’ve included a Sample Use Case chart that we’ve found helpful
to at least provide some initial guidance on data modeling patterns for generic
use cases.


SAMPLE USE CASES

The chart below is a guideline for what we’ve found after years of experience
working with our customers of what schema design patterns are used in a variety
of applications. This is not a “set in stone” set of rules about which design
pattern can be used for a particular type of application. Ensure you look at the
ones that are frequently used in your use case. However, don't discard the other
ones, they may still apply. How you design your application’s data schema is
very dependent on your data access patterns.




DESIGN PATTERN SUMMARIES


APPROXIMATION

The Approximation Pattern is useful when expensive calculations are frequently
done and when the precision of those calculations is not the highest priority.

PROS

 * Fewer writes to the database.
 * Maintain statistically valid numbers.

CONS

 * Exact numbers aren’t being represented.
 * Implementation must be done in the application.


ATTRIBUTE

The Attribute Pattern is useful for problems that are based around having big
documents with many similar fields but there is a subset of fields that share
common characteristics and we want to sort or query on that subset of fields.
When the fields we need to sort on are only found in a small subset of
documents. Or when both of those conditions are met within the documents.

PROS

 * Fewer indexes are needed.
 * Queries become simpler to write and are generally faster.


BUCKET

The Bucket Pattern is a great solution for when needing to manage streaming
data, such as time-series, real-time analytics, or Internet of Things (IoT)
applications.

PROS

 * Reduces the overall number of documents in a collection.
 * Improves index performance.
 * Can simplify data access by leveraging pre-aggregation.


COMPUTED

When there are very read intensive data access patterns and that data needs to
be repeatedly computed by the application, the Computed Pattern is a great
option to explore.

PROS

 * Reduction in CPU workload for frequent computations.
 * Queries become simpler to write and are generally faster.

CONS

 * It may be difficult to identify the need for this pattern.
 * Applying or overusing the pattern should be avoided unless needed.


DOCUMENT VERSIONING

When you are faced with the need to maintain previous versions of documents in
MongoDB, the Document Versioning pattern is a possible solution.

PROS

 * Easy to implement, even on existing systems.
 * No performance impact on queries on the latest revision.

CONS

 * Doubles the number of writes.
 * Queries need to target the correct collection.


EXTENDED REFERENCE

You will find the Extended Reference pattern most useful when your application
is experiencing lots of JOIN operations to bring together frequently accessed
data.

PROS

 * Improves performance when there are a lot of JOIN operations.
 * Faster reads and a reduction in the overall number of JOINs.

CONS

 * Data duplication.


OUTLIER

Do you find that there are a few queries or documents that don’t fit into the
rest of your typical data patterns? Are these exceptions driving your
application solution? If so, the Outlier Pattern is a wonderful solution to this
situation.

PROS

 * Prevents a few documents or queries from determining an application’s
   solution.
 * Queries are tailored for “typical” use cases, but outliers are still
   addressed.

CONS

 * Often tailored for specific queries, therefore ad hoc queries may not perform
   well.
 * Much of this pattern is done with application code.


PRE-ALLOCATION

When you know your document structure and your application simply needs to fill
it with data, the Pre-Allocation Pattern is the right choice.

PROS

 * Design simplification when the document structure is known in advance.

CONS

 * Simplicity versus performance.


POLYMORPHIC

The Polymorphic Pattern is the solution when there are a variety of documents
that have more similarities than differences and the documents need to be kept
in a single collection.

PROS

 * Easy to implement.
 * Queries can run across a single collection.


SCHEMA VERSIONING

Just about every application can benefit from the Schema Versioning Pattern as
changes to the data schema frequently occur in an application’s lifetime. This
pattern allows for previous and current versions of documents to exist side by
side in a collection.

PROS

 * No downtime needed.
 * Control of schema migration.
 * Reduced future technical debt.

CONS

 * Might need two indexes for the same field during migration.


SUBSET

The Subset Pattern solves the problem of having the working set exceed the
capacity of RAM due to large documents that have much of the data in the
document not being used by the application.

PROS

 * Reduction in the overall size of the working set.
 * Shorter disk access time for the most frequently used data.

CONS

 * We must manage the subset.
 * Pulling in additional data requires additional trips to the database.


TREE

When data is of a hierarchical structure and is frequently queried, the Tree
Pattern is the design pattern to implement.

PROS

 * Increased performance by avoiding multiple JOIN operations.

CONS

 * Updates to the graph need to be managed in the application.


CONCLUSION

As we hope you have seen in this series, the MongoDB document model provides a
lot of flexibility in how you model data. That flexibility is incredibly
powerful but that power needs to be harnessed in terms of your application’s
data access patterns. Remember that schema design in MongoDB has a tremendous
impact on the performance of your application. We’ve found that performance
issues can frequently be traced to poor schema design.

Keep in mind that to further enhance the power of the document model, these
schema design patterns can be used together, when and if it makes sense. For
example, Schema Versioning can be used in conjunction with any of the other
patterns as your application evolves. With the twelve schema design patterns
that have been covered, you have the tools and knowledge needed to harness the
power of the document model’s flexibility.


← Previous


MONGODB’S OFFICIAL BREW TAP NOW OPEN AND FLOWING

We know macOS users love using Homebrew, aka Brew, "the missing package manager
for macOS". Its made life so much simpler installing both open source and freely
available applications - it lets anyone create a tap to make their software
available. That is why we are very happy to announce that we now have our own
official MongoDB Tap which makes it simpler than ever to install the latest
MongoDB.

April 25, 2019
Next →


MAXIMIZING GROWTH: THE POWER OF AI UNLEASHED IN PAYMENTS

Artificial Intelligence (AI) technologies are an integral part of the banking
industry. In areas such as risk, fraud , and compliance, for example, the use of
AI has been commonplace for years and continues to deepen. The success of these
initiatives (and others), and the potential to unlock further benefits, is
driving further investment in this area in 2024, with Generative AI attracting
particular interest. Financial tech analyst Celent created a report commissioned
by MongoDB and Icon Solutions which dives into how AI is currently being used in
the banking industry today, as well as some of the key use cases for AI adoption
in payments to improve operational agility, automate workflows, and increase
developer productivity. Download Celent’s report: Harnessing the Benefits of AI
in Payments to discover how you can make the most of your AI investments and
unlock the limitless possibilities that AI holds for the future of payments.
Unlocking a range of workflow and product enhancements AI technologies are used
today to address a wide range of different workflows and customer-facing
services from process automation and optimization in the middle and back office,
to areas such as real-time risk and liquidity management, cashflow forecasting,
and service personalization in the front office. Virtual assistants and bots
have also become an important part of the customer support process. Below,
discover some of the key findings from Celent’s Harnessing the Benefits of AI in
Payments report and what this means for the banking and payments industry.
Advanced analytics, intelligent automation, and AI technologies lead the
investment agenda in 2024 Over time, banks have steadily increased their
investments in projects to make better and more efficient use of data. In part,
this has been driven by the need to respond to rising customer expectations over
the speed and quality of digital services but it also reflects a growing
understanding of the true value of account and transaction data. Most important
of all though has been enabling the technologies required to deliver use cases
supported by AI and advanced analytics. It is no surprise to see that projects
supported by data analytics and AI technologies are high on the agenda globally.
Advanced analytics and machine learning investments are a leading technology
priority for 33% of corporate banks, ranking higher than projects relating to
robotics and automation (which are a focus for 31% of the market). Artificial
intelligence and natural language processing (NLP) are not far behind and were
highlighted as a priority by 28% of banks. Many are also exploring Generative AI
While the excitement around GenAI is understandable given the obvious potential,
the conversation became more nuanced through the latter part of 2023. This is
understandable given the complexities of applying large language models (LLMs)
to potentially sensitive customer data, as well as broader regulatory concerns
over the explainability (and potential auditability) of LLM outputs. That said,
there are many areas in which GenAI is already being used to support advisors
and relationship managers and further innovation in areas such as this is
expected. 58% of banks are evaluating or testing Generative AI in some capacity
while a further 23% have projects using this technology in their roadmap.
Emerging use cases for AI in payments and the potential revenue growth of 5.3%
if past resource constraints were overcome A lack of developer capacity is one
of the biggest challenges for banks when it comes to delivering payment product
innovation. Banks believe the product enhancements they could not deliver in the
past two years due to resource constraints would have supported a 5.3% growth in
payments revenues. With this in mind and the revolutionary transformation with
the integration of AI, financial institutions must consider how to free up
developer resources to make the most of these opportunities. Below are some of
the exciting and transformative use cases for AI in payments highlighted by
Celent. As the payments industry continues to evolve, the integration of AI is
poised to reshape the landscape, offering innovative solutions that prioritize
security, efficiency, and a personalized user experience. The emerging use cases
for AI in payments are a testament to its transformative potential in shaping
the future of financial transactions. Leveraging modern technologies to make the
most of AI adoption In the rapidly evolving landscape of AI, constant
technological advancements and evolving customer needs necessitate strategic
investments. To stay competitive, banks and payment providers should not only
focus on current product enhancements but also future-proof their capabilities
through payment infrastructure modernization . When adopting advanced
technologies like AI and ML which require data as the foundation, organizations
often grapple with the challenge of integrating these innovations into legacy
systems due to their inflexibility and resistance to modification. For example,
adding a new payment rail and a new customer access point could be very
difficult. Establishing a robust data architecture with a modern data platform
that enables banks to enrich the payments experience by consolidating and
analyzing data in any format in real-time, driving value-added services and
features to consumers. Train AI/ML models on the most accurate and up-to-date
data , thereby addressing the critical need for adaptability and agility in the
face of evolving technologies. By unifying data from backend payment processing
to customer interactions, banks can surface insights in real-time to create a
seamless, connected, and personalized customer journey. Future-proof with a
flexible data schema capable of accommodating any data structure, format, or
source. This flexibility facilitates seamless integration with different AI/ML
platforms, allowing financial institutions to adapt to changes in the AI
landscape without extensive modifications to the infrastructure. Address
security concerns with built-in security controls across all data. Whether
managed in a customer environment or through MongoDB Atlas, a fully managed
cloud service, MongoDB ensures robust security with features such as
authentication (single sign-on and multi-factor authentication), role-based
access controls, and comprehensive data encryption. These security measures act
as a safeguard for sensitive financial data, mitigating the risk of unauthorized
access from external parties and providing organizations with the confidence to
embrace AI and ML technologies. Launch and scale always-on and secure
applications by integrating third-party services with APIs. MongoDB's flexible
data model and ability to handle various types of data, including structured and
unstructured data, is a great fit for orchestrating your open API ecosystem to
make data flow between banks, third parties, and consumers possible. MongoDB’s
developer data platform puts powerful AI and analytics capabilities directly in
the hands of developers and offers the capabilities to enrich payment
experiences by consolidating, ingesting, and acting on any payment data type
instantly. Overcome data challenges with MongoDB's document data model has the
flexibility and third-party integration capabilities required to create
composable payment systems that scale effortlessly, are always-on, secure, and
ACID compliant. Stay ahead of the curve – download Celent’s report now and
unlock the limitless possibilities that AI holds for the future of payments. If
you prefer a visual exploration, a discussion featuring Celent, Icon Solutions,
and MongoDB is available to watch here . If you would like to discover more
about building AI-enriched payment applications with MongoDB, take a look at the
following resources: Discover how the financial sector can make use of
Generative AI Deliver AI-enriched payment apps with the right security controls
in place, and at the scale and performance users expect Sign up for our Atlas
for Industries programme to get access to our solution accelerators to drive
innovation

February 12, 2024



© 2023 MongoDB, Inc.

About

 * Careers
 * Investor Relations
 * Legal Notices
 * Privacy Notices
 * Security Information
 * Trust Center

Support

 * Contact Us
 * Customer Portal
 * Atlas Status
 * Customer Support

Social

 * GitHub
 * Stack Overflow
 * LinkedIn
 * YouTube
 * Twitter
 * Twitch
 * Facebook

© 2023 MongoDB, Inc.


By clicking "Accept All Cookies", you agree to the storing of cookies on your
device to enhance site navigation, analyze site usage, and assist in our
marketing efforts. You can enable and disable optional cookies as desired.Read
our Privacy Policy
Manage Cookies Accept All Cookies



PRIVACY PREFERENCE CENTER

"Cookies" are small files that enable us to store information while you visit
one of our websites. When you visit any website, it may store or retrieve
information on your browser, mostly in the form of cookies. This information
might be about you, your preferences or your device and is mostly used to make
the site work as you expect it to. The information does not usually directly
identify you, but it can give you a more personalized web experience. Because we
respect your right to privacy, you can choose not to allow some types of
cookies, but essential cookies are always enabled. Click on the different
category headings to find out more and change our default settings. However,
blocking some types of cookies may impact your experience of the site and the
services we are able to offer.
MongoDB Privacy Policy
Allow All


MANAGE CONSENT PREFERENCES

STRICTLY NECESSARY COOKIES

Always Active

These cookies are necessary for the website to function and cannot be switched
off in our systems. They are usually only set in response to actions made by you
which amount to a request for services, such as setting your privacy
preferences, logging in or filling in forms. You can set your browser to block
or alert you about these cookies, but some parts of the site will not then work.
These cookies do not store any personally identifiable information.

PERFORMANCE COOKIES

Performance Cookies

These cookies allow us to count visits and traffic sources so we can measure and
improve the performance of our site. They help us to know which pages are the
most and least popular and see how visitors move around the site. All
information these cookies collect is aggregated and therefore anonymous. If you
do not allow these cookies we will not know when you have visited our site, and
will not be able to monitor its performance.

FUNCTIONAL COOKIES

Functional Cookies

These cookies enable the website to provide enhanced functionality and
personalisation. They may be set by us or by third party providers whose
services we have added to our pages. If you do not allow these cookies then some
or all of these services may not function properly.

TARGETING COOKIES

Targeting Cookies

These cookies may be set through our site by our advertising partners. They may
be used by those companies to build a profile of your interests and show you
relevant adverts on other sites. They do not store directly personal
information, but are based on uniquely identifying your browser and internet
device. If you do not allow these cookies, you will experience less targeted
advertising.

SOCIAL MEDIA COOKIES

Social Media Cookies

These cookies are set by a range of social media services that we have added to
the site to enable you to share our content with your friends and networks. They
are capable of tracking your browser across other sites and building up a
profile of your interests. This may impact the content and messages you see on
other websites you visit. If you do not allow these cookies you may not be able
to use or see these sharing tools.

Back Button


COOKIE LIST



Search Icon
Filter Icon

Clear
checkbox label label
Apply Cancel
Consent Leg.Interest
checkbox label label
checkbox label label
checkbox label label

Confirm My Choices