Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-8947

Cassandra connector support for 2.x (idealy 2.2.x)

    XMLWordPrintable

Details

    Description

      Hi,

      Currently it doesn't seem like mariadb 10.0.x can connect to a cassandra 2.2.x cluster and recognize the column family

      I assume the issue is that cassandra 2.x uses CQL for most things, rather than thrift legacy these days.

      I get the following error

      ERROR 1429 (HY000): Unable to connect to foreign data source: Column family sessions not found in keyspace sessions

      with the DDL shown below

      set global cassandra_default_thrift_host='localhost'
       
      create table sessions (  
         id varchar(50) PRIMARY KEY 
      ) engine=cassandra keyspace='sessions' column_family='sessions';

      cqlsh> use sessions ;
      cqlsh:sessions> DESCRIBE KEYSPACE;
       
      CREATE KEYSPACE sessions WITH replication = {'class': 'SimpleStrategy', 'replication_factor': '3'}  AND durable_writes = true;
       
      CREATE TABLE sessions.sessions (
          id text PRIMARY KEY,
          client_ip text,
          controller text,
          controller_action text,
          created timestamp,
          data text,
          expires timestamp,
          http_host text,
          modified timestamp,
          request_agent text,
          request_agent_bot boolean,
          request_path text,
          site_id int,
          user_id int
      ) WITH bloom_filter_fp_chance = 0.01
          AND caching = '{"keys":"NONE", "rows_per_partition":"NONE"}'
          AND comment = 'sessions table for bownty apps'
          AND compaction = {'min_threshold': '4', 'class': 'org.apache.cassandra.db.compaction.LeveledCompactionStrategy', 'max_threshold': '32'}
          AND compression = {'sstable_compression': 'org.apache.cassandra.io.compress.LZ4Compressor'}
          AND dclocal_read_repair_chance = 0.1
          AND default_time_to_live = 0
          AND gc_grace_seconds = 864000
          AND max_index_interval = 2048
          AND memtable_flush_period_in_ms = 0
          AND min_index_interval = 128
          AND read_repair_chance = 0.0
          AND speculative_retry = '99.0PERCENTILE';

      I see the following from thrift

      -> cassandra-cli
      Connected to: "Test Cluster" on 127.0.0.1/9160
      Welcome to Cassandra CLI version 2.1.3
       
      The CLI is deprecated and will be removed in Cassandra 3.0.  Consider migrating to cqlsh.
      CQL is fully backwards compatible with Thrift data; see http://www.datastax.com/dev/blog/thrift-to-cql3
       
      Type 'help;' or '?' for help.
      Type 'quit;' or 'exit;' to quit.
       
      [default@unknown] use sessions;
      Authenticated to keyspace: sessions
      [default@sessions] show schema;
       
      WARNING: CQL3 tables are intentionally omitted from 'show schema' output.
      See https://issues.apache.org/jira/browse/CASSANDRA-4377 for details.
       

      Attachments

        Issue Links

          There are no Sub-Tasks for this issue.

          Activity

            People

              psergei Sergei Petrunia
              Jippi Christian Winther
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Git Integration

                  Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.