Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / March 2007

Tip: Looking for answers? Try searching our database.

want to read messages from queue

Thread view: 
gk - 19 Mar 2007 14:31 GMT
I have a JMS Server in weblogic server . it has a queue in it . i want
to read the message count  in queue .

so,
I want to write a program which will read

1. messages pending
2. Total Message

from the queue

How do i start ?

from a priliminary guess , i have to do with MBean ...is it true ? can
anybody push me to the right direction ?

any link /ideas are appreciated
gk - 21 Mar 2007 08:11 GMT
somebody ?  anybody ?

is my question not understandable ? i want to read  the number of
messages in a queue  in weblogic server .....this is the question .

> I have a JMS Server in weblogic server . it has a queue in it . i want
> to read the message count  in queue .
[quoted text clipped - 13 lines]
>
> any link /ideas are appreciated
hvt - 21 Mar 2007 11:24 GMT
> somebody ?  anybody ?
>
[quoted text clipped - 5 lines]
>
> > so,

> > from the queue
>
[quoted text clipped - 4 lines]
>
> > any link /ideas are appreciated

> > I want to write a program which will read
>
> > 1. messages pending
> > 2. Total Message

Total number of messages in the queue can be found using
queue.browse() method. This method basically reads the queue without
deleting values from the queue as deletion happens with
queue.receive() message. browsing the queue might be helpful to
determine the queue length though this approach is feasible for
smaller (and fixed length) queues where there is not much overhead
timing vise.

I don't understand what do you mean by messages pending! as only
measurable thing in JMS Queue in number of messages contained. If you
mean that messages pending are those which are waiting to be written
into the fixed-length-queue, I don't 've exact answer to this as it
will depend upon how insertion functionality works.
Note: queue is an instance of Weblogic's JMS Queue implementation.

Also Weblogic's console provide JMS Monitoring page where you can see
number of messages present in the queue plus some other details.

With Regards
gk - 22 Mar 2007 07:23 GMT
> I don't understand what do you mean by messages pending! as only
> measurable thing in JMS Queue in number of messages contained. If you
[quoted text clipped - 7 lines]
>
> With Regards

ok.

How do see message queue in weblogic ?

you first login

go to JMS

choose the queues >Mionitor the queues

when you see the queues , you find  table with columns  , message
received, messace pending etc etc.

I want to get all those  values programmatically
kvasani - 25 Mar 2007 15:05 GMT
> > I don't understand what do you mean by messages pending! as only
> > measurable thing in JMS Queue in number of messages contained. If you
[quoted text clipped - 22 lines]
>
> I want to get all those  values programmatically

Have a look at weblogic server documentation (appropriate to your
version).
>From Version 7 onwards, they have concept of MBeans, which gets
created for each component running on server, including JMS/EJB/Web
application etc.

All you need to do is find correct MBean, & monitor it's state.

KV
blmblm@myrealbox.com - 21 Mar 2007 21:09 GMT
> somebody ?  anybody ?
>
> is my question not understandable ? i want to read  the number of
> messages in a queue  in weblogic server .....this is the question .

I notice that you did get a reply later, but a thought about how
to do better another time, maybe:  If your question is specific
to JMS / Weblogic (and I can't really tell since I don't know
anything about either of these), maybe it would help to put that in
the subject line -- "read messages from JMS server" or something.
That way people who don't read all the threads but have the right
background to answer your question would be more likely to notice it.

> > I have a JMS Server in weblogic server . it has a queue in it . i want
> > to read the message count  in queue .
[quoted text clipped - 13 lines]
> >
> > any link /ideas are appreciated

Signature

B. L. Massingill
ObDisclaimer:  I don't speak for my employers; they return the favor.



Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.