Couchbase home page linkCouchbase developer portal link
  • Free TrialCouchbase free trial link
  • Downloads
  • Loading...
  • Loading...
  • docs
    • Java
    • Node JS
    • .Net
    • Scala
    • C/C++
    • PHP
    • Python
    • Ruby
    • Go
    • Kotlin
    • Mobile
  • playground
  • learn
  • tutorials
  • videos
  • forums
  • community

Tutorials
on Couchbase

Learn to build and operate apps using Couchbase.

Cloud

Signing Up and UI Overview

Couchbase Capella is a fully managed database-as-a-service that makes it easy to deploy a clustered database.

capella
15 Mins
Cluster and Data

Having followed the sign up process and deployed your first cluster, follow the steps below to explore Couchbase Capella — loading data, configuring your cluster, and connecting to it along the way.

capella
15 Mins
Run Your First Capella Queries

Run Your First N1QL Queries and build indexes on Couchbase Capella

capella
15 Mins
Other Capella Data Tools

Other data tools to find and look for documents.

capella
15 Mins

SDKs

Start with Java and Spring Boot

Build a REST API with Couchbase's Java SDK 3 and Spring Boot.

spring
30 Mins
Couchbase With Spring-Boot and Spring Data

Build a REST API with Couchbase and Spring Data.

spring boot
spring data
java
30 Mins
Transactions with Java SDK

In this exercise will use a sample application that allows transferring virtual credits between different accounts to show how to work with Couchbase transactions in Java SDK.

spring
transactions
30 Mins
Start with Kotlin and Ktor

Build a REST API with Couchbase's Java SDK 3 and Kotlin.

ktor
30 Mins
Quickstart Node JS and Express

Build a REST API with Couchbase's NodeJS SDK 3 using Express.

express
30 Mins
Getting Started with Ottoman v1 and Couchbase Node.js SDK 2.6

Get started with Ottoman version 1 and the Couchbase Node.js SDK version 2.6 using JavaScript to create models and schema, persist, and read data from Couchbase Server.

ottoman
javascript
30 Mins
Connecting with TLS on the Node.js SDK

Connect to a TLS-secured Couchbase cluster (such as Capella) with the root certificate

nodejs
tls
capella
5 Mins
Quickstart Ottoman JS and Express

Build a REST API with Couchbase's Ottoman JS and SDK 3 using Express.

ottoman
express
30 Mins
Quickstart in Couchbase with Scala

Build REST APIs with Couchbase's Scala SDK.

scala
30 Mins
Creating User Defined Functions with Javascript

Build a User Defined Function with Javascript for Query Service

UDF
n1ql
javascript
30 Mins
Creating Analytics User Defined Functions with Python

Build an Analytics User Defined Function with Python.

UDF
analytics
python
30 Mins
ASP.NET Core First Query with Couchbase 6.5

Using the Couchbase .NET SDK in an ASP.NET Core application to create new database records in Couchbase and look them up.

csharp
aspnet
30 Mins
ASP.NET Core First Query with Couchbase SDK 3

Using the Couchbase .NET SDK in an ASP.NET Core application to create new database records in Couchbase and look them up.

csharp
aspnet
30 Mins
.NET Core with Linq2Couchbase First Query

Using the Couchbase .NET SDK in a .NET Core console application to create new database records in Couchbase and look them up with Linq2Couchbase.

csharp
aspnet
linq
30 Mins
Quickstart in Couchbase with C# and ASP.NET

Build a REST API with Couchbase's C# SDK 3 and ASP.NET.

csharp
aspnet
30 Mins
Quickstart in Couchbase with C# and ASP.NET Minimum API

Build a REST API with Couchbase's C# SDK 3 and ASP.NET Minimum API.

csharp
aspnet
30 Mins
Using NextJS with Couchbase NodeJS SDK

Build a basic NextJS front-end and back-end app with Couchbase.

nextjs
javascript
45 Mins
Quickstart in Couchbase with Python and Flask

Build a REST API with Couchbase's Python SDK (4.x) and Flask.

flask
30 Mins

N1QL/Data Modeling

Comparing Document-Oriented and Relational Data

In this tutorial we are comapring document-oriented models vs relational-oriented models for data.

documents
relational
data modeling
10 Mins
Using JSON documents

JSON is a lightweight data-interchange format which is easy to read and change.

json
documents
data modeling
10 Mins
Schemaless Data Modeling

When you use documents to represent data, a database schema is optional. The majority of your effort will be creating one or more documents that will represent application data.

schema
data modeling
10 Mins
Phases of Data Modeling

A data modeling exercise consists of logical and physical data modeling phases to describe your entities and relationships and map them to physical containers.

data modeling
embed
reference
20 Mins
JSON Design Choices

Couchbase Server neither enforces nor validates for any particular document structure. Below are the design choices that impact JSON document design.

json
documents
data modeling
20 Mins
Document Key Design

The most important part of NoSQL database modeling is document keys. There are different patterns when it comes to designing a document key.

documents
keys
10 Mins
Standardization, Optimization, and Resources

Wrapping up our Data Modeling Guide, we talk about standardization and optimization of your documents and modeling and share some resources to help you dive deeper.

documents
opti
10 Mins
Standardized Document Properties

Multiple data sets can share a common bucket in Couchbase. To ensure each data set has isolated keyspaces, it's best practice to include a certain prefixes in your document keys.

documents
relational
data modeling
10 Mins
Document Optimizations

In any database, every byte of stored data adds up, in this tutorial we go over options and best practices to proactively reduce document sizes.

json
document
dates
10 Mins
Schema Versioning

Storing the schema version within the document is a best practice that provides a mechanism to migrate and upgrade models as they change over time. In this tutorial, we illustrate an approach to schema management through code.

json
documents
versioning
20 Mins
Document Revisions

There may be requirements to save multiple revisions of a document within a bucket, this history is maintained by the application. This tutorial is intended to outline one way this can be accomplished.

json
documents
metadata
20 Mins
Understanding Query Workflow and Optimization

Applications submit the N1QL query to one of the available query nodes. The Query node parses and analyzes the query, uses metadata on underlying objects to figure out the optimal execution plan and executes it.

n1ql
tuning
10 Mins
Understanding Index Scans

Query predicate indicates the subset of the data interested. During the query planning phase, we select the indexes to be used for the query.

n1ql
tuning
10 Mins
Identifying the Top Slow Queries

The top slow queries can be identified by querying the system catalog.

n1ql
tuning
15 Mins
Understanding an Explain Plan

The tutorial describes the various attributes you see in an explain plan and how to interpret them.

n1ql
tuning
10 Mins
Understanding Cardinality and Selectivity

Cardinality and selectivity can provide measurable insights into your data set and effectiveness of the index, pointing you to where specific optimizations can be made.

n1ql
tuning
15 Mins
Understanding Covering Indexes and TTLs

When using covering indexes, the N1QL queries are constructed in a way to ensure they do NOT return stale data from your indexes(GSIs).

n1ql
tuning
10 Mins
Tuning Tips and Advice

A collection of tips and advice for you to improve the query performance.

n1ql
tuning
40 Mins
Operators Guide

A guide to all the operators for query optimization.

n1ql
tuning
10 Mins

Mobile

Tutorial Background App Refresh in iOS with UIKit and Swift

Build an iOS App in Swift with UIKit that uses Background.

ios
swift
uikit
30 Mins
Tutorial Couchbase Lite with Recycler Views in Android with Java

Build an Android App in Java with Couchbase Lite and Recycler Views

android
30 Mins
Quickstart with Peer-to-Peer Sync in Swift and UIKit

Build an iOS App in Swift with UIKit that uses Peer-to-Peer Sync

ios
swift
30 Mins
Quickstart with Peer-to-Peer Sync in C# and Xamarin Forms

Build an Xamarin App in C# with Xamarin Forms that uses Peer-to-Peer Sync

charp
xamarin
30 Mins
Quickstart in Couchbase Lite with Android and Java

Build an Android App in Java with Couchbase Lite

android
java
30 Mins
Quickstart in Couchbase Lite Query with Android and Java

Build an Android App in Java and Couchbase Lite using Query

android
java
query
30 Mins
Quickstart in Couchbase Lite Data Sync with Android and Java

Build an Android App that uses Data Sync in Java and Couchbase Lite

android
java
sync gateway
30 Mins
Quickstart in Couchbase Lite Query with iOS, Swift, and UIKit

Build an iOS App in Swift with UIKit and Couchbase Lite using Query

ios
swift
30 Mins
Quickstart in Couchbase Lite with iOS, Swift, and UIKit

Build an iOS App in Swift with UIKit and Couchbase Lite

ios
swift
30 Mins
Quickstart in Couchbase Lite Data Sync with iOS, Swift, and UIKit

Build an iOS App that uses Data Sync in Swift with UIKit and Couchbase Lite

ios
swift
sync gateway
30 Mins
Quickstart in Couchbase Lite with C#, .NET, and Xamarin Forms

Build an App in dotnet with C#, Xamarin Forms, and Couchbase Lite

csharp
dotnet
xamarin-forms
30 Mins
Quickstart in Couchbase Lite Query with C#, .NET, and Xamarin Forms

Build an App in C# with Xamarin and Couchbase Lite using Query

csharp
xamarin
30 Mins
Quickstart in Couchbase Lite Data Sync with C#, .NET, and Xamarin Forms

Build an App that uses Data Sync in C# with Xamarin and Couchbase Lite

csharp
tutorial
xamarin
30 Mins
OpenID Connect Authentication for Sync Gateway with Keycloak

Configure Keycloak an OpenID Connect OP to work with Sync Gateway

auth
openid
sync gateway
30 Mins
XCode Playground: Exploring Couchbase Lite Query API

Use XCode Playground to explore the Couchbase Lite Query API

ios
swift
xcode
30 Mins

Observability

Monitoring Operating System

In order to have a solid understanding of overall cluster health, it is important to monitor the operating system and various stats for each node in the cluster.

monitoring
10 Mins
Monitoring Nodes

This tutorial describes the important metrics and how to monitor them for each node in the cluster.

monitoring
10 Mins
Monitoring XDCR

This tutorial describes the important metrics and how to monitor them for cross data center replication (XDCR) operations in the cluster.

monitoring
10 Mins
Monitoring Query Service

This tutorial describes the important metrics and how to monitor them for query service running in the cluster.

monitoring
10 Mins
Monitoring Index Service

This tutorial describes the important metrics and how to monitor them for index service running in the cluster.

monitoring
10 Mins
Monitoring FTS Service

This tutorial describes the important metrics and how to monitor them for full text service (FTS) running in the cluster.

monitoring
10 Mins
Monitoring Eventing Service

This tutorial describes the important metrics and how to monitor them for eventing service running in the cluster.

monitoring
10 Mins
Logs

This tutorial goes over the Couchbase API used to access the alerts from the logs in the server.

monitoring
10 Mins
Install Prometheus

This tutorial walks you through installation and configuration of Prometheus as a stand alone instance. This should not be installed on each or any node in the Couchbase cluster.

prometheus
alerting
15 Mins
Node Exporter Setup

This tutorial is optional step in the Prometheus Integration Learning Path and requires setup on each server that you wish to gather system metrics using Node Exporter.

prometheus
alerting
15 Mins
Process Exporter Setup

This tutorial is optional step in the Prometheus Integration Learning Path and requires setup on each server that you wish to monitor process metrics using Process Exporter.

prometheus
alerting
15 Mins
Couchbase Exporter Setup

This tutorial walks you through installation and configure the Couchbase Exporter and its dependencies. The mode you run Couchbase Exporter in will determine a single instance for each cluster, or an instance for each node in the cluster.

prometheus
alerting
15 Mins
Configure Prometheus

Prometheus is configured through a single YAML file. When configured, Prometheus runs as a service, in this tutorial, we configure Prometheus.

prometheus
alerting
30 Mins
Configure AlertManager

It's important to know that Prometheus can support multiple AlertManagers for High-Availability by specifying more than one target. For the purpose of this tutorial, we install a single AlertManager on the same server as Prometheus and Grafana.

prometheus
alerting
15 Mins
Configure Prometheus Alerts

This tutorial will help you to set up and configure Prometheus Alerts with AlterManager configuration ans creation and configuration of Prometheus rules for alerting.

prometheus
alerting
15 Mins
Install Grafana

This tutorial walks you through installation and configuration of Grafana as a stand alone instance. This should not be installed on each or any node in the Couchbase cluster.

prometheus
alerting
visualize
15 Mins
Configure Grafana

This tutorial will help you add a data source for Grafana for use with Prometheus to give your dashboard different ways of visualizing your data.

prometheus
alerting
visualize
15 Mins
Upgrading Services

In the final tutorial of the Prometheues Integration learning path, we will upgrade all of our services installed in our application. This can be used for reference in the future as part of ongoing maintainence of your project.

prometheus
alerting
30 Mins
Monitoring Data Service

This tutorial describes the important metrics and how to monitor them for data service running in the cluster.

monitoring
10 Mins

Others

Couchbase Database Server Installation Options

This tutorial shows the different installation options for Couchbase Server - developers can run a Couchbase cluster on many platforms (Capella, Couchbase Playground, Docker, Kubernetes, and locally on their machine). This tutorial will guide you through deploying Couchbase Server on the aforementioned platforms. If you are not sure which one to use, we recommend using Couchbase Capella to get started for the least amount of friction.

installation
capella
server
10 Mins
Customer 360 Data Ingestion

Learn about how Couchbase can fit into your data ingestion architecture

data
360
20 Mins
Couchbase Server CE Docker Container - Example Manual Configuration

Get started with Couchbase Server CE using Docker with manual configuration.

docker
configuration
5 Mins
Installing and Operating Couchbase Server Community Edition (CE)

Tutorial to install and operate Couchbase Server Community Edition (CE)

community
30 Mins
Grafana Dashboards with Couchbase

Tutorial on how to install and configure Grafana Couchbase data source plugin.

grafana
connectors
20 Mins
Working with Support

To speed up the resolution of your issue, our Customer Support will need information to replicate and troubleshoot your issue. The more info provided, the faster we'll able to identify the issue and propose a fix.

support
customer
15 Mins
General Support Best Practices

To help your support ticket get solved in a timely manner, follow these best practices for general support!

support
customer
15 Mins
Was this page helpful?
Couchbase home page link
  • Documentation
  • Downloads
  • Forums
  • Blog
  • Resources
  • Support Login
  • Training
  • Careers
  • Events
  • SDKs
  • Social Media Link for Stack OverflowStack Overflow
  • Social Media Link for GitHubGithub
  • Social Media Link for TwitterTwitter
  • Social Media Link for LinkedInLinkedIn

© 2021 Couchbase, Inc. Couchbase, Couchbase Lite and the Couchbase logo are registered trademarks of Couchbase, Inc.

Terms of UsePrivacy PolicyCookie PolicySupport PolicyMarketing Preference Center