Author |
Message
|
wmquser |
Posted: Thu Aug 05, 2010 3:09 am Post subject: Move messages from one queue to another |
|
|
Apprentice
Joined: 20 Aug 2008 Posts: 32
|
Hi,
I have a java application which reads from the queue and process the message. For large message the application fails, in spite of increasing the heap size. I would like to know if there is a way to move the message from one queue to another thru the java application without reading the message. Please advise.
Thanks in advance. |
|
Back to top |
|
 |
zpat |
Posted: Thu Aug 05, 2010 4:11 am Post subject: |
|
|
 Jedi Council
Joined: 19 May 2001 Posts: 5866 Location: UK
|
No, only MQGET and MQPUT can move a message.
There are plenty of utilities that can do this, MO71 for one. |
|
Back to top |
|
 |
Mr Butcher |
Posted: Thu Aug 05, 2010 6:02 am Post subject: |
|
|
 Padawan
Joined: 23 May 2005 Posts: 1716
|
on z/OS, there is a "move qlocal" command which then is performed by the queuemanager. _________________ Regards, Butcher |
|
Back to top |
|
 |
wmquser |
Posted: Thu Aug 05, 2010 6:04 am Post subject: |
|
|
Apprentice
Joined: 20 Aug 2008 Posts: 32
|
we are running the application on AIX, so we cant use that option. |
|
Back to top |
|
 |
Vitor |
Posted: Thu Aug 05, 2010 8:15 am Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
wmquser wrote: |
we are running the application on AIX, so we cant use that option. |
Time for a support pac then? _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
mvic |
Posted: Thu Aug 05, 2010 8:45 am Post subject: Re: Move messages from one queue to another |
|
|
 Jedi
Joined: 09 Mar 2004 Posts: 2080
|
wmquser wrote: |
For large message the application fails, in spite of increasing the heap size. |
How big is the message? |
|
Back to top |
|
 |
wmquser |
Posted: Thu Aug 05, 2010 11:36 pm Post subject: |
|
|
Apprentice
Joined: 20 Aug 2008 Posts: 32
|
the message is 300MB which is segmented into 50MBs. |
|
Back to top |
|
 |
mvic |
Posted: Fri Aug 06, 2010 2:10 am Post subject: |
|
|
 Jedi
Joined: 09 Mar 2004 Posts: 2080
|
wmquser wrote: |
the message is 300MB which is segmented into 50MBs. |
OK. And what is the failure you mentioned? |
|
Back to top |
|
 |
wmquser |
Posted: Fri Aug 06, 2010 3:10 am Post subject: |
|
|
Apprentice
Joined: 20 Aug 2008 Posts: 32
|
i am getting out of memory error. I have increased the java heap size to 2048 also, but the same error. |
|
Back to top |
|
 |
mvic |
Posted: Fri Aug 06, 2010 3:18 am Post subject: |
|
|
 Jedi
Joined: 09 Mar 2004 Posts: 2080
|
wmquser wrote: |
i am getting out of memory error. |
Then I guess your app is out of memory.
One has to assume there is more detail than this.. did you go digging for more information?
For example, a full exception printout, entries in MQ error logs (look in /var/mqm/errors for example), system event logs, etc. |
|
Back to top |
|
 |
wmquser |
Posted: Mon Aug 09, 2010 12:47 am Post subject: |
|
|
Apprentice
Joined: 20 Aug 2008 Posts: 32
|
Below is the exception logged when the application tries to get a message of 300mb (segmented into 50mb each) size. There is no MQ error log found for this error, as this is a application error.
JVMDUMP006I Processing Dump Event "systhrow", detail "java/lang/OutOfMemoryError" - Please Wait.
JVMDUMP007I JVM Requesting Snap Dump using '/Code/Snap0001.20100805.091919.1073274.trc'
JVMDUMP010I Snap Dump written to /Code/Snap0001.20100805.091919.1073274.trc
JVMDUMP007I JVM Requesting Heap Dump using '/Code/heapdump.20100805.091919.1073274.phd'
JVMDUMP010I Heap Dump written to /Code/heapdump.20100805.091919.1073274.phd
JVMDUMP007I JVM Requesting Java Dump using '/Code/javacore.20100805.091919.1073274.txt'
JVMDUMP010I Java Dump written to /Code/javacore.20100805.091919.1073274.txt
JVMDUMP013I Processed Dump Event "systhrow", detail "java/lang/OutOfMemoryError".
Exception in thread "main" java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:79)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:618)
at com.simontuffs.onejar.Boot.run(Boot.java:251)
at com.simontuffs.onejar.Boot.main(Boot.java:108)
Caused by: java.lang.OutOfMemoryError
at java.lang.StringCoding.decode(StringCoding.java:510)
at java.lang.StringCoding.decode(StringCoding.java:579)
at java.lang.String.<init>(String.java:165)
at java.lang.String.<init>(String.java:114) |
|
Back to top |
|
 |
mvic |
Posted: Mon Aug 09, 2010 1:38 am Post subject: |
|
|
 Jedi
Joined: 09 Mar 2004 Posts: 2080
|
There is no mention of "mq" in the exception stack, so no direct evidence of a problem inside MQ, or anything related to MQ. My guess would be a memory leak somewhere, possibly in your main routine. Do you ensure all data is freed when it has been processed? |
|
Back to top |
|
 |
wmquser |
Posted: Thu Aug 19, 2010 10:01 pm Post subject: |
|
|
Apprentice
Joined: 20 Aug 2008 Posts: 32
|
I could able to complete this, I am doing a get and checking the data length and without reading the data I am moving the message into backout queue. I could able to process large message now. |
|
Back to top |
|
 |
|