【问题标题】:Apache James with AWS Keyspaces for CassandraApache James 与适用于 Cassandra 的 AWS Keyspaces
【发布时间】:2022-01-16 20:36:41
【问题描述】:

尝试将 Apache James 与 AWS Keyspaces 连接。 James 能够连接,但几秒钟后出现上述错误失败。

根据堆栈跟踪,上述方法引发了异常。

感谢任何帮助。 谢谢,

【问题讨论】:

    标签: cassandra james amazon-keyspaces apache-james


    【解决方案1】:

    如错误消息所示,Amazon Keyspaces 不支持 now 函数,因此如果不进行修改,James 将无法开箱即用。您可以尝试将该功能更改为类似的内容(请参阅QueryBuilder 的文档):

    return session.prepare(select()
             .all()
             .from("local"))
             .bind();
    

    并重建。但很可能,它会在其他地方失败。

    附:真的,有来自OSS Cassandra的plenty of differences,所以很多代码可能不起作用。

    【讨论】:

    • 是的。我也试过了。得到另一个错误。 =============== 13:22:11.850 [cluster7-nio-worker-3] 调试 com.datastax.driver.core.QueryLogger.ERROR - [cluster7] [15.222.43.132/ 15.222.43.132:9142] 1 ms 后查询错误:SELECT count(*) FROM keyspaces WHERE keyspace_name=?; com.datastax.driver.core.exceptions.InvalidQueryException:countRows 尚不受支持。在 com.datastax.driver.core.Responses$Error.asException(Responses.java:181) 在 com.datastax.driver.core.RequestHandler$SpeculativeExecution.onSet(RequestHandler.java:651)
    • 所以 Apache James 不支持 AWS Keyspaces out of the box ?.
    • 我怀疑它不会在没有大量调整的情况下工作
    • 谁能把它翻译成 cql 查询。 select() .fcall("NOW") .from("local")) .bind();
    • 从本地选择 now();
    猜你喜欢
    • 2020-07-30
    • 2020-11-22
    • 2020-08-08
    • 2012-12-31
    • 2015-12-23
    • 2017-10-04
    • 1970-01-01
    • 2011-11-01
    • 1970-01-01
    相关资源
    最近更新 更多