战斗记录逻辑优化,但是未启用(可能会增加io和内存)
parent
a32bec7c08
commit
e7e0ce8eb8
|
@ -1,6 +1,5 @@
|
||||||
package com.ljsd.jieling.logic.fight;
|
package com.ljsd.jieling.logic.fight;
|
||||||
|
|
||||||
import com.googlecode.protobuf.format.JsonFormat;
|
|
||||||
import com.ljsd.jieling.logic.dao.root.User;
|
import com.ljsd.jieling.logic.dao.root.User;
|
||||||
import org.slf4j.Logger;
|
import org.slf4j.Logger;
|
||||||
import org.slf4j.LoggerFactory;
|
import org.slf4j.LoggerFactory;
|
||||||
|
@ -51,12 +50,12 @@ public class FightRecordLogic {
|
||||||
* 添加信息至队列中
|
* 添加信息至队列中
|
||||||
*/
|
*/
|
||||||
public void addRecordMap(User user, CommonProto.FightData fightData){
|
public void addRecordMap(User user, CommonProto.FightData fightData){
|
||||||
try {
|
// try {
|
||||||
String str = JsonFormat.printToString(fightData);
|
// String str = JsonFormat.printToString(fightData);
|
||||||
queue.offer(str);
|
// queue.offer(str);
|
||||||
}catch (Exception e){
|
// }catch (Exception e){
|
||||||
e.printStackTrace();
|
// e.printStackTrace();
|
||||||
}
|
// }
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue