we will cover everything in the end
That’s great to hear. But some of the things I did in the community plugin was code heavy, I worry that they might be philosophically incompatible with the rest of Gatling.
Speaking of philosophy, what do you think about the use of lens+expression with ScalaPB generated messages?
Compare the following Scala snippet:
for {
firstName <- session("firstName").validate[String]
lastName <- session("lastName").validate[String]
} yield Greeting(firstName, lastName)
and the corresponding Kotlin code:
greeting {
firstName = session.get("firstName") ?: "null"
lastName = session.get("lastName") ?: "null"
}
In the Scala version firstName
appears 3 times (will be four if you use named arguments) - twice are intermediate variables; and the type String
has to be provided explicitly. It doesn’t sit well with me that the Scala code is more verbose than the Kotlin version.
But I also know that the lens magic I did was confusing for many. I’d love to hear your thoughts on that.