Home » Developer & Programmer » Precompilers, OCI & OCCI » OCI client do not receive notification upon successful registration (Continuous Query Notification) (Oracle 11gR2)
OCI client do not receive notification upon successful registration (Continuous Query Notification) [message #493418] Mon, 07 February 2011 17:47 Go to next message
oraswen
Messages: 3
Registered: February 2011
Junior Member
Hello all,

I am trying to understand on how ORACLE Continuous Query Notification works. I used the sample code from the ORACLE site:

//download.oracle.com/docs/cd/B28359_01/appdev.111/b28395/oci10new.htm#LNOCI13111

(I can not add the proper link here since I have not post more than 5 messages)

and also created employees and departments table under my schema.

When I executed the sample code. I received an error

"ORA-24912: Listener thread failed. Failed to get IP address of host." that was generated from OCISubscriptionRegister.

Upon setting the client IP address through calling OCIAttrSet, the client can register successfully. I can see the registration entry in USER_CHANGE_NOTIFICATION_REGS.

I tried to trigger the notification by updating employee table as recommended. However, the client never received the notification.

Is there a way to check if the server created notification and tried to send it out to the client?

I attached the code with modification to set IP address attribute for subscription.


Thanks,

swen
  • Attachment: demoq.txt
    (Size: 20.15KB, Downloaded 2034 times)
Re: OCI client do not receive notification upon successful registration (Continuous Query Notificati [message #493452 is a reply to message #493418] Tue, 08 February 2011 01:33 Go to previous messageGo to next message
Michel Cadot
Messages: 68625
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
ORA-24912: Listener thread failed. %s
 *Cause: Thread listening for event notification exited because of an error.
         The error encountered is appended to the error message.
 *Action: The client needs to be restarted.

Regards
Michel
Re: OCI client do not receive notification upon successful registration (Continuous Query Notificati [message #493558 is a reply to message #493452] Tue, 08 February 2011 11:49 Go to previous messageGo to next message
oraswen
Messages: 3
Registered: February 2011
Junior Member
Thanks for the reply.

What does it mean by client needs to be restarted?

Does it mean the the application needs to be restarted?

I have restarted the application several times and the issue persisted. I got around ORA-24912 by setting the IP address attribute before calling OCISubscriptionRegister. However, I don't get the notification when I did DML operation on the registered tables.

My sample application uses oracle instant client 11.2.0.2.0 to connect to the server.

My database server is running oracle 11.2.1.0.

The sample application was running on Centos 5.5.

The application user has already had CHANGE_NOTIFICATION privilege. The database server's DML_LOCKS and JOB_QUEUE_PROCESSES are also set to non zero values. However, the notification never reached to the client or never got generated on the server side.

Is there a way to check if the server side generated the notification?


Regards,

swen

Re: OCI client do not receive notification upon successful registration (Continuous Query Notificati [message #493561 is a reply to message #493558] Tue, 08 February 2011 12:22 Go to previous message
oraswen
Messages: 3
Registered: February 2011
Junior Member
Correction on my DB server. It is running ORACLE 11g Release 11.2.0.1.0
Previous Topic: SQLJ in NetBeans
Next Topic: Pro*C - how to compile with SQLCHECK when access to meta-information requires a SET ROLE
Goto Forum:
  


Current Time: Thu Mar 28 21:35:00 CDT 2024