Lentiq chose Couchbase as its primary database due to its previous experience with it from their parent company Bigstep, where they had already tested and used Couchbase for performance. The team needed a fast, reliable, and scalable database that could support a microservices-based architecture, and Couchbase met all these requirements. They allocated separate buckets for each microservice, allowing each service to have its own user and access credentials. This approach also assisted with scaling and reliability. The Spring data Couchbase library made it easy to connect to and use Couchbase for reading and writing data. Lentiq uses pessimistic locking, specifically `getAndLock` and `unlock`, to ensure exclusive access to certain documents while performing critical operations like physical resources checks. They integrated the lock document creation and deletion with the environment's creation and deletion flows to solve the issue of atomic getOrCreateAndLock. Overall, Couchbase has proven to be a reliable and fast storage layer for Lentiq's internal microservices, meeting all their requirements and enabling them to implement a successful NoSQL database solution.