Commit bbe53666 authored by 赵威's avatar 赵威

remove test

parent feb95858
...@@ -45,9 +45,8 @@ object Main extends LazyLogging { ...@@ -45,9 +45,8 @@ object Main extends LazyLogging {
"172.16.44.25:9092,172.16.44.31:9092,172.16.44.45:9092" "172.16.44.25:9092,172.16.44.31:9092,172.16.44.45:9092"
) )
// TODO remove test
val kafkaConsumer = new FlinkKafkaConsumer[UserInfo]( val kafkaConsumer = new FlinkKafkaConsumer[UserInfo](
"gm-portrait-update-device-test", "gm-portrait-update-device",
new UserInfoDeserializationSchema, new UserInfoDeserializationSchema,
kafkaConsumerProperties kafkaConsumerProperties
) )
......
...@@ -34,6 +34,7 @@ object Redis { ...@@ -34,6 +34,7 @@ object Redis {
): Unit = { ): Unit = {
val key = s"streaming:candidate:${contentType}:device_id:${deviceId}" val key = s"streaming:candidate:${contentType}:device_id:${deviceId}"
try {
contentEitherFuture match { contentEitherFuture match {
case Left(e) => e.printStackTrace() case Left(e) => e.printStackTrace()
case Right(contentFuture) => case Right(contentFuture) =>
...@@ -63,6 +64,18 @@ object Redis { ...@@ -63,6 +64,18 @@ object Redis {
} }
} }
} }
} catch {
case e: Throwable =>
DingTalk.send(
Map(
"method" -> "Redis.save",
"deviceId" -> deviceId,
"contentType" -> contentType,
"error" -> e.getStackTrace.mkString("\n")
),
contentType = "exception"
)
}
} }
def saveServiceDiary( def saveServiceDiary(
...@@ -88,7 +101,12 @@ object Redis { ...@@ -88,7 +101,12 @@ object Redis {
} catch { } catch {
case e: Throwable => case e: Throwable =>
DingTalk.send( DingTalk.send(
Map("method" -> "Redis.saveServiceDiary", "error" -> e.getStackTrace.mkString("\n")), Map(
"method" -> "Redis.saveServiceDiary",
"deviceId" -> deviceId,
"contentType" -> "service_diary",
"error" -> e.getStackTrace.mkString("\n")
),
contentType = "exception" contentType = "exception"
) )
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment