use of rpc.turbo.benchmark.bean.Page in project turbo-rpc by hank-whu.
the class ProtostuffBenchmark method deserializeUserPage.
@Benchmark
@BenchmarkMode({ Mode.Throughput })
@OutputTimeUnit(TimeUnit.MILLISECONDS)
@SuppressWarnings("unchecked")
public Page<User> deserializeUserPage() throws Exception {
listBuffer.readerIndex(0);
ByteBufInput input = new ByteBufInput(listBuffer, true);
Page<User> userPage = (Page<User>) userPageSchema.newMessage();
userPageSchema.mergeFrom(input, userPage);
return userPage;
}
Aggregations