You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
2024-01-20 15:11:05 [alerter-worker-1] WARN org.dromara.hertzbeat.manager.component.alerter.DispatcherAlarm - DispatchTask sendNoticeMsg error, message: [Discord Bot Notify Error] I/O error on POST request for "https://discord.com/api/v9/channels/www/messages": Connection reset; nested exception is java.net.SocketException: Connection reset
2024-01-20 15:11:05 [alerter-worker-1] ERROR freemarker.runtime - Error executing FreeMarker template
freemarker.core.InvalidReferenceException: The following has evaluated to null or missing:
==> alarmId [in template "freeMakerTemplate" at line 2, column 16]
----
Tip: If the failing expression is known to legally refer to something that's sometimes null or missing, either specify a default value like myOptionalVar!myDefault, or use <#if myOptionalVar??>when-present<#else>when-missing</#if>. (These only cover the last step of the expression; to cover the whole expression, use parenthesis: (myOptionalVar.foo)!myDefault, (myOptionalVar.foo)??
----
----
FTL stack trace ("~" means nesting-related):
- Failed at: ${alarmId} [in template "freeMakerTemplate" at line 2, column 14]
----
at freemarker.core.InvalidReferenceException.getInstance(InvalidReferenceException.java:134)
at freemarker.core.EvalUtil.coerceModelToTextualCommon(EvalUtil.java:481)
at freemarker.core.EvalUtil.coerceModelToStringOrMarkup(EvalUtil.java:401)
at freemarker.core.EvalUtil.coerceModelToStringOrMarkup(EvalUtil.java:370)
at freemarker.core.DollarVariable.calculateInterpolatedStringOrMarkup(DollarVariable.java:100)
at freemarker.core.DollarVariable.accept(DollarVariable.java:63)
at freemarker.core.Environment.visit(Environment.java:347)
at freemarker.core.Environment.visit(Environment.java:353)
at freemarker.core.Environment.process(Environment.java:326)
at freemarker.template.Template.process(Template.java:383)
at org.springframework.ui.freemarker.FreeMarkerTemplateUtils.processTemplateIntoString(FreeMarkerTemplateUtils.java:50)
at org.dromara.hertzbeat.manager.component.alerter.impl.AbstractAlertNotifyHandlerImpl.renderContent(AbstractAlertNotifyHandlerImpl.java:121)
at org.dromara.hertzbeat.manager.component.alerter.impl.WebHookAlertNotifyHandlerImpl.send(WebHookAlertNotifyHandlerImpl.java:51)
at org.dromara.hertzbeat.manager.component.alerter.DispatcherAlarm.sendNoticeMsg(DispatcherAlarm.java:90)
at org.dromara.hertzbeat.manager.component.alerter.DispatcherAlarm$DispatchTask.sendNotify(DispatcherAlarm.java:137)
at org.dromara.hertzbeat.manager.component.alerter.DispatcherAlarm$DispatchTask.run(DispatcherAlarm.java:119)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:829)
2024-01-20 15:11:05 [alerter-worker-1] WARN org.dromara.hertzbeat.manager.component.alerter.DispatcherAlarm - DispatchTask sendNoticeMsg error, message: [WebHook Notify Error] The following has evaluated to null or missing:
==> alarmId [in template "freeMakerTemplate" at line 2, column 16]
----
Tip: If the failing expression is known to legally refer to something that's sometimes null or missing, either specify a default value like myOptionalVar!myDefault, or use <#if myOptionalVar??>when-present<#else>when-missing</#if>. (These only cover the last step of the expression; to cover the whole expression, use parenthesis: (myOptionalVar.foo)!myDefault, (myOptionalVar.foo)??
----
----
FTL stack trace ("~" means nesting-related):
- Failed at: ${alarmId} [in template "freeMakerTemplate" at line 2, column 14]
----
Expected Behavior
No response
Steps To Reproduce
No response
Environment
HertzBeat version(s): 1.4.4
Debug logs
2024-01-20 15:11:05 [alerter-worker-1] WARN org.dromara.hertzbeat.manager.component.alerter.DispatcherAlarm - DispatchTask sendNoticeMsg error, message: [Discord Bot Notify Error] I/O error on POST request for "https://discord.com/api/v9/channels/www/messages": Connection reset; nested exception is java.net.SocketException: Connection reset
2024-01-20 15:11:05 [alerter-worker-1] ERROR freemarker.runtime - Error executing FreeMarker template
freemarker.core.InvalidReferenceException: The following has evaluated to null or missing:
==> alarmId [in template "freeMakerTemplate" at line 2, column 16]
----
Tip: If the failing expression is known to legally refer to something that's sometimes null or missing, either specify a default value like myOptionalVar!myDefault, or use <#if myOptionalVar??>when-present<#else>when-missing</#if>. (These only cover the last step of the expression; to cover the whole expression, use parenthesis: (myOptionalVar.foo)!myDefault, (myOptionalVar.foo)??
----
----
FTL stack trace ("~" means nesting-related):
- Failed at: ${alarmId} [in template "freeMakerTemplate" at line 2, column 14]
----
at freemarker.core.InvalidReferenceException.getInstance(InvalidReferenceException.java:134)
at freemarker.core.EvalUtil.coerceModelToTextualCommon(EvalUtil.java:481)
at freemarker.core.EvalUtil.coerceModelToStringOrMarkup(EvalUtil.java:401)
at freemarker.core.EvalUtil.coerceModelToStringOrMarkup(EvalUtil.java:370)
at freemarker.core.DollarVariable.calculateInterpolatedStringOrMarkup(DollarVariable.java:100)
at freemarker.core.DollarVariable.accept(DollarVariable.java:63)
at freemarker.core.Environment.visit(Environment.java:347)
at freemarker.core.Environment.visit(Environment.java:353)
at freemarker.core.Environment.process(Environment.java:326)
at freemarker.template.Template.process(Template.java:383)
at org.springframework.ui.freemarker.FreeMarkerTemplateUtils.processTemplateIntoString(FreeMarkerTemplateUtils.java:50)
at org.dromara.hertzbeat.manager.component.alerter.impl.AbstractAlertNotifyHandlerImpl.renderContent(AbstractAlertNotifyHandlerImpl.java:121)
at org.dromara.hertzbeat.manager.component.alerter.impl.WebHookAlertNotifyHandlerImpl.send(WebHookAlertNotifyHandlerImpl.java:51)
at org.dromara.hertzbeat.manager.component.alerter.DispatcherAlarm.sendNoticeMsg(DispatcherAlarm.java:90)
at org.dromara.hertzbeat.manager.component.alerter.DispatcherAlarm$DispatchTask.sendNotify(DispatcherAlarm.java:137)
at org.dromara.hertzbeat.manager.component.alerter.DispatcherAlarm$DispatchTask.run(DispatcherAlarm.java:119)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:829)
2024-01-20 15:11:05 [alerter-worker-1] WARN org.dromara.hertzbeat.manager.component.alerter.DispatcherAlarm - DispatchTask sendNoticeMsg error, message: [WebHook Notify Error] The following has evaluated to null or missing:
==> alarmId [in template "freeMakerTemplate" at line 2, column 16]
----
Tip: If the failing expression is known to legally refer to something that's sometimes null or missing, either specify a default value like myOptionalVar!myDefault, or use <#if myOptionalVar??>when-present<#else>when-missing</#if>. (These only cover the last step of the expression; to cover the whole expression, use parenthesis: (myOptionalVar.foo)!myDefault, (myOptionalVar.foo)??
----
----
FTL stack trace ("~" means nesting-related):
- Failed at: ${alarmId} [in template "freeMakerTemplate" at line 2, column 14]
----
Anything else?
No response
The text was updated successfully, but these errors were encountered:
I noticed that org/dromara/hertzbeat/manager/component/alerter/impl/AbstractAlertNotifyHandlerImpl.renderContent method has code model.put("alarmId", alert.getId()); . Is the alarmId allowed to be null? Do we have default value about alarmId if alarmId is null and we don’t allow alarmId is null?
Is there an existing issue for this?
Current Behavior
webhook notice error happen
Expected Behavior
No response
Steps To Reproduce
No response
Environment
Debug logs
Anything else?
No response
The text was updated successfully, but these errors were encountered: