标签: amazon-keyspaces

如何将 AWS Lambda 连接到 Amazon Keyspaces (AWS Cassandra)?

正在寻找使用 AWS Lambda 连接到 Amazon Keyspaces(AWS Managed Cassandra)的示例程序,但找不到任何相同的示例程序。

database amazon-web-services cassandra aws-lambda amazon-keyspaces

5
推荐指数
1
解决办法
1423
查看次数

此操作不支持一致性级别 LOCAL_ONE。支持的一致性级别有:LOCAL_QUORUM

我正在使用 AWS keyspaces 并尝试从 C# 插入数据,但收到此错误。“此操作不支持一致性级别 LOCAL_ONE。支持的一致性级别为:LOCAL_QUORUM”。有人可以帮忙吗?

AWS密钥空间

CREATE KEYSPACE IF NOT EXISTS "DevOps"
   WITH REPLICATION={'class': 'SingleRegionStrategy'} ;
Run Code Online (Sandbox Code Playgroud)

桌子

CREATE TABLE IF NOT EXISTS "DevOps"."projectdetails" (
"id" UUID PRIMARY KEY,
"name" text,
"lastupdatedtime" timestamp,
"baname" text,
"customerid" UUID)
Run Code Online (Sandbox Code Playgroud)

C# 代码

 public async Task AddRecord(List<projectdetails> projectDetails)
        {

            try
            {
                if (projectDetails.Count > 0)
                {
                    foreach (var item in projectDetails)
                    {
                        projectdetails projectData = new projectdetails();
                        projectData.id = item.id;
                        projectData.name = item.name;
                        projectData.baname = "Vishal";
                        projectData.lastupdatedtime = item.lastupdatedtime;
                        projectData.customerid = 1;
                        await …
Run Code Online (Sandbox Code Playgroud)

amazon-web-services cassandra amazon-keyspaces

5
推荐指数
1
解决办法
2962
查看次数

如何从 Cassandra 计算 RCU 和 WCU 以进行 AWS Keyspace 成本估算?

为了将 AWS Keyspaces 视为本地 Cassandra 集群的替代方案,我想进行成本估算。但是,密钥空间定价基于写入请求单位 (WRU) 和读取容量单位 (RCU)。

https://aws.amazon.com/keyspaces/pricing/

每个 RRU 提供足够的容量来读取最多 4 KB 的数据,并保持 LOCAL_QUORUM 一致性。每个 WRU 提供足够的容量,可在 LOCAL_QUORUM 一致性下每行写入最多 1 KB 的数据

Cassandra 中的哪些指标可用于计算现有集群的 RCU 和 WCU?

amazon-web-services cassandra cost-management amazon-keyspaces

5
推荐指数
1
解决办法
1342
查看次数

使用 Amazon Keyspaces 存储后端运行 JanusGraph

是否可以使用 AWS Keyspace 作为存储后端来运行 JanusGraph Docker 容器?

我尝试使用 Janus Graphs 模板配置 Keyspace cassandra-es。如果我运行下面的 docker-compose.ymlJanusGraph 日志异常并且所有查询都返回一个ScriptEvaluationError: gremlin-groovy is not an available GremlinScriptEngine'. 也许无法建立与Keyspace的连接?

version: "3"

services:
  janusgraph:
    image: janusgraph/janusgraph:latest
    container_name: jce-janusgraph
    environment:
      JANUS_PROPS_TEMPLATE: cassandra-es
      janusgraph.storage.backend: cql
      janusgraph.storage.hostname: cassandra.eu-central-1.amazonaws.com
      janusgraph.storage.password: <password>
      janusgraph.storage.username: <username>
      janusgraph.storage.cql.keyspace: janusgraphtest
      # janusgraph.storage.cql.ssl.enabled: 'true'
      janusgraph.index.search.hostname: jce-elastic
    ports:
      - "8182:8182"
    networks:
      - jce-network
  elasticsearch:
    image: docker.elastic.co/elasticsearch/elasticsearch:6.6.0
    container_name: jce-elastic
    environment:
      - "ES_JAVA_OPTS=-Xms512m -Xmx512m"
      - "http.host=0.0.0.0"
      - "network.host=0.0.0.0"
      - "transport.host=127.0.0.1"
      - "cluster.name=docker-cluster"
      - "xpack.security.enabled=false"
      - "discovery.zen.minimum_master_nodes=1"
    ports: …
Run Code Online (Sandbox Code Playgroud)

docker-compose janusgraph amazon-keyspaces

3
推荐指数
1
解决办法
1141
查看次数

Amazon Keyspaces“DefaultTokenFactoryRegistry 和 DefaultTopologyMonitor”导致 CPU 和内存使用率过高

我们已将部分表从 AWS RDS 迁移到 AWS Keyspaces,看看是否可以在 KeySpaces 上获得更好的性能。我们投入了大量的工作来从 MySQL 迁移到 Keyspaces,并且我们一直在监控系统以避免爆炸性的不一致。在我们的监控期间,我们观察到以下导致 CPU 和内存使用率过高的警告。

- DefaultTokenFactoryRegistry - [s0] Unsupported partitioner 'com.amazonaws.cassandra.DefaultPartitioner, token map will be empty.
Run Code Online (Sandbox Code Playgroud)

-DefaultTopologyMonitor - [s0] 控制节点 IPx/IPy:9142 在 system.peers 中有一个自身条目:该条目将被忽略。这可能是由于配置错误造成的;请验证集群中所有节点上 cassandra.yaml 中的 rpc_address 配置(IPx 和 IPy 是 cassandra 节点 IP) - 控制节点 cassandra.{REGION}.amazonaws.com/{IP_1}:9142 在系统中拥有其自身的条目。同行:此条目将被忽略。这可能是由于配置错误造成的;请验证集群中所有节点上 cassandra.yaml 中的 rpc_address 配置。

尽管这些警告不会在我们部署代码后以及接下来的几个小时内立即出现,但它会在部署后 24-72 小时后以某种方式出现。

到目前为止我们做了什么?

amazon-web-services cassandra amazon-keyspaces

3
推荐指数
1
解决办法
411
查看次数

将 Janusgraph 与 AWSKeyspaces 结合使用。从 gremlin 控制台添加顶点时,我收到一条错误消息“锁定写入重试次数超出”

Gremlin 控制台: gremlin> :远程连接tinkerpop.server conf/remote.yaml ==>配置的 localhost/127.0.0.1:8182

gremlin> :remote console
==>All scripts will now be sent to Gremlin Server - [localhost/127.0.0.1:8182] - type ':remote console' to return to local mode

gremlin> graph
==>standardjanusgraph[cql:[cassandra.us-east-2.amazonaws.com]]
gremlin> g = graph.traversal()

==>graphtraversalsource[standardjanusgraph[cql:[cassandra.us-east-2.amazonaws.com]], standard]
gremlin> g.addV('student').property('name', 'Jeffery').property('GPA', 'A+');

Lock write retry count exceeded
Run Code Online (Sandbox Code Playgroud)

我的设置如下

  janusgraph.storage.cql.ssl.enabled: "true"
  janusgraph.index.search.hostname: jce-elastic
  janusgraph.storage.cql.local-datacenter: "us-east-2"
  janusgraph.storage.cql.partitioner-name: DefaultPartitioner
  janusgraph.storage.cql.metadata-schema-enabled: "false"
  janusgraph.storage.cql.metadata-token-map-enabled: "false"
  janusgraph.storage.cql.only-use-local-consistency-for-system-operations: "true"
  janusgraph.log.janusgraph.key-consistent: "true"
  janusgraph.log.tx.key-consistent: "true"
  janusgraph.storage.cql.read-consistency-level: "LOCAL_QUORUM"
  janusgraph.storage.cql.write-consistency-level: "LOCAL_QUORUM"
  janusgraph.graph.assign-timestamp: "false"
Run Code Online (Sandbox Code Playgroud)

以下是服务器日志

jce-janusgraph   | 232996 [gremlin-server-exec-4] WARN  org.janusgraph.diskstorage.locking.consistentkey.ConsistentKeyLocker …
Run Code Online (Sandbox Code Playgroud)

gremlin janusgraph amazon-keyspaces

3
推荐指数
1
解决办法
154
查看次数

如何通过 shell 访问 Amazon Keyspaces?

我尝试cqlsh在 AWS shell 中编写,但没有返回任何输出。我参考了这个教程

输出:-bash: cqlsh: command not found

amazon-web-services cassandra nosql wide-column-store amazon-keyspaces

2
推荐指数
1
解决办法
341
查看次数