Commit 6bf9045d authored by 赵威's avatar 赵威

add printer

parent 7ab85667
......@@ -12,13 +12,13 @@ object Redis {
def save(contentF: Future[IndexedSeq[Content]], deviceId: String, contentType: String): Unit = {
val key = s"streaming:candidate:${contentType}:device_id:${deviceId}"
println(key)
contentF.foreach { seq =>
val ids = seq.map(c => c.id)
if (ids.size > 0) {
pRc4.del(key)
ids.foreach { id =>
// println(id)
println(id)
pRc4.rpush(key, id)
}
pRc4.expire(key, 60 * 60 * 24 * 15)
......
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