草庐IT

JoinWithCassandraTable

全部标签

mysql - C* 端的过滤器 - 将过滤器/范围查询从 Spark 下推到 C*

我使用datastax/spark-cassandra-connector和填充了1B+行的C*表(datastax-enterprisedse4.7.0)开发spark1.2.1。我需要对时间戳参数执行范围过滤器/where查询。在不加载整个1B+行表以激发内存(可能需要数小时才能完成)并且实际上将查询推回C*的情况下,最好的方法是什么?将rdd与JoinWithCassandraTable结合使用,还是将数据框与下推结合使用?还有别的吗? 最佳答案 JoinWithCassandraTable成为我的最佳解决方案。我从这篇文章中

mysql - 时间戳分区键上的 Spark JoinWithCassandraTable STUCK

我正在尝试使用以下方法对巨大的C*表的一小部分进行过滤:valsnapshotsFiltered=sc.parallelize(startDatetoendDate).map(TableKey(_)).joinWithCassandraTable("listener","snapshots_tspark")println("DoneJoin")//*******//getonlythesnapshotsandcreaterddtemptablevaljsons=snapshotsFiltered.map(_._2.getString("snapshot"))valjsonSchemaR