Skip to content

Link Tasks / HTML-Reports (quick and dirty solution - JVM only) #283

Open
@teenriot

Description

When you have many benchmarks in a run, it could be difficult to analyze the console output. Also, when the console output is gone, you only have the json reports for later analysis. It would be nice if kotlinx-benchmark had a simple build in mechanism to create persisted human friendly summaries or if there are "end points" that make thirdparty solutions easy.

Thats where JMH Visualizer comes into play. A better solution would be if those visual reports are generated automatically. There is a gradle plugin for this tool, but obviously it doesn't work together with kotlinx-benchmark. So i wrote a "quick and dirty" workaround, which nearly replaces that plugin.

As newbie i wasn't quick writing it and it is more than dirty, since i was not able to link HTML-Report-Generation in a "gradlish" way . To me it looks like benchmark tasks are created on the fly and they have no output. So there is no common way you can link these tasks with other tasks. I think this should / could be improved, not only for the purpose of report generation, but also for other kinds of extended automation.

For those who want to try out what i came up with - (JVM only):
Version 1: Messing up your build.gradle.kts
Version 2: As Gradle-Plugin in buildSrc (doesn't work with: org.gradle.configuration-cache=true)

The results are linked in console
image

The output is equal to JMH Visualizer
image

(i apologize in advance if such tickets are not welcome, since it is more a comment than an issue)

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions