随笔分类 -  Scala

kafka scala API
摘要:scala kafka api test 依赖: <dependency> <groupId>org.apache.kafka</groupId> <artifactId>kafka_2.11</artifactId> <version>1.1.0</version> </dependency> b 阅读全文
posted @ 2020-11-16 11:38 lshan 阅读(369) 评论(0) 推荐(0)
spark-mongo(1 读写数据)
摘要:参考链接 MongoDB Connector for Spark官方文档 Mongo Spark 源码 原文:https://www.jianshu.com/p/dbac491317cc 场景:适用于数据清洗,如只需要部分字段: 依赖: <dependency> <groupId>org.mongo 阅读全文
posted @ 2020-09-08 11:48 lshan 阅读(849) 评论(2) 推荐(0)
scala io 读写文件
摘要:def testPrintAndWriter()= { val line = StdIn.readLine() val writer = new PrintWriter(new File("test.txt" )) writer.write("sea write "+line) writer.clo 阅读全文
posted @ 2020-05-15 16:56 lshan 阅读(216) 评论(0) 推荐(0)
springboot2.X 整合scala
摘要:参考文档: https://segmentfault.com/a/1190000018357979 github: https://github.com/Lshan523/springboot-scala-integration/tree/master/src/main 如果需要注入多个对象: cl 阅读全文
posted @ 2020-05-10 10:32 lshan 阅读(757) 评论(0) 推荐(0)