Database Development
A growing collection of database-development references — practical, example-driven documentation on the core technologies of data storage and querying.
Sections
-
Choosing the Right Database — when to pick a relational, document, search, vector, graph, key-value, wide-column, time-series or analytical store, how MongoDB and Couchbase differ in practice, and how to keep several databases consistent with CQRS.
-
Pagination: Offset vs. Keyset — why large
OFFSET/SKIPvalues degrade query performance, the keyset (seek method) alternative, and how it maps onto SQL, MongoDB, Couchbase, Solr, Elasticsearch, GraphQL and Spring Data. -
Diagnosing and Fixing Slow Queries — a vendor-neutral workflow for detecting a slow query from each engine’s own log or profiler, reading an execution plan, and matching the typical root causes to the fix documented elsewhere on this site.
-
Database IDEs & Tools — graphical clients for browsing and querying databases, grouped by engine family.
-
SQL Reference — a standard SQL reference covering DDL, DML, DCL, functions, and triggers/stored procedures, plus a downloadable one-page cheat sheet.
-
MongoDB Reference — the document database: the BSON document model, the Query API and aggregation, indexing and search, schema design, transactions and change streams, replication and sharding, storage and security, plus a downloadable one-page cheat sheet.
-
Couchbase Reference — the distributed JSON document and key-value database: buckets, scopes and collections, the key-value and sub-document APIs, SQL++ querying and transactions, Global Secondary Indexes, Full-Text and Vector Search, Analytics and Eventing, clustering, replication and XDCR, storage, security and the SDKs, plus a downloadable one-page cheat sheet.
-
Elasticsearch Reference — the distributed, Lucene-based search and analytics engine: the document and index model, mapping and text analysis, indexing and the Query DSL, relevance and aggregations, joins, geospatial and vector/semantic search, the distributed model, index lifecycle and scaling, performance tuning, administration, snapshots and security, plus a downloadable one-page cheat sheet.
-
Apache Solr Reference — the Lucene-based search server: cores and collections, schema and analysis, indexing and querying, the JSON Request/Facet APIs, relevance, SolrCloud, security, deployment and the SolrJ client, plus a downloadable one-page cheat sheet.
-
Apache Lucene Reference — the embedded Java search library that Elasticsearch, OpenSearch and Solr are built on: the segment/codec index model, the indexing chain, text analysis, the Query API and parsers, points and BKD range search, BM25 and custom scoring, collectors and concurrent search, kNN vector search, faceting, highlighting, suggesters, grouping and joins, near-real-time search and performance tuning, plus a downloadable one-page cheat sheet.
-
Neo4j Reference — the native graph database: the property graph model, Cypher fundamentals through advanced querying, data modeling, importing data, indexes and constraints, transactions and drivers, APOC, security and administration, clustering and multi-database, the Graph Data Science library (pathfinding, centrality, community detection, similarity, embeddings and ML pipelines), vector search and GraphRAG, worked use cases, and a comparison with relational and other graph databases, plus a downloadable one-page cheat sheet.
-
Prometheus & Monitoring — metrics-based monitoring and visualization: the Prometheus data model and metric types, instrumenting applications, exporters and the Pushgateway, service discovery, PromQL, recording and alerting rules, Alertmanager, storage and remote write, security and production operations, and Grafana dashboards and alerting.
-
Qdrant Reference — the vector database purpose-built for similarity search: collections and points, HNSW indexing and quantization, filtering and payload indexing, hybrid and sparse search, CRUD and batch operations, clustering and storage, security and administration, and RAG integration patterns, plus a downloadable one-page cheat sheet.
-
Redis Reference — the in-memory data store for caching, sessions and real-time workloads: core data types, Redis Query Engine and JSON, vector search, streams and pub/sub, probabilistic and time-series structures, pipelining/transactions/scripting, persistence, replication, Sentinel and Cluster, security and administration, client libraries and use cases, Spring Boot integration, and deploying on AWS, Google Cloud and Azure.
-
Vector Databases & RAG — the concepts every vector database shares — embeddings, ANN indexing and quantization, hybrid search, pgvector and sqlite-vec, a vendor comparison, retrieval-augmented generation and agentic RAG, LangChain and Spring AI integration, evaluation and production concerns — plus a downloadable one-page cheat sheet.
-
Evolving the Database Model — safe, consistent schema evolution with Liquibase, Mongock and Flamingock: changelogs, changesets, changeunits and changes, preconditions/contexts/labels, rollback, distributed locking, target systems, stages and pipelines, testing, and the expand/contract pattern.