AutoJsonRpcServiceImplExporter not set parallelBatchProcessingTimeout to JsonServiceExporter
anvt1 opened this issue · 1 comments
anvt1 commented
I'm using AutoJsonRpcServiceImplExporter to expose my service as rpc API, now I try to enable it runs in parallel, but It seems parallelBatchProcessingTimeout is not set to JsonServiceExporter via AutoJsonRpcServiceImplExporter configuration.
This my code:
@Bean
public AutoJsonRpcServiceImplExporter autoJsonRpcServiceImplExporter(HttpStatusCodeProvider httpStatusCodeProvider) {
AutoJsonRpcServiceImplExporter exporter = new AutoJsonRpcServiceImplExporter();
ThreadPoolTaskExecutor threadPoolTaskExecutor = new TaskExecutorBuilder()
.corePoolSize(5)
.maxPoolSize(15)
.queueCapacity(50)
.keepAlive(Duration.ofMillis(15000))
.build();
threadPoolTaskExecutor.initialize();
exporter.setBatchExecutorService(threadPoolTaskExecutor.getThreadPoolExecutor());
exporter.setParallelBatchProcessingTimeout(10000);
return exporter;
}
Then I do debug but get parallelBatchProcessingTimeout is 0 in JsonRpcBasicServer#getSingleJsonResponse
If I configure wrong or It's a bug?
Thanks for any support.
anvt1 commented
I had a look to AutoJsonRpcServiceImplExporter#registerServiceProxy, where we register a JsonServiceExporter bean, I don't see anything like builder.addPropertyValue("parallelBatchProcessingTimeout ", parallelBatchProcessingTimeout );