renaissance icon indicating copy to clipboard operation
renaissance copied to clipboard

Chat application benchmark using Kotlin with Ktor framework (Closes #428)

Open zavidnyi opened this issue 9 months ago • 8 comments

zavidnyi avatar Apr 28 '24 13:04 zavidnyi

Hey @farquet, I tried to clarify the benchmark readme. Let me, know if it's more clear now or if there any other issues

zavidnyi avatar Apr 29 '24 09:04 zavidnyi

Ilia (@zavidnyi), could you look into why the JMH wrappers fail to build in the CI? The JMH wrapper around the Kotlin benchmark should not really need to run kotlinCompile task, so maybe just disabling the plugin for the wrappers target could fix that?

lbulej avatar May 14 '24 09:05 lbulej

@lbulej I've fixed an issue by disabling the Koltin plugin for both renaissanceJmhWrappers and dependant renaissanceJmh. However, this seems like more of a workaround rather than a fix. I'm unfamiliar with sbt, so it's hard for me to say why koltinCompile even triggers there.

zavidnyi avatar May 22 '24 12:05 zavidnyi

@lbulej I've fixed an issue by disabling the Koltin plugin for both renaissanceJmhWrappers and dependant renaissanceJmh.

Thanks!

However, this seems like more of a workaround rather than a fix. I'm unfamiliar with sbt, so it's hard for me to say why koltinCompile even triggers there.

No problem, that's the usual case with SBT :-) I'll check later if there is a better way to do this, but I want to merge the benchmark in a state that passes the CI.

One (I believe) last thing: please add test and jmh configurations to the benchmark — see for example RxScrabble.scala. The test configuration is supposed to trigger a short workload meant to be run during CI. The jmh configuration is used when run via JMH and is usually empty (meaning it uses the defaults) — unless there is a need for an override under JMH.

lbulej avatar May 22 '24 12:05 lbulej

@lbulej I've added the test and jmh configurations for the kotlin-ktor

One question: Where is exactly jmh configuration is used? I've not found any place in the repository which calls it and according to the README I'd assume that I can pass arguments to the JMH package as usual, without extra empty configuration

zavidnyi avatar May 23 '24 07:05 zavidnyi

@lbulej I've added the test and jmh configurations for the kotlin-ktor

Thanks!

One question: Where is exactly jmh configuration is used? I've not found any place in the repository which calls it and according to the README I'd assume that I can pass arguments to the JMH package as usual, without extra empty configuration

It is used (by default) by the JmhRenaissanceBenchmark class, which is the base class for JMH wrapper classes that are generated for individual benchmarks.

lbulej avatar May 23 '24 12:05 lbulej

Hi @lbulej, I've just noticed that PR still not merged. I can see that some checks failed, but for some reason I can't see the details. Could you please rerun them, so I could check what's wrong?

zavidnyi avatar Jun 13 '24 09:06 zavidnyi

Hi @lbulej, I've just noticed that PR still not merged. I can see that some checks failed, but for some reason I can't see the details. Could you please rerun them, so I could check what's wrong?

The JVM has trouble finding some Kotlin classes when run under JMH. I have re-run the checks so that you could see for yourself (you should be able to run the CI checks in your repository too).

lbulej avatar Jun 14 '24 14:06 lbulej