Uploaded image for project: 'Couchbase Documentation'
  1. Couchbase Documentation
  2. DOC-1329

Dash in bucket name and query search trough java SDK

    XMLWordPrintable

Details

    Description

      Hello,

      sorry, I don't know where else I should report this, so I wrote it here.

      Yesterday I was working on a bug, where in our dev environment was not getting data from server trough Java SDK api, but it work on my local machine.

      The code looks like this:

      bucket.query(N1qlQuery.simple(Index.createPrimaryIndex().on(bucket.name())));
      List<N1qlQueryRow> rows = bucket.query(Select.select("*").from(bucket.name())).allRows();
      

      This code was the part of the code which take all data and "reindex" them into elasticsearch when ES mapping changed (We don't normaly get all data from bucket at once, and for the future, we will not be in this cas also, but now our app is so small, that this cause no prblem).

      So, senarious was theese:

      • when my bucket on localhost was called e.g. example it get's all data.
      • when my bucket in dev environment was called e.g. example-dev, then it get's no data
      • when I renamend the bucket (created new) in dev env. to exampledev, it get's all data

      Si I gues, the problem was with the dash.

      And to be complete, here are versions we use:
      Couchbase server: 4.1.0-5005 Enterprise Edition (build-5005)
      Java client: "com.couchbase.client" % "java-client" % "2.2.5"

      Reporter: Jakub Uhrik
      E-mail: jakuub@bookyourself.com

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            marija Marija Jovanovic (Inactive)
            docsite-collector Docs Site Collector
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes

                PagerDuty