Hyperfoil / Horreum

Benchmark results repository service
https://horreum.hyperfoil.io/
Apache License 2.0
34 stars 30 forks source link

Unhelpful error message when creating a new Slack Action. #1779

Open whitingjr opened 2 weeks ago

whitingjr commented 2 weeks ago

Describe the bug

Need an informative error message when the user attempts to save the Action when the token field is empty.

To Reproduce Create a Action Slack that does not have a token string.

{"id":-1,"event":"run/new","type":"slack-channel-message","config":{"type":"slack-channel-message","channel":"notification-horreum-kb"},"secrets":{},"testId":290,"active":true,"runAlways":true}
Warning alert:Failed to update action

{
  "details": "Error id 50d986ef-31fd-4444-a77d-fd2473d464e9-64",
  "stack": ""
}

Server logs have this exception.

2024-06-14 12:38:55,861 ERROR [io.qua.ver.htt.run.QuarkusErrorHandler] (executor-thread-8953) HTTP Request to /api/action/update failed, error id: 50d986ef-31fd-4444-a77d-fd2473d464e9-65: java.lang.IllegalArgumentException: Configuration is missing property 'token'
    at io.hyperfoil.tools.horreum.action.SlackPluginBase.missing(SlackPluginBase.java:42)
    at io.hyperfoil.tools.horreum.action.SlackPluginBase.requireProperties(SlackPluginBase.java:36)
    at io.hyperfoil.tools.horreum.action.SlackChannelMessageAction.validate(SlackChannelMessageAction.java:32)
    at io.hyperfoil.tools.horreum.action.SlackChannelMessageAction_ClientProxy.validate(Unknown Source)
    at io.hyperfoil.tools.horreum.svc.ActionServiceImpl.validate(ActionServiceImpl.java:156)
    at io.hyperfoil.tools.horreum.svc.ActionServiceImpl.update(ActionServiceImpl.java:222)
    at io.hyperfoil.tools.horreum.svc.ActionServiceImpl_Subclass.update$$superforward(Unknown Source)
    at io.hyperfoil.tools.horreum.svc.ActionServiceImpl_Subclass$$function$$3.apply(Unknown Source)
    at io.quarkus.arc.impl.AroundInvokeInvocationContext.proceed(AroundInvokeInvocationContext.java:73)
    at io.quarkus.arc.impl.AroundInvokeInvocationContext$NextAroundInvokeInvocationContext.proceed(AroundInvokeInvocationContext.java:97)
    at io.hyperfoil.tools.horreum.server.RolesInterceptor.intercept(RolesInterceptor.java:70)
    at io.hyperfoil.tools.horreum.server.RolesInterceptor_Bean.intercept(Unknown Source)
    at io.quarkus.arc.impl.InterceptorInvocation.invoke(InterceptorInvocation.java:42)
    at io.quarkus.arc.impl.AroundInvokeInvocationContext.proceed(AroundInvokeInvocationContext.java:70)
    at io.quarkus.arc.impl.AroundInvokeInvocationContext$NextAroundInvokeInvocationContext.proceed(AroundInvokeInvocationContext.java:97)
    at io.quarkus.security.runtime.interceptor.SecurityHandler.handle(SecurityHandler.java:47)
    at io.quarkus.security.runtime.interceptor.RolesAllowedInterceptor.intercept(RolesAllowedInterceptor.java:29)
    at io.quarkus.security.runtime.interceptor.RolesAllowedInterceptor_Bean.intercept(Unknown Source)
    at io.quarkus.arc.impl.InterceptorInvocation.invoke(InterceptorInvocation.java:42)
    at io.quarkus.arc.impl.AroundInvokeInvocationContext.proceed(AroundInvokeInvocationContext.java:70)
    at io.quarkus.arc.impl.AroundInvokeInvocationContext$NextAroundInvokeInvocationContext.proceed(AroundInvokeInvocationContext.java:97)
    at io.quarkus.narayana.jta.runtime.interceptor.TransactionalInterceptorBase.invokeInOurTx(TransactionalInterceptorBase.java:136)
    at io.quarkus.narayana.jta.runtime.interceptor.TransactionalInterceptorBase.invokeInOurTx(TransactionalInterceptorBase.java:107)
    at io.quarkus.narayana.jta.runtime.interceptor.TransactionalInterceptorRequired.doIntercept(TransactionalInterceptorRequired.java:38)
    at io.quarkus.narayana.jta.runtime.interceptor.TransactionalInterceptorBase.intercept(TransactionalInterceptorBase.java:61)
    at io.quarkus.narayana.jta.runtime.interceptor.TransactionalInterceptorRequired.intercept(TransactionalInterceptorRequired.java:32)
    at io.quarkus.narayana.jta.runtime.interceptor.TransactionalInterceptorRequired_Bean.intercept(Unknown Source)
    at io.quarkus.arc.impl.InterceptorInvocation.invoke(InterceptorInvocation.java:42)
    at io.quarkus.arc.impl.AroundInvokeInvocationContext.proceed(AroundInvokeInvocationContext.java:70)
    at io.quarkus.arc.impl.AroundInvokeInvocationContext.proceed(AroundInvokeInvocationContext.java:62)
    at io.quarkus.resteasy.reactive.server.runtime.StandardSecurityCheckInterceptor.intercept(StandardSecurityCheckInterceptor.java:44)
    at io.quarkus.resteasy.reactive.server.runtime.StandardSecurityCheckInterceptor_RolesAllowedInterceptor_Bean.intercept(Unknown Source)
    at io.quarkus.arc.impl.InterceptorInvocation.invoke(InterceptorInvocation.java:42)
    at io.quarkus.arc.impl.AroundInvokeInvocationContext.perform(AroundInvokeInvocationContext.java:30)
    at io.quarkus.arc.impl.InvocationContexts.performAroundInvoke(InvocationContexts.java:27)
    at io.hyperfoil.tools.horreum.svc.ActionServiceImpl_Subclass.update(Unknown Source)
    at io.hyperfoil.tools.horreum.svc.ActionServiceImpl_ClientProxy.update(Unknown Source)
    at io.hyperfoil.tools.horreum.api.internal.services.ActionService$quarkusrestinvoker$update_2c3c30a4688c9b51abcaeb302fb86c2189712d4b.invoke(Unknown Source)
    at org.jboss.resteasy.reactive.server.handlers.InvocationHandler.handle(InvocationHandler.java:29)
    at io.quarkus.resteasy.reactive.server.runtime.QuarkusResteasyReactiveRequestContext.invokeHandler(QuarkusResteasyReactiveRequestContext.java:141)
    at org.jboss.resteasy.reactive.common.core.AbstractResteasyReactiveContext.run(AbstractResteasyReactiveContext.java:147)
    at io.quarkus.vertx.core.runtime.VertxCoreRecorder$14.runWith(VertxCoreRecorder.java:582)
    at org.jboss.threads.EnhancedQueueExecutor$Task.run(EnhancedQueueExecutor.java:2513)
    at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1538)
    at org.jboss.threads.DelegatingRunnable.run(DelegatingRunnable.java:29)
    at org.jboss.threads.ThreadLocalResettingRunnable.run(ThreadLocalResettingRunnable.java:29)
    at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)
    at java.base/java.lang.Thread.run(Thread.java:840)

Version

0.13.0

Browser

FF125