Java API `javaBucket.collection(collectionName)` docs should state what happens when collection not found

I can see that there is a CollectionNotFoundException, probably thrown, but documentation lacks a description of exceptions.

Thanks for the feedback @zoltan.zvara we will look into it.

It took some time to figure out that it will not create nor throw an exception when the collection is not found. The exact behavior is still unclear to me.

I am assuming you are working with Couchbase Server Versions that has Scopes and Collections enabled. Can you please clarify which Couchbase Server Version you are testing this against ?

Will SDK automatically create a missing Collection - The answer is No. There are management API that you can use (look at Collection Manager) that you can use to either create a wrapper so that it can do that or a bootstrap code that using Collection Manager to be able to create scopes and collections for you.

Java Client 3.0.10 and Couchbase 7.0.0 Beta.

Thanks @zoltan.zvara, I think the only question is when a collection does not exist does SDK response back with a valid error message ? We will get back to you on this.

No, there is no error response after calling javaBucket.collection(collectionName) if collectionName collection does not exist.

Thats right @zoltan.zvara, you should see an exception the first time you use the collection.