1 option
Practical MongoDB Aggregations : The Official Guide to Developing Optimal Aggregation Pipelines with MongoDB 7. 0 / Paul Done and Asya Kamsky.
- Format:
- Book
- Author/Creator:
- Done, Paul, author.
- Kamsky, Asya, author.
- Language:
- English
- Subjects (All):
- MongoDB.
- Database management--Software.
- Database management.
- Open source software.
- Object-oriented databases.
- Non-relational databases.
- Physical Description:
- 1 online resource (313 pages)
- Edition:
- First edition.
- Place of Publication:
- Birmingham, England : Packt Publishing, [2023]
- Biography/History:
- Done Paul: Paul Done is a Field CTO at MongoDB Inc. , having been a Solutions Architect for the past decade at MongoDB. He has previously held roles in various software disciplines, including engineering, consulting, and pre-sales, at companies like Oracle, Novell, and BEA Systems. Paul specializes in databases and middleware, focusing on resiliency, scalability, transactions, event processing, and applying evolvable data model approaches. He spent most of the early 2000s building Java EE (J2EE) transactional systems on WebLogic, integrated with relational databases like Oracle RAC and messaging systems like MQ Series.
- Summary:
- Begin your journey toward efficient data manipulation with this robust technical guide and enhance your aggregation skills while building efficient pipelines for a variety of tasks Key Features Build effective aggregation pipelines for increased productivity and performance Solve common data manipulation and analysis problems with the help of practical examples Learn essential strategies to aggregate time series data in financial datasets and IoT Purchase of the print or Kindle book includes a free PDF eBook Book Description Officially endorsed by MongoDB, Inc., Practical MongoDB Aggregations helps you unlock the full potential of the MongoDB aggregation framework, including the latest features of MongoDB 7.0. This book provides practical, easy-to-digest principles and approaches for increasing your effectiveness in developing aggregation pipelines, supported by examples for building pipelines to solve complex data manipulation and analytical tasks. This book is customized for developers, architects, data analysts, data engineers, and data scientists with some familiarity with the aggregation framework. It begins by explaining the framework's architecture and then shows you how to build pipelines optimized for productivity and scale. Given the critical role arrays play in MongoDB's document model, the book delves into best practices for optimally manipulating arrays. The latter part of the book equips you with examples to solve common data processing challenges so you can apply the lessons you've learned to practical situations. By the end of this MongoDB book, you'll have learned how to utilize the MongoDB aggregation framework to streamline your data analysis and manipulation processes effectively. What you will learn Develop dynamic aggregation pipelines tailored to changing business requirements Master essential techniques to optimize aggregation pipelines for rapid data processing Achieve optimal efficiency for applying aggregations to vast datasets with effective sharding strategies Eliminate the performance penalties of processing data externally by filtering, grouping, and calculating aggregated values directly within the database Use pipelines to help you secure your data access and distribution Who this book is for This book is for intermediate-level developers, architects, analysts, engineers, and data scientists who are interested in learning about aggregation capabilities in MongoDB. Working knowledge of MongoDB is needed to get the most out of this book.
- Contents:
- Cover
- Title Page
- Copyright and Credits
- Contributors
- Acknowledgements
- Foreword
- Table of Contents
- Preface
- Chapter 1: MongoDB Aggregations Explained
- What is the MongoDB aggregation framework?
- What is the MongoDB aggregation language?
- What do developers use the aggregation framework for?
- A short history of MongoDB aggregations
- Aggregation capabilities in MongoDB server releases
- Getting going
- Setting up your environment
- Database
- Client tool
- Getting further help
- Summary
- Part 1: Guiding Tips and Principles
- Chapter 2: Optimizing Pipelines for Productivity
- Embrace composability for increased productivity
- Guiding principles to promote composability
- Using macro functions
- So, what's the best way of factoring out code?
- Better alternatives for a projection stage
- When to use set and unset
- When to use project
- The hidden danger of project
- Key projection takeaways
- Chapter 3: Optimizing Pipelines for Performance
- Using explain plans to identify performance bottlenecks
- Viewing an explain plan
- Understanding the explain plan
- Guidance for optimizing pipeline performance
- Be cognizant of streaming vs blocking stages ordering
- Avoid unwinding and regrouping documents just to process each array's elements
- Encourage match filters to appear early in the pipeline
- Chapter 4: Harnessing the Power of Expressions
- Aggregation expressions explained
- What do expressions produce?
- Chaining operator expressions together
- Can all stages use expressions?
- What is using expr inside match all about?
- Restrictions when using expressions within match
- Advanced use of expressions for array processing
- if-else conditional comparison
- The power array operators
- for-each looping to transform an array.
- for-each looping to compute a summary value from an array
- for-each looping to locate an array element
- Reproducing map behavior using reduce
- Adding new fields to existing objects in an array
- Rudimentary schema reflection using arrays
- Chapter 5: Optimizing Pipelines for Sharded Clusters
- A brief summary of MongoDB sharded clusters
- Sharding implications for pipelines
- Sharded aggregation constraints
- Where does a sharded aggregation run?
- Pipeline splitting at runtime
- Execution of the split pipeline shards
- Execution of the merger part of the split pipeline
- Difference in merging behavior for grouping versus sorting
- Performance tips for sharded aggregations
- Part 2: Aggregations by Example
- Chapter 6: Foundational Examples: Filtering, Grouping, and Unwinding
- Filtered top subset
- Scenario
- Populating the sample data
- Defining the aggregation pipeline
- Executing the aggregation pipeline
- Expected pipeline results
- Pipeline observations
- Group and total
- Expected pipeline result
- Unpack arrays and group differently
- Distinct list of values
- Chapter 7: Joining Data Examples
- One-to-one join
- Pipeline observations.
- Multi-field join and one-to-many
- Chapter 8: Fixing and Generating Data Examples
- Strongly typed conversion
- Converting incomplete date strings
- Generating mock test data
- Chapter 9: Trend Analysis Examples
- Faceted classification
- Largest graph network
- Incremental analytics
- Chapter 10: Securing Data Examples
- Redacted view
- Mask sensitive fields
- Executing the aggregation pipeline.
- Expected pipeline result
- Role programmatic restricted view
- Chapter 11: Time-Series Examples
- IoT power consumption
- State change boundaries
- Chapter 12: Array Manipulation Examples
- Summarizing arrays for first, last, minimum, maximum, and average values
- Pivoting array items by a key
- Array sorting and percentiles
- Array element grouping
- Array fields joining
- Comparison of two arrays
- Populating the sample data.
- Defining the aggregation pipeline
- Jagged array condensing
- Chapter 13: Full-Text Search Examples
- What is Atlas Search?
- Compound text search criteria
- Facets and counts text search
- Appendix
- Afterword
- Index
- Other books you may enjoy.
- Notes:
- Description based on print version record.
- ISBN:
- 9781835086841
- 1835086845
- OCLC:
- 1396974184
The Penn Libraries is committed to describing library materials using current, accurate, and responsible language. If you discover outdated or inaccurate language, please fill out this feedback form to report it and suggest alternative language.