Let's suppose that we need to develop an application that will sell books online. We have already decided the technologies to be used for it. We will be using Couchbase as a database and Couchbase Java SDK APIs to develop it. Since we are using Couchbase as the backend, we will be designing our data model in terms of documents. As mentioned earlier, it is impossible to discuss and analyze the entire ecosystem of e-commerce in a single chapter; we will discuss only one or two scenarios.
In any typical e-commerce application, you can browse catalogs, search for products, view them, add them to a shopping cart, and order them. You will have modules for customer registration, inventory management, fulfillment management, advertising management, and so on. However, in this chapter we will discuss only the minimal relevant scenarios so that you understand how to apply a NoSQL document design in the Couchbase cluster.