The couchbase manager is a session manager for glassfish that tries to handle servlet sessions inside a couchbase repository. The external repository maintains the life-cycle completely, expiration, locking and so on. Sessions are retrieved from couchbase in the lock method and saved in the unlock one.