Projects tigase _server server-core Issues #582
Monitor Component causes javaX exception (#582)
Won't Fix
Daniel Wisnewski opened 9 years ago
Due Date
2015-10-18

Setting monitor component to load yields the following error:

2015-10-09 11:53:02.498 [main]             MonitorComponent.setProperties()   WARNING:  Monitoring Tasks: {test=taskName=test, taskClass=null, type=scriptTask, configuration=Form{fields=Fields{fields=[x-task#enabled = [1] ], fieldsByVar={x-task#enabled=x-task#enabled = [1] }, log=java.util.logging.Logger@2a42019a}}} with items: {test=taskName=test, taskClass=null, type=scriptTask, configuration=Form{fields=Fields{fields=[x-task#enabled = [1] ], fieldsByVar={x-task#enabled=x-task#enabled = [1] }, log=java.util.logging.Logger@2a42019a}}}
javax.script.ScriptException: <eval>:1:7 Expected an operand but found ]
output[]
       ^ in <eval> at line number 1 at column number 7
	at jdk.nashorn.api.scripting.NashornScriptEngine.throwAsScriptException(NashornScriptEngine.java:467)
	at jdk.nashorn.api.scripting.NashornScriptEngine.compileImpl(NashornScriptEngine.java:534)
	at jdk.nashorn.api.scripting.NashornScriptEngine.compileImpl(NashornScriptEngine.java:521)
	at jdk.nashorn.api.scripting.NashornScriptEngine.evalImpl(NashornScriptEngine.java:399)
	at jdk.nashorn.api.scripting.NashornScriptEngine.eval(NashornScriptEngine.java:155)
	at javax.script.AbstractScriptEngine.eval(AbstractScriptEngine.java:233)
	at tigase.monitor.tasks.ScriptTask.enable(ScriptTask.java:30)
	at tigase.monitor.tasks.AbstractConfigurableTask.setEnabled(AbstractConfigurableTask.java:49)
	at tigase.monitor.tasks.AbstractConfigurableTask.setNewConfiguration(AbstractConfigurableTask.java:58)
	at tigase.monitor.TasksScriptRegistrar.runScriptTask(TasksScriptRegistrar.java:122)
	at tigase.monitor.TasksScriptRegistrar.initTaskFromTaskConfig(TasksScriptRegistrar.java:74)
	at tigase.monitor.TasksScriptRegistrar.load(TasksScriptRegistrar.java:86)
	at tigase.monitor.MonitorComponent.setProperties(MonitorComponent.java:192)
	at tigase.conf.ConfiguratorAbstract.setup(ConfiguratorAbstract.java:540)
	at tigase.conf.ConfiguratorAbstract.componentAdded(ConfiguratorAbstract.java:177)
	at tigase.conf.Configurator.componentAdded(Configurator.java:50)
	at tigase.conf.Configurator.componentAdded(Configurator.java:33)
	at tigase.server.AbstractComponentRegistrator.addComponent(AbstractComponentRegistrator.java:116)
	at tigase.server.MessageRouter.addComponent(MessageRouter.java:108)
	at tigase.server.MessageRouter.addRouter(MessageRouter.java:145)
	at tigase.server.MessageRouter.setProperties(MessageRouter.java:698)
	at tigase.conf.ConfiguratorAbstract.setup(ConfiguratorAbstract.java:540)
	at tigase.conf.ConfiguratorAbstract.componentAdded(ConfiguratorAbstract.java:177)
	at tigase.conf.Configurator.componentAdded(Configurator.java:50)
	at tigase.conf.Configurator.componentAdded(Configurator.java:33)
	at tigase.server.AbstractComponentRegistrator.addComponent(AbstractComponentRegistrator.java:116)
	at tigase.server.MessageRouter.addRegistrator(MessageRouter.java:131)
	at tigase.server.MessageRouter.setConfig(MessageRouter.java:597)
	at tigase.server.XMPPServer.start(XMPPServer.java:142)
	at tigase.server.XMPPServer.main(XMPPServer.java:112)
Caused by: jdk.nashorn.internal.runtime.ParserException: <eval>:1:7 Expected an operand but found ]
output[]
       ^
	at jdk.nashorn.internal.parser.AbstractParser.error(AbstractParser.java:292)
	at jdk.nashorn.internal.parser.AbstractParser.error(AbstractParser.java:277)
	at jdk.nashorn.internal.parser.Parser.unaryExpression(Parser.java:3179)
	at jdk.nashorn.internal.parser.Parser.expression(Parser.java:3279)
	at jdk.nashorn.internal.parser.Parser.memberExpression(Parser.java:2527)
	at jdk.nashorn.internal.parser.Parser.leftHandSideExpression(Parser.java:2374)
	at jdk.nashorn.internal.parser.Parser.unaryExpression(Parser.java:3144)
	at jdk.nashorn.internal.parser.Parser.expression(Parser.java:3279)
	at jdk.nashorn.internal.parser.Parser.expressionStatement(Parser.java:1152)
	at jdk.nashorn.internal.parser.Parser.statement(Parser.java:969)
	at jdk.nashorn.internal.parser.Parser.sourceElements(Parser.java:775)
	at jdk.nashorn.internal.parser.Parser.program(Parser.java:711)
	at jdk.nashorn.internal.parser.Parser.parse(Parser.java:284)
	at jdk.nashorn.internal.parser.Parser.parse(Parser.java:250)
	at jdk.nashorn.internal.runtime.Context.compile(Context.java:1281)
	at jdk.nashorn.internal.runtime.Context.compileScript(Context.java:1248)
	at jdk.nashorn.internal.runtime.Context.compileScript(Context.java:629)
	at jdk.nashorn.api.scripting.NashornScriptEngine.compileImpl(NashornScriptEngine.java:532)
	... 28 more

init.properties

Daniel Wisnewski commented 9 years ago

Error shows in both OpenJDK and Oracle JDK environments.

Error shows with settings set in init.properties, or no settings set (seems internal monitor component is responsible?)

More detailed error here

2015-10-14 08:50:18.352 [main]             MonitorComponent.setProperties()   WARNING:  Monitoring Tasks: {test=taskName=test, taskClass=null, type=scriptTask, configuration=Form{fields=Fields{fields=[x-task#enabled = [1] ], fieldsByVar={x-task#enabled=x-task#enabled = [1] }, log=java.util.logging.Logger@3bcc8f13}}} with items: {test=taskName=test, taskClass=null, type=scriptTask, configuration=Form{fields=Fields{fields=[x-task#enabled = [1] ], fieldsByVar={x-task#enabled=x-task#enabled = [1] }, log=java.util.logging.Logger@3bcc8f13}}}
javax.script.ScriptException: <eval>:1:7 Expected an operand but found ]
output[]
       ^ in <eval> at line number 1 at column number 7
	at jdk.nashorn.api.scripting.NashornScriptEngine.throwAsScriptException(NashornScriptEngine.java:467)
	at jdk.nashorn.api.scripting.NashornScriptEngine.compileImpl(NashornScriptEngine.java:534)
	at jdk.nashorn.api.scripting.NashornScriptEngine.compileImpl(NashornScriptEngine.java:521)
	at jdk.nashorn.api.scripting.NashornScriptEngine.evalImpl(NashornScriptEngine.java:399)
	at jdk.nashorn.api.scripting.NashornScriptEngine.eval(NashornScriptEngine.java:155)
	at javax.script.AbstractScriptEngine.eval(AbstractScriptEngine.java:233)
	at tigase.monitor.tasks.ScriptTask.enable(ScriptTask.java:30)
	at tigase.monitor.tasks.AbstractConfigurableTask.setEnabled(AbstractConfigurableTask.java:49)
	at tigase.monitor.tasks.AbstractConfigurableTask.setNewConfiguration(AbstractConfigurableTask.java:58)
	at tigase.monitor.TasksScriptRegistrar.runScriptTask(TasksScriptRegistrar.java:122)
	at tigase.monitor.TasksScriptRegistrar.initTaskFromTaskConfig(TasksScriptRegistrar.java:74)
	at tigase.monitor.TasksScriptRegistrar.load(TasksScriptRegistrar.java:86)
	at tigase.monitor.MonitorComponent.setProperties(MonitorComponent.java:192)
	at tigase.conf.ConfiguratorAbstract.setup(ConfiguratorAbstract.java:540)
	at tigase.conf.ConfiguratorAbstract.componentAdded(ConfiguratorAbstract.java:177)
	at tigase.conf.Configurator.componentAdded(Configurator.java:50)
	at tigase.conf.Configurator.componentAdded(Configurator.java:33)
	at tigase.server.AbstractComponentRegistrator.addComponent(AbstractComponentRegistrator.java:116)
	at tigase.server.MessageRouter.addComponent(MessageRouter.java:108)
	at tigase.server.MessageRouter.addRouter(MessageRouter.java:145)
	at tigase.server.MessageRouter.setProperties(MessageRouter.java:698)
	at tigase.conf.ConfiguratorAbstract.setup(ConfiguratorAbstract.java:540)
	at tigase.conf.ConfiguratorAbstract.componentAdded(ConfiguratorAbstract.java:177)
	at tigase.conf.Configurator.componentAdded(Configurator.java:50)
	at tigase.conf.Configurator.componentAdded(Configurator.java:33)
	at tigase.server.AbstractComponentRegistrator.addComponent(AbstractComponentRegistrator.java:116)
	at tigase.server.MessageRouter.addRegistrator(MessageRouter.java:131)
	at tigase.server.MessageRouter.setConfig(MessageRouter.java:597)
	at tigase.server.XMPPServer.start(XMPPServer.java:142)
	at tigase.server.XMPPServer.main(XMPPServer.java:112)
Caused by: jdk.nashorn.internal.runtime.ParserException: <eval>:1:7 Expected an operand but found ]
output[]
       ^
	at jdk.nashorn.internal.parser.AbstractParser.error(AbstractParser.java:292)
	at jdk.nashorn.internal.parser.AbstractParser.error(AbstractParser.java:277)
	at jdk.nashorn.internal.parser.Parser.unaryExpression(Parser.java:3179)
	at jdk.nashorn.internal.parser.Parser.expression(Parser.java:3279)
	at jdk.nashorn.internal.parser.Parser.memberExpression(Parser.java:2527)
	at jdk.nashorn.internal.parser.Parser.leftHandSideExpression(Parser.java:2374)
	at jdk.nashorn.internal.parser.Parser.unaryExpression(Parser.java:3144)
	at jdk.nashorn.internal.parser.Parser.expression(Parser.java:3279)
	at jdk.nashorn.internal.parser.Parser.expressionStatement(Parser.java:1152)
	at jdk.nashorn.internal.parser.Parser.statement(Parser.java:969)
	at jdk.nashorn.internal.parser.Parser.sourceElements(Parser.java:775)
	at jdk.nashorn.internal.parser.Parser.program(Parser.java:711)
	at jdk.nashorn.internal.parser.Parser.parse(Parser.java:284)
	at jdk.nashorn.internal.parser.Parser.parse(Parser.java:250)
	at jdk.nashorn.internal.runtime.Context.compile(Context.java:1281)
	at jdk.nashorn.internal.runtime.Context.compileScript(Context.java:1248)
	at jdk.nashorn.internal.runtime.Context.compileScript(Context.java:629)
	at jdk.nashorn.api.scripting.NashornScriptEngine.compileImpl(NashornScriptEngine.java:532)
	... 28 more
Daniel Wisnewski commented 9 years ago

Might be related

Errors in log.0 reveal that logger-task threshold setting is not available as well as disk-task threshold (already known).

Following errors are seen

2015-10-14 08:58:51.294 [main]             BeanConfigurator.configureBeans()  CONFIG:   Cannot set property levelThreshold of bean logger-task
java.lang.NoSuchMethodException: No setter for property 'levelThreshold'.
	at tigase.kernel.BeanUtils.setValue(BeanUtils.java:126)
	at tigase.monitor.BeanConfigurator.configureBeans(BeanConfigurator.java:42)
	at tigase.monitor.MonitorComponent.setProperties(MonitorComponent.java:194)
	at tigase.conf.ConfiguratorAbstract.setup(ConfiguratorAbstract.java:540)
	at tigase.conf.ConfiguratorAbstract.componentAdded(ConfiguratorAbstract.java:177)
	at tigase.conf.Configurator.componentAdded(Configurator.java:50)
	at tigase.conf.Configurator.componentAdded(Configurator.java:33)
	at tigase.server.AbstractComponentRegistrator.addComponent(AbstractComponentRegistrator.java:116)
	at tigase.server.MessageRouter.addComponent(MessageRouter.java:108)
	at tigase.server.MessageRouter.addRouter(MessageRouter.java:145)
	at tigase.server.MessageRouter.setProperties(MessageRouter.java:698)
	at tigase.conf.ConfiguratorAbstract.setup(ConfiguratorAbstract.java:540)
	at tigase.conf.ConfiguratorAbstract.componentAdded(ConfiguratorAbstract.java:177)
	at tigase.conf.Configurator.componentAdded(Configurator.java:50)
	at tigase.conf.Configurator.componentAdded(Configurator.java:33)
	at tigase.server.AbstractComponentRegistrator.addComponent(AbstractComponentRegistrator.java:116)
	at tigase.server.MessageRouter.addRegistrator(MessageRouter.java:131)
	at tigase.server.MessageRouter.setConfig(MessageRouter.java:597)
	at tigase.server.XMPPServer.start(XMPPServer.java:142)
	at tigase.server.XMPPServer.main(XMPPServer.java:112)

2015-10-14 08:58:51.299 [main]             BeanConfigurator.configureBeans()  CONFIG:   Cannot set property threshold[F] of bean disk-task
java.lang.NoSuchMethodException: No setter for property 'threshold[F]'.
	at tigase.kernel.BeanUtils.setValue(BeanUtils.java:126)
	at tigase.monitor.BeanConfigurator.configureBeans(BeanConfigurator.java:42)
	at tigase.monitor.MonitorComponent.setProperties(MonitorComponent.java:194)
	at tigase.conf.ConfiguratorAbstract.setup(ConfiguratorAbstract.java:540)
	at tigase.conf.ConfiguratorAbstract.componentAdded(ConfiguratorAbstract.java:177)
	at tigase.conf.Configurator.componentAdded(Configurator.java:50)
	at tigase.conf.Configurator.componentAdded(Configurator.java:33)
	at tigase.server.AbstractComponentRegistrator.addComponent(AbstractComponentRegistrator.java:116)
	at tigase.server.MessageRouter.addComponent(MessageRouter.java:108)
	at tigase.server.MessageRouter.addRouter(MessageRouter.java:145)
	at tigase.server.MessageRouter.setProperties(MessageRouter.java:698)
	at tigase.conf.ConfiguratorAbstract.setup(ConfiguratorAbstract.java:540)
	at tigase.conf.ConfiguratorAbstract.componentAdded(ConfiguratorAbstract.java:177)
	at tigase.conf.Configurator.componentAdded(Configurator.java:50)
	at tigase.conf.Configurator.componentAdded(Configurator.java:33)
	at tigase.server.AbstractComponentRegistrator.addComponent(AbstractComponentRegistrator.java:116)
	at tigase.server.MessageRouter.addRegistrator(MessageRouter.java:131)
	at tigase.server.MessageRouter.setConfig(MessageRouter.java:597)
	at tigase.server.XMPPServer.start(XMPPServer.java:142)
	at tigase.server.XMPPServer.main(XMPPServer.java:112)
Daniel Wisnewski commented 9 years ago

init.properties file uploaded with settings

issue 1 of 1
Type
Bug
Priority
Major
Assignee
RedmineID
3608
Version
tigase-server-7.1.0
Spent time
6h
Issue Votes (0)
Watchers (0)
Reference
tigase/_server/server-core#582
Please wait...
Page is in error, reload to recover