Messages remain in Queue Table

Hello,
I work as a dba in a company where my colleagues are developing an application that uses AQ.
The application is installed on multiple databases but we have a problem in a particular one:
the processed messages are not deleted from table by Oracle.
DBMS_AQADM.CREATE_QUEUE( Queue_name => 'my_AQ', Queue_table => 'AQT', Queue_type => 0, Max_retries => 65535, Retry_delay => 0, Retention_time => 2592000, dependency_tracking => FALSE);
SELECT msg_state, count(*) FROM AQT GROUP BY msg_state;
PROCESSED     830548
SELECT min(enq_time),max(enq_time) FROM AQT
07-OCT-10      01-AUG-12
SELECT value FROM v$parameter WHERE name='aq_tm_processes'
10
thanks,

Hi,
I didn't notice this in your first post:
DBMS_AQADM.CREATE_QUEUE(
    Queue_name => 'my_AQ',
    Queue_table => 'AQT',
    Queue_type => 0,
    Max_retries => 65535,
    Retry_delay => 0,
    Retention_time => 2592000,      <<<<<<<<<< why are you specifying such a high value for this?
    dependency_tracking => FALSE
);Retention_time: See doc for this value: http://docs.oracle.com/cd/E11882_01/server.112/e11013/aq_admin.htm#i1006091
This parameter specifies the number of seconds a message is retained in the queue table after being dequeued from the queue. When retention_time expires, messages are removed by the time manager process. INFINITE means the message is retained forever. The default is 0, no retention.
You are asking for messages to be retained for 30 days, now looking at the min/max enq_time you have messages which are much older than this, but did you check when they were actually DQ'd (DEQ_TIME)?
Also, from my previous post, did you check out that MOS note ? Did you check what the Q00 processes are doing in the database?
Thanks
Paul

Similar Messages

  • Messages remained in queue - deferred

    NMS 4.15/patched.
    Any local domain user who has Email forwarded to a non-local domain is not receiving the forwarded Email.
    The NMS message queue is stacked up with thousands of messages for remote hosts.
    The queue is set for 1 minute retries for 3 days.
    PROCESSQ does not cause delivery.
    A test was setup with a non-local host, and the NMS 4.15 server never even contacts the remote host for delivery. BIND is running on the same machine and NSLOOKUP resolves remote hosts fine.
    Prior to this, all was working fine. We had to reinstalled NMS 4.15 and reload the LDAP database due to a corrupted disc. The same configuration was used.
    This sounds like a DNS issue whereby NMS is not finding an entry for the non-local host MX, however, the DNS used on the server (which has one IP address) resolves everything just fine.
    Any help appreciated !
    Thanks - Ado

    (1) There are four entries for SMTP routing which affect domains which we are MX backup for. I am not concerned with any Email on these domains at the moment.
    (2) Below is the test message which came into a local account which is forwarded. The local NMS account receipient got the message.
    The SMTP server for the forwarded recipient (@thepilotshop.us) is sitting right next to me, and NMS has never made a connection to it.
    Again, DNS resolves MX fine on that domain using the NMS server NSLOOKUP
    The same is true for 1,500+ forwards to @aol.com and others well-known domains.
    Envelope Contents:
    743
    Message-Id: HUOLPW01.E04
    Parent: 0
    Header-Size: 1413
    Body-Size: 719
    Header-Flush: 0
    Function: SMTP-Deliver
    Control-Type: Mail
    Priority: 2
    Submitted-Date: Tue, 16 Mar 2004 12:22:44 -0600
    MIME-Encoding: 7BIT
    Host-From: mailproxy.stl-net.net [65.127.236.34]
    User-From: SMTP<[email protected]>
    Message-Size: 2132
    MTA-Hops: 2
    Received-From-MTA: dns; mailproxy.stl-net.net (65.127.236.34)
    MAIL-Exts: RET=HDRS
    Trace: SMTP-Accept
    Trace: Account-Handler
    Trace: SMTP-Router
    Trace: SMTP-Deliver
    Account-To! repcogchatten
    Deliver-To! Mailbox repcogchatten
    Host-To: thepilotshop.us
    Channel-To: SMTP <[email protected]>
    RCPT-Exts:
    Remote-MTA: DNS;thepilotshop.us
    Last-Delayed-DSN-Date: Tue, 16 Mar 2004 12:22:44 -0600
    743
    Message-Id: HUOLYX01.204
    Parent: 0
    Header-Size: 1412
    Body-Size: 719
    Header-Flush: 0
    Function: SMTP-Deliver
    Control-Type: Mail
    Priority: 2
    Submitted-Date: Tue, 16 Mar 2004 12:28:09 -0600
    MIME-Encoding: 7BIT
    Host-From: mailproxy.stl-net.net [65.127.236.34]
    User-From: SMTP<[email protected]>
    Message-Size: 2131
    MTA-Hops: 2
    Received-From-MTA: dns; mailproxy.stl-net.net (65.127.236.34)
    MAIL-Exts: RET=HDRS
    Trace: SMTP-Accept
    Trace: Account-Handler
    Trace: SMTP-Router
    Trace: SMTP-Deliver
    Account-To! repcogchatten
    Deliver-To! Mailbox repcogchatten
    Host-To: thepilotshop.us
    Channel-To: SMTP <[email protected]>
    RCPT-Exts:
    Remote-MTA: DNS;thepilotshop.us
    Last-Delayed-DSN-Date: Tue, 16 Mar 2004 12:28:09 -0600
    It added the SMTP log DEBUG, and restarted the server. Below is the output from the startup, and the entry pertaining to the test Email to "@thepilotshop.us":
    [16/Mar/2004:16:24:49 -0600] smtp smtpd[272]: General Notice: listening on all interfaces port 29
    [16/Mar/2004:16:24:56 -0600] smtp smtpd[272]: General Warning: Netscape Messaging Server ESMTP 4.15 Patch 1 (built Mar 15 2000) starting up
    [16/Mar/2004:16:28:10 -0600] smtp smtpd[269]: General Notice: SMTP-Deliver:HUOLYX01.204:<[email protected]>:Deferred:thepilotshop.us:<[email protected]>:2133:1:<[email protected]>
    The oddity is that we installed from the exact same originals that we had been running onto a clean disc, with the same settings. The LDAP users were re-imported and that's it, and all was working fine before -:<>
    Any suggestions ?
    Thanks - Ado

  • Messages are in READY state in QUEUE TABLE but in AQ$ QUEUE TABLE messages are in PROCESSED State

    HI All,
       We create a brand new oracle multi-consumer queue. We have en-queued the messages into the queue and are processed successfully.
       But when we checked the STATE Column  of the messages in the queue table it was showing as "0". But it is showing as "PROCESSED" in the
       AQ$<QUEUE_TABLE> msg_state column.
      We are unable to figure out why there is a mismatch. Can any one help us ?
    Regards,
    Hari P.

    Hello,
    the column value AQ$<QUEUE_TABLE>.MSG_STATE = 'PROCESSED' corresponds to column value <QUEUE_TABLE>.STATE = 2
    (see definition of view AQ$<QUEUE_TABLE for the DECODE statement).
    In your case you see a value of STATE = 0 instead of STATE = 2. Is this correct ? The value 0 corresponds to a state "READY" (the delay
    is gone and the message is ready for dequeuing).
    The AQ documentation says: "After the specified delay, the message is in the READY state and available for dequeuing."
    Normally, you cannot see the processed data in your AQ because the enqueued data will be deleted after
    successful dequeuing. You wrote that they were processed successfully.
    Kind regards,
    WoG

  • Queue or Queue Table getting hanged

    Hi. I am having an interesting issue. The problem goes as below
    I have a queue table QT_PROMO_QUEUE and the associated queue Q_PROMO_QUEUE. This Queue has two agents QUEUE_AGENT1 and QUEUE_AGENT2.
    Suppose say i have enqueued one message into the this Q_PROMO_QUEUE, then if i have manually deleted(not purging) that message from the queue table QT_PROMO_QUEUE, then the queue is getting hanged. I am not able to perform any operations on the queue except enqueuing the new messages.
    I am not able to do below operations
    dequeuing the messages from the queue, stopping the queue, removing the subscribers from the queue, dropping the queue, or even purging the queue table, and dropping the queue table.
    Early replies are appreciated...Thanks in advance.

    when the Init is sucessfull in BW it initializes the DS in Delta Queue(RSA7) and if any of the documents gets posted they will come to update tables/extraction queue depends on the update mode you have selected in LO Cokpit. when you schedule the job control on LBWE - it transfer the delta records to RSA7

  • Replace message payload object without remove queue table

    hi,
    i want to replace message payload object without remove queue table but i have got the "ORA-02303: cannot drop or replace a type with type or table dependents" error.
    is there any way to replace message payload object without remove queue table?
    Click to link below to find a demo which is explain the problem clearly
    Replace message payload object without remove queue table
    Regards.

    Hi
    I answered this in Re: Replace message payload object without remove queue table forum.
    Cheers, APC

  • Edit message payload object without remove queue table

    Hi, need ur help again,
    Known that if we want to modify a message payload attribute (add,edit or delete), we will fail to do so if the message payload is used by existing AQ's queue table.
    How to change the message payload object without remove the queue table?
    Thanks!

    Hi
    I answered this in Re: Replace message payload object without remove queue table forum.
    Cheers, APC

  • Messages in Distributed Queue remain on one JMSServer in Cluster

    Hi,
              the situation is as follows:
              We're having Distributed Queues on a two-Node server setup. A queue therefore exists two times, once on each JMSServer on each node.
              Forward-Delay has been set on the DistibutedQueue to value 1 second (we tested with values 0 and 10, too).
              External Java client (both cluster nodes in the provider_url for initialcontext) connects to the DistributedQueue and sends messages. In the weblogic console you can see these messages on the physical queue on the JMSServer, let's call it QueueA on NodeA.
              An external java process to consume messages (again both clusters nodes in the jndi-connection-string) is started to consume messages. Because of round-robin it sometimes get's connections to QueueB (part of same DistributedQueue as QueueA, but on the other node in the cluster).
              When connected to QueueB on NodeB no single message is received. You can even see in the weblogic console that QueueA on NodeA has zero consumers and 50 messages, QueueB on NodeB has zero messages but one consumer.
              When we restart the consumer java process and it randomly get's connected to QueueA on NodeA it consumes fine, as it should.
              Should'nt Forward-Delay do exactly this? Transport messages from QueueA on NodeA with zero consumers to QueueB on NodeB which actually has consumers?
              Any help would be appreciated.
              Axel van Lil

    Hi,
              thanks for your answer. We opened a support case today for this issue... I don't know. Cluster seems to run fine, no warnings, no exceptions.
              The next step of this issue is the following (just to give an idea of our upcoming problems :-)
              External Java process listens on QueueA on NodeA (QueueA is part of a Distributed Queue). Currently receives all the messages located on that queue. We kill NodeA on that machine to simulate failover.
              The external process failovers immediately to NodeB (which is good! proven by netstat and debugger) but just doesn't receive messages even though there are messages in that queue! It seems that the new consumer is just being forgotten by the BEA server.
              I don't know... somehow our configuration is quirked... or the BEA implementation doesn't work at all...
              Rgds,
              Axel

  • Error while dropping/creating new queue table

    Hi,
    I am trying to modify an existing AQ setup. In the process, I had to remove a queue and redirect all its subscriptions to another queue.
    I get an oracle "sequence does not exist" while trying to drop the queue table. The sequence of operations that I am carrying out is:
    disable propagation schedule
    unschedule propagation
    stop queue
    drop queue
    drop queue table
    The error occurs when the drop statement is executed.
    I tried restoring the existing configuration, but got the same error message while trying to add a subscription.
    Could you help me with this problem? What am I missing here?
    Thanks,
    Anupama

    In what version of Oracle?
    I see a couple of problems assuming you are working with a currently supported version:
    1. Never grant CONNECT to anyone: Ever. Grant CREATE SESSION.
    2. GRANT CREATE TABLE to AQ;
    Go to Morgan's Library at www.psoug.org and look at AQ Demo 1. You should have no problem cutting and pasting your way to where you are trying to go.

  • Is this the best design for asynchronous notifications (such as email)? Current design uses Web Site, Azure Service Bus Queue, Table Storage and Cloud Service Worker Role.

    I am asking for feedback on this design. Here is an example user story:
    As a group admin on the website I want to be notified when a user in my group uploads a file to the group.
    Easiest solution would be that in the code handling the upload, we just directly create an email message in there and send it. However, this seems like it isn't really the appropriate level of separation of concerns, so instead we are thinking to have a separate
    worker process which does nothing but send notifications. So, the website in the upload code handles receiving the file, extracting some metadata from it (like filename) and writing this to the database. As soon as it is done handling the file upload it then
    does two things: Writes the details of the notification to be sent (such as subject, filename, etc...) to a dedicated "notification" table and also creates a message in a queue which the notification sending worker process monitors. The entire sequence
    is shown in the diagram below.
    My questions are: Do you see any drawbacks in this design? Is there a better design? The team wants to use Azure Worker Roles, Queues and Table storage. Is it the right call to use these components or is this design unnecessarily complex? Quality attribute
    requirements are that it is easy to code, easy to maintain, easy to debug at runtime, auditable (history is available of when notifications were sent, etc...), monitor-able. Any other quality attributes you think we should be designing for?
    More info:
    We are creating a cloud application (in Azure) in which there are at least 2 components. The first is the "source" component (for example a UI / website) in which some action happens or some condition is met that triggers a second component or "worker"
    to perform some job. These jobs have details or metadata associated with them which we plan to store in Azure Table Storage. Here is the pattern we are considering:
    Steps:
    Condition for job met.
    Source writes job details to table.
    Source puts job in queue.
    Asynchronously:
    Worker accepts job from queue.
    Worker Records DateTimeStarted in table.
    Queue marks job marked as "in progress".
    Worker performs job.
    Worker updates table with details (including DateTimeCompleted).
    Worker reports completion to queue.
    Job deleted from queue.
    Please comment and let me know if I have this right, or if there is some better pattern. For example sake, consider the work to be "sending a notification" such as an email whose template fields are filled from the "details" mentioned in
    the pattern.

    Hi,
    Thanks for your posting.
    This development mode can exclude some errors, such as the file upload complete at the same time... from my experience, this is a good choice to achieve the goal.
    Best Regards,
    Jambor  
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • Error while sending the messages to JMS Queue

    Hi ,
    I am trying to pick the file from JMS Queue and send the response xml as outbound message to JMS Queue again using XAI Sender
    I Created XAI Sender, Outbound Message Type(DM-RCVRESP) and configured these two with External System.
    I am able to pick the file from JMS Queue but unable to send the message through XAI Sender (Real-time)
    Plz find below the error trace getting.
    [Wed Jun 15 16:12:09 IST 2011] Error while processing sender "UPLOADSTG" : Unable to update response in staging table: Row id not given.
    com.splwg.mpl.sending.SameThreadSendingManager$ProcessException
         at com.splwg.mpl.sending.SameThreadSendingManager.processDestination(SameThreadSendingManager.java:341)
         at com.splwg.mpl.sending.SameThreadSendingManager.sendResponse(SameThreadSendingManager.java:293)
         at com.splwg.mpl.sending.SameThreadSendingManager.doSend(SameThreadSendingManager.java:249)
         at com.splwg.mpl.server.async.ExecSendRequestProcessor.ProcessRequest(ExecSendRequestProcessor.java:61)
         at com.splwg.mpl.server.async.RequestProcessingThreadAdapter.run(RequestProcessingThreadAdapter.java:46)
         at com.splwg.mpl.server.PooledThread.run(PooledThread.java:91)
         at java.lang.Thread.run(Thread.java:662)
    Please guide me in this regard..
    Thanks,
    sukumar

    What have you configured for the response tab for the sender? Are you using the MPL or the MDB?
    Take a look at:
    MPL Best Practices (Doc Id 1308165.1)
    Oracle WebLogic JMS Integration (Doc Id: 1308181.1)

  • JMS messages stuck in queue in weblogic v923 cluster

    Hi all,
    Enviornment details:
    In our pre-production weblogic v923 cluster enviornment with Oracle 10g database, there are 10 server boxes with 2 managed nodes running on each server box in linux enviornment.
    There are 3 JMS queues and 1 error queue per managed node.
    All the queues are durable and the persitence store is a database table. There is a single database table per single managed node.
    High loads of JMS messages from client applications coming on each of the 3 JMS queue are processed by the cluster on daily basis.
    The JMS messages that failed to be processed the very first time due to the application logic exceptions are put on error queue since the retry is set to zero on the non-error queue.
    The application exceptions are logged to a database table for futher reference.
    The falied messages from the error queue are read by spring based MDP and resent to the application for reprocessing.
    If no application exceptions, the message will be persisted in a relational database; in the case of failures, MDP code puts the failed message back on to the error queue.
    The auto_ack is true on the JMS message.
    It is observed about less than 1% of the messages fail the original processing and are in error queue on daily basis.
    99.9% of the time, the reprocessing of the messages from the error queue is a success.
    Currently due to some obvious reasons, the system administrator stops a managed node when the disk is full and start a different managed node on the same server box. This approach will be stopped in the very near future so that all nodes on all servers are running at any point of time by making few enviornment changes.
    Problem:
    1a) Occasionally, it is observed that 1 - 4 JMS messages are stuck in the error queue. There are no signs of reprocessing as there are no application exceptions or the corresponing insert into the database. The JMS persistence store table still has the JMS message.
    1b) It is observed that over time, the same JMS messages that were originally stuck on server 1's managed node A are no longer there but are found in a different node (say node B) on a different server box.
    As far as I understand the JMS, a message could be in a Pending state if MDP (in my case) does not automatically send ACKNOWLEGMENT back due to an issue in the Spring Defaultlisternercontainer before calling MDP's onMessage(). I am not sure as what happens to that status over time).
    It is also observed that the stuck messages content is not much different than the other messages that are processed fine.
    Any pointers/input is highly appreciated.
    Thanks in advance for your valuable input and time.

    Off the top of my head, I can only think of two reasons why a message might move from node to node:
    (A) An application is dequeueing them and enquening them elsewhere.
    (B) The application is using distributed queues, and the distributed queue has been configured to enable "queue forwarding". The forwarding feature automatically moves messages from distributed queue members that have no consumers to members that do have consumers. Queue forwarding is sometimes enabled as a work-around to better enable MDP support of WL distributed destinations, unlike WebLogic MDBs, MDPs have no container logic to ensure that all members of a distributed destination are serviced by a consumer under all circumstances...
    Regards,
    Tom

  • Messages remain in Scheduled status in message monitoring in RWB

    Hi PI experts,
    I have got a situation where there are several messages showing in the Scheduled status. I followed the path RWB > Message Monitoring > Adapter Engine > Database (Overview) > Display.
    QoS for these messages is EOIO, however there are no messages stuck in the queue. All other channels are running smoothly. Only with this particular channel the messages remain in Scheduled status for a long time.
    I am neither able to make out the roor cause nor reprocess/resend these messages. Pleaes help.
    Regards,
    Dhawal

    Hi Suraj,
    What you said is absolutely correct. However, as I mentioned, the error message was not visible in RWB.
    My problem just got resolved. What I did is this,
    I followed the link http://<server>:<port>/MessagingSystem/monitor/monitor.jsp which is SAP Message Display Tool.
    Here in EOIO Sequence Monitor I found the error message and it's predecessor. When I resent the erroneous message from here, all subsequent Holding messages got processed.
    Thank you everyone for your help. Have a gr8 day...
    Best Regards,
    Dhawal

  • Messages Stuck in Queue in PI

    Hi,
    For a few inbound interfaces for which PI is the middleware, we have found that the messages are stuck in queue in PI. We have also found that the messages are stuck in the queue in PI because one message which has an RFC error (It does a RFC lookup from PI into R/3).
    Is there any way in which we can trigger the RFC lookup manually for the failed message in the queue in PI?
    If this is not the right forum, please let me know the correct forum.
    Thanks in advance.
    Mick

    Hi,
    We can prevent this problem through standard SAP program RSQIWKEX.  This program need to execute background.  Whenever any message stuck in queue automatically this problem will restart error message automatically.  If you want to delete error message from queue (due to this error message remaining messages are in hold stage.  for remaining message execution we need to delete error message from queue) we need to change one function in this probem.
    Existing function TRFC_QIN_RESET_LUW , this function only can restart error message.
    Need to add function TRFC_QIN_DELETE_LUW , this function delete error message from queue.
    For this program execution we need to mentioned queue name(mandatory), find message stucking queue name and give same name to program in variant.
    I hope now clear

  • Messages stuck in queue AFWRecv of Adapter Framework

    Hello,
    Messages stuck in queue AFWRecv of Adapter Framework in our production system(trace in  RWB: "to be delivered")
    in URL http://xxxxxxx:50000/MessagingSystem/monitor/systemStatus.jsp we can see:
    Queue Info 
    Queue Name isStarted QueueSize ThreadCount (working) MaxThreads
    AFWCall true 0 0 (0) 20
    AFWRecv true 954 10 (10) 10
    AFWRqst true 0 0 (0) 20
    AFWSend true 0 0 (0) 10
    We have tried to resend the first message but that´the result:
    Time Stamp Status Description
    2010-10-09 11:24:06 Success The message was successfully received by the messaging system. Profile: XI URL: http://xxxxxxxxx:8100/MessagingSystem/receive/AFW/XI
    2010-10-09 11:24:06 Success Using connection AFW. Trying to put the message into the receive queue.
    2010-10-09 11:24:06 Success Message successfully put into the queue.
    2010-10-11 00:01:46 Success Recovering from loss of connection to database; message loaded into queue by recover job: System Job (Failover Recovery)
    2010-10-11 02:48:16 Success System Startup: Message successfully loaded into queue: AFWRecv.
    2010-10-13 11:03:19 Success Admin action: Trying to redeliver message.
    2010-10-13 11:03:46 Success Admin action: Trying to redeliver message.
    Since then it stucks there...
    Any help would be apreciated....

    Hi,
    Go to the runtime workbench --> Message Monitoring --> Click on the 'Configure Table Columns' > Check Sequence ID, Serialization Context & Sequential Number options.> and then click 'Apply'.
    Then in the 'Serialization Context' column you will get the queue ID for the stcuk message.
    Take that value and click on the 'Show additional Criteria' option on the top and put this value in the 'Serialization context' parameter. Also,select the start/end date as 'This year' --> start.
    You will get all the messages stuck in that particular queue for this yoear, try to rectify them, so that your message will be processed.
    -Supriya.

  • Messages in Buffered queue not beeing applied

    Hi All,
    Im running a streams environment. The receiving server crashed and was restarted. The apply process was restarted and the buffer was flooded with messages. Flow control initiatied on the sending database. The apply process doesn't show errors, but there are 5001 messages in the queue that arn't beeing applied. I' ve tried restarting the apply process and increased the number of parallel apply processes. Purging the queue doesn't seem like a good idea since the I will loose data. What can I do?
    btw The messages in de queue seem to be in defered state. I dont know if this is of any importance...
    Another thing that struck me as odd was the following:
    Coordinator Low Watermark: 11063412548
    Reader Oldest SCN: 11063412382
    I would assume the Oldest SCN would be equal or higher that the Coordinator low watermark because messages are first beeing read, then coordinated then applied right?
    and while I' m at it: it is no longer possible to disable the queue from Grid Control. If I try to, what happens is, that the status becomes disabled (red downward arrow) but the state remains:"DEQUEUEING MESSAGES"
    kind regards,
    Erik
    Edited by: erikros on Apr 28, 2010 2:47 PM
    Edited by: erikros on Apr 28, 2010 3:05 PM
    Edited by: erikros on Apr 28, 2010 3:08 PM

    Query 1
    APPLY_NAME : P_APP1
    Latency in Seconds : 29139
    Message Creation : 2010-04-27 14:48
    Apply Time : 2010-04-27 22:54
    APPLIED_MESSAGE_NUMBER : 11063412548
    Query 2
    CAPTURE_NAME : P_CAP1
    STATE : PAUSED FOR FLOW CONTROL
    CAPTURE_TIME : 2010-04-29 07:41
    CAPTURE_MESSAGE_NUMBER : 11063460122
    CAPTURE_MESSAGE_CREATE_TIME : 2010-04-27 14:55
    ENQUEUE_TIME : 2010-04-29 07:41
    ENQUEUE_MESSAGE_NUMBER : 11063460122
    ENQUEUE_MESSAGE_CREATE_TIME : 2010-04-27 14:55
    AVAILABLE_MESSAGE_NUMBER : 11076534248
    The second query had some fields in it that weren't supported by my version of Oracle 10.2. I replaced them with some others....
    Edited by: erikros on Apr 29, 2010 8:24 AM

Maybe you are looking for