You should try to debug and see why the NullPointerException is
thrown from your code. If the problem comes from a null
ComponentContext, the reason would be that you are trying to
send exchanges before the component has been fully initialized.
In such a case, you would need to ensure that the quartz engine
is not started before the component itself is started.
On 10/13/06, bhuvi <[EMAIL PROTECTED]> wrote:
hi all
i wrote a quartz component that would trigger a class.This class must
send some messge to another bindingcomponent.So can i have my InOnly &
NormalizedMessage in a seperate method other than onMessage() or
onMessageExchange() in that class.I tried that but i have the following
exception.
18:28:10,039 ERROR [JobRunShell] Job 1.LogTime threw an unhandled Exception:
java.lang.NullPointerException
at test.service.ServiceEngine.normMsg(ServiceEngine.java:71)
at test.service.ServiceEngine.execute(ServiceEngine.java:58)
at org.quartz.core.JobRunShell.run(JobRunShell.java:195)
at
org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:520)
18:28:10,039 ERROR [ErrorLogger] Job (1.LogTime threw an exception.
org.quartz.SchedulerException: Job threw an unhandled exception. [See nested
exception: java.lang.NullPointerException]
at org.quartz.core.JobRunShell.run(JobRunShell.java:206)
at
org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:520)
* Nested Exception (Underlying Cause) ---------------
here is my method that sends msg to bindingcomponet
public void normMsg()throws MessagingException{
try{
String Xml="hai";
ComponentContext ctx= getContext();
System.out.println(Xml);
InOnly messageExchange =
ctx.getDeliveryChannel().createExchangeFactory().createInOnlyExchange();
NormalizedMessage inMessage = messageExchange.createMessage();
ServiceEndpoint destination = null;
resolver = new ServiceNameEndpointResolver( new
QName("http://servicemix.org/example/", "mechspec"));
--
View this message in context:
http://www.nabble.com/abt-InOnly...-tf2436899.html#a6795176
Sent from the ServiceMix - User mailing list archive at Nabble.com.
--
Cheers,
Guillaume Nodet