This commit is contained in:
lxy
2020-08-15 01:06:35 +08:00
parent 60a5bd300f
commit 8f26b66e35
5 changed files with 12 additions and 9 deletions

View File

@@ -60,8 +60,13 @@ public abstract class RedisConsumer<T extends Event> implements IConsumer<T>, Se
br.readLine(); //$n len(value)
String value = br.readLine(); // value
T t = JsonConvert.root().convertFrom(getTypeToken().getType(), value);
accept(t);
try {
T t = JsonConvert.root().convertFrom(getTypeToken().getType(), value);
accept(t);
} catch (Exception e) {
logger.warning("event fmt error :" + value);
e.printStackTrace();
}
}
}
} catch (Exception e) {