<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<atom:link href="https://www.xlayer.co.za/forum/extern.php?action=feed&amp;tid=18&amp;type=rss" rel="self" type="application/rss+xml" />
		<title><![CDATA[SXI Forum / X-Notify 9.1.14.NullPointerException]]></title>
		<link>https://www.xlayer.co.za/forum/viewtopic.php?id=18</link>
		<description><![CDATA[The most recent posts in X-Notify 9.1.14.NullPointerException.]]></description>
		<lastBuildDate>Wed, 21 Nov 2018 08:58:30 +0000</lastBuildDate>
		<generator>FluxBB</generator>
		<item>
			<title><![CDATA[X-Notify 9.1.14.NullPointerException]]></title>
			<link>https://www.xlayer.co.za/forum/viewtopic.php?pid=30#p30</link>
			<description><![CDATA[<p><strong>Error:</strong><br />[za.co.sxi.concurrent.MonitoredThreadFactory$RecoverableThreadRunner.uncaughtException] java.lang.NullPointerException: Thread &#039;XNotifyXml&#039; stopped unexpectedly: null, will restart it<br />[za.co.sxi.concurrent.MonitoredThreadFactory$RecoverableThreadRunner.uncaughtException] StackTrace:<br />[za.co.sxi.concurrent.MonitoredThreadFactory$RecoverableThreadRunner.uncaughtException] bin.NotificationService.sendNotification(NotificationService.java:197)<br />[za.co.sxi.concurrent.MonitoredThreadFactory$RecoverableThreadRunner.uncaughtException] plugins.input.InputAbstractPlugin.sendNotification(InputAbstractPlugin.java:61)<br />[za.co.sxi.concurrent.MonitoredThreadFactory$RecoverableThreadRunner.uncaughtException] plugins.input.XNotifyXml.processFile(XNotifyXml.java:44)<br />[za.co.sxi.concurrent.MonitoredThreadFactory$RecoverableThreadRunner.uncaughtException] plugins.input.XNotifyXml.loopIteration(XNotifyXml.java:84)<br />[za.co.sxi.concurrent.MonitoredThreadFactory$RecoverableThreadRunner.uncaughtException] plugins.input.InputAbstractPlugin.run(InputAbstractPlugin.java:69)<br />[za.co.sxi.concurrent.MonitoredThreadFactory$RecoverableThreadRunner.uncaughtException] java.lang.Thread.run(Unknown Source)</p><p><strong>Cause:</strong></p><ul><li><p>In X-Notify/xml/Initialisation.xml, the Notifiers element children might be configured as follows (note the highlighted lines):</p><div class="codebox"><pre><code>  &lt;Notifiers&gt;
    &lt;EMail id=&quot;EMail&quot;&gt;
      &lt;SmtpServer&gt;127.0.0.1&lt;/SmtpServer&gt;
      &lt;FromAddress&gt;from@company.co.za&lt;/FromAddress&gt;
      &lt;SmtpAuthentication&gt;
        &lt;Basic Username=&quot;username@company.co.za&quot; Password=&quot;mypassword&quot;/&gt;
      &lt;/SmtpAuthentication&gt;
      &lt;SmtpPort&gt;25&lt;/SmtpPort&gt;
    &lt;/EMail&gt;
	
    &lt;XDec id=&quot;XDec&quot;/&gt;
	
  &lt;/Notifiers&gt;</code></pre></div></li><li><p>Below the Notifiers element is the ApplicationGroups element, which is where the cause of the problem is located (see highlighted line):</p><div class="codebox"><pre><code> &lt;ApplicationGroups&gt;
   &lt;ApplicationGroup applicationName=&quot;MyTest&quot;&gt;
      &lt;NotificationGroup name=&quot;Heartbeat Failure&quot;&gt;
	  
        &lt;XDec notifier=&quot;EMail&quot;&gt;
		
          &lt;Destination&gt;127.0.0.1&lt;/Destination&gt;
          &lt;ESMTool&gt;ServiceBroker&lt;/ESMTool&gt;
          &lt;MD&gt;ServiceBroker1&lt;/MD&gt;
          &lt;Agent_Class&gt;X-ServiceBroker&lt;/Agent_Class&gt;
          &lt;Agent_Instance&gt;X-ServiceBroker&lt;/Agent_Instance&gt;
          &lt;Instance_Detail&gt;X-ServiceBroker&lt;/Instance_Detail&gt;
          &lt;Server&gt;ServiceBroker1&lt;/Server&gt;
          &lt;Client&gt;ACME&lt;/Client&gt;
          &lt;Source&gt;ServiceDesk&lt;/Source&gt;
        &lt;/XDec&gt;
      &lt;/NotificationGroup&gt;
    &lt;/ApplicationGroup&gt;
  &lt;/ApplicationGroups&gt;</code></pre></div></li><li><p>Effectively this means that we want to create an <strong>XDEC</strong> document using the <strong>EMAIL</strong> Notifier plugin, which is not possible. An XDEC document can only be created by using an XDEC Notifier plugin. The same applies to all Notifier plugins.</p></li></ul><br /><br /><p><strong>Resolution:</strong></p><ul><li><p>Change the ID in the affected ApplicationGroup config to reflect the correct Notifier ID:</p><br /><div class="codebox"><pre><code> &lt;ApplicationGroups&gt;
   &lt;ApplicationGroup applicationName=&quot;MyTest&quot;&gt;
      &lt;NotificationGroup name=&quot;Heartbeat Failure&quot;&gt;

        &lt;XDec notifier=&quot;XDec&quot;&gt;

          &lt;Destination&gt;127.0.0.1&lt;/Destination&gt;
          &lt;ESMTool&gt;ServiceBroker&lt;/ESMTool&gt;
          &lt;MD&gt;ServiceBroker1&lt;/MD&gt;
          &lt;Agent_Class&gt;X-ServiceBroker&lt;/Agent_Class&gt;
          &lt;Agent_Instance&gt;X-ServiceBroker&lt;/Agent_Instance&gt;
          &lt;Instance_Detail&gt;X-ServiceBroker&lt;/Instance_Detail&gt;
          &lt;Server&gt;ServiceBroker1&lt;/Server&gt;
          &lt;Client&gt;ACME&lt;/Client&gt;
          &lt;Source&gt;ServiceDesk&lt;/Source&gt;
        &lt;/XDec&gt;
      &lt;/NotificationGroup&gt;
    &lt;/ApplicationGroup&gt;
  &lt;/ApplicationGroups&gt;</code></pre></div></li></ul>]]></description>
			<author><![CDATA[dummy@example.com (SeanR)]]></author>
			<pubDate>Wed, 21 Nov 2018 08:58:30 +0000</pubDate>
			<guid>https://www.xlayer.co.za/forum/viewtopic.php?pid=30#p30</guid>
		</item>
	</channel>
</rss>
