高加载服务器的Vert.x设置

发布于 2025-01-18 06:50:44 字数 484 浏览 2 评论 0原文

我有8个内核的服务器 在那个服务器中,我每秒有3000个传入请求 哪些设置最好用于最佳性能? 新的deploymentOptions()。setInstances(???); 由于我的8个核心服务器,我需要8个实例吗?默认情况下是1。 最好使用: .setWorker(true).setWorkerPoolSize(???) 或者我只需要对此保留什么?如果我需要设置WorkerPoolsize,它将是多少?默认情况下是20。

我无法在生产中进行比较,我需要对此进行预测。

非常感谢您的回答!

还有其他问题: 以下是使异步在VERTX管道中工作的正确方法吗? 返回 Future 的管道步骤呼叫函数,在 oncomplete 中的将调用 ctx.next() 如果没有,我如何在管道中间进行异步工作?

I have server with 8 CORES
In that server I have 3000 incoming requests per second
What settings are best to use for best performance?
new DeploymentOptions().setInstances(???);
Do I need 8 instances because of my 8 cores server? By default it's 1.
Is that better to use: .setWorker(true).setWorkerPoolSize(???)
Or I need just keep nothing for that? And if I need to set workerPoolSize how much will it be? By default it's 20.

I can't compare it in production, I need predict for that.

Thanks a lot for answer!

And additional question:
Is the following the right way to making async work in vertx pipeline?
pipeline step call function that return Future and in that Future in onComplete will call ctx.next()
If no, how I can do async work in the middle of pipeline?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

梦断已成空 2025-01-25 06:50:44

您应该有16个实例用于8个核心。

您是否正在使用executeBlocking功能?如果是 - 您应该将工作池大小设置为128

和其他问题:以下是使异步在VERTX管道中工作的正确方法吗?管道步骤呼叫函数将来返回未来以及在OnComplete中的未来将调用ctx.next(),如果否,我如何在管道中间进行异步工作?

问题没有意义。您应该在投入为3K RPS生产的服务之前阅读文档

You should have 16 instances for 8 cores.

Are you using the executeBlocking functionality? If yes - you should set the worker pool size to 128

And additional question: Is the following the right way to making async work in vertx pipeline? pipeline step call function that return Future and in that Future in onComplete will call ctx.next() If no, how I can do async work in the middle of pipeline?

Question doesn't make sense. You should read the docs before putting a service that serves 3k rps in production

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文