This commit is contained in:
lxyer 2018-08-29 15:49:40 +08:00
parent e4a7dc48aa
commit 4c5ee1baf2
5 changed files with 8 additions and 5 deletions

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -13,8 +13,8 @@
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.8</source>
<target>1.8</target>
<source>10</source>
<target>10</target>
</configuration>
</plugin>
</plugins>
@ -25,12 +25,12 @@
<dependency>
<groupId>org.redkale</groupId>
<artifactId>redkale</artifactId>
<version>1.9.5.2</version>
<version>1.9.6</version>
</dependency>
<dependency>
<groupId>org.redkalex</groupId>
<artifactId>redkale-plugins</artifactId>
<version>1.9.5.2</version>
<version>1.9.6</version>
</dependency>
<dependency>

View File

@ -24,6 +24,7 @@ import org.redkale.source.FilterExpress;
import org.redkale.source.FilterNode;
import org.redkale.source.Flipper;
import org.redkale.util.AnyValue;
import org.redkale.util.Comment;
import org.redkale.util.Sheet;
import javax.annotation.Resource;
@ -67,10 +68,12 @@ public class TaskQueue<T extends Object> extends BaseService implements Runnable
visLog = database.getCollection("vis_log");
}
@RestMapping(ignore = true)
public T take() throws InterruptedException {
return (T) queue.take();
}
@RestMapping(ignore = true)
public void put(T t) throws InterruptedException {
queue.put(t);
}
@ -98,7 +101,7 @@ public class TaskQueue<T extends Object> extends BaseService implements Runnable
}
}
@RestMapping(ignore = true, comment = "帖子阅读数处理")
@Comment("帖子阅读数处理")
private void updateViewNumAsync(Map logData) {
CompletableFuture.runAsync(()->{
Bson filter = and(