rspec/rules/S2122/kotlin/rule.adoc
Johann Beleites c607360a48
Create rule S2122[Kotlin]: "ScheduledThreadPoolExecutor" should not have 0 core threads (#326)
* Create rule S2122[Kotlin]: "ScheduledThreadPoolExecutor" should not have 0 core threads

* Update rules/S2122/description.adoc

Co-authored-by: margarita-nedzelska-sonarsource <70522623+margarita-nedzelska-sonarsource@users.noreply.github.com>

Co-authored-by: margarita-nedzelska-sonarsource <70522623+margarita-nedzelska-sonarsource@users.noreply.github.com>
2021-09-14 10:31:55 +00:00

15 lines
255 B
Plaintext

include::../description.adoc[]
== Noncompliant Code Example
----
fun do() {
val stpe1 = ScheduledThreadPoolExecutor(0) // Noncompliant
val stpe2 = ScheduledThreadPoolExecutor(POOL_SIZE)
stpe2.corePoolSize = 0 // Noncompliant
...
----