End Thread -- Urgent
Hi,
Let's said i have an applet that do a upload file. When clicking on the "upload" button, it starts to read a file and send each line to a serial port. And I have a "Cancel" button that I could click on durint the upload to cancel the upload...But the click on the "cancel" button is only performed after my upload end...
What should I do to performed the Cancel Upload during my upload session?
thx
just close the stream
Similar Messages
-
Need some help with threads, urgent!!
Hi I am really new to threads and I cannot figure out why the code below will not work. After my thread goes into a wait, it never wakes up. Can someone please help me? When stepping through the code, I get an invalid stack frame message as well. Thanks in Advance!!!
Colin
import java.io.*;
import java.util.*;
public class XMLInputCompression extends InputStream implements Runnable
private InputStream in;
private ByteArrayOutputStream baos = new ByteArrayOutputStream();
private boolean closed = false;
private boolean foundDTD = false;
private Vector elementsList = new Vector();
private Vector attributesList = new Vector();
private BufferedReader br = null;
private StringTokenizer st = null;
final static int BUFF_SIZE = 500;
final static String HEADER = "<?xml version=\"1.0\"?><!DOCTYPE Form SYSTEM ";
final static char CLOSE_ELEMENT = '>';
final static String END_ELEMENT = ">";
final static char START_ELEMENT = '<';
final static char START_ATTRIBUTE = '[';
final static String ATTLIST = "<!ATTLIST";
final String XMLTAG ="<?xml";
final String ELEMENTTAG = "<!ELEMENT";
public static void main(String[] args)
try
FileInputStream fis = new FileInputStream("c:/Dump.txt");
XMLInputCompression compress = new XMLInputCompression(fis);
int r = 0;
while(r != -1)
byte b[] = new byte[200];
r = compress.read(b);
System.out.println("r is: " + r);
if( r == -1)
compress.close();
}catch(Exception e)
e.printStackTrace();
} // end main
public XMLInputCompression(InputStream is) throws IOException
this.in = is;
baos.write(HEADER.getBytes());
new Thread(this).start();
public void run()
try
Vector elementNames = new Vector();
//Vector attributeNames = new Vector();
StringBuffer sb = new StringBuffer(BUFF_SIZE);
char c = (char)in.read();
switch (c)
case START_ELEMENT:
if (!foundDTD)
wakeUp(sb.toString().getBytes());
//populate the elements and atrributes vectors
FileInputStream fis = new FileInputStream("C:/form.dtd");
processDTDElements(fis);
foundDTD = true;
sb.setLength(0);
else
sb.append("<");
String element = (String)elementsList.get((int)in.read());
elementNames.addElement(element);
sb.append(element);
wakeUp(sb.toString().getBytes());
//baos.write(sb.toString().getBytes());
sb.setLength(0);
break;
case START_ATTRIBUTE:
sb.append("[");
sb.append(attributesList.get((int)in.read()));
wakeUp(sb.toString().getBytes());
//baos.write(sb.toString().getBytes());
sb.setLength(0);
break;
case CLOSE_ELEMENT:
wakeUp(sb.toString().getBytes());
//baos.write(sb.toString().getBytes());
sb.setLength(0);
sb.append(elementNames.get(0));
elementNames.remove(0);
sb.append(">");
break;
default:
sb.append(c);
synchronized (baos)
baos.notify();
System.out.println(" in run method*****");
}catch(Exception e)
e.printStackTrace();
} // end run
private void wakeUp(byte b[])
System.out.println(" in wakeup method*****");
synchronized (baos)
try
baos.write(b);
catch(Exception e)
System.out.println("exception caught");
e.printStackTrace();
baos.notify();
public boolean markSupported()
return false;
public int read(byte[] b1, int off, int len) throws IOException
return readData(b1, off, len);
public int read() throws IOException
return readData(null, 0, 1);
public int read(byte[] b1) throws IOException
return readData(b1, 0, b1.length);
private int readData(byte[] b1, int off, int len) throws IOException
String s = null;
while(true)
if (closed && baos.size() == 0)
return -1;
int size = baos.size();
if (baos.size() > 0) // Have at least one byte
if( b1 == null)
byte b[] = baos.toByteArray();
baos.reset();
baos.write(b, 1, b.length-1); // baos contains all data except b[0]
return b[0];
else
int minLen = Math.min(baos.size(), len);
//System.out.println(" baos contents are: " + baos.toString());
byte b[] = baos.toByteArray();
s = b.toString();
int length = baos.size() - minLen;
baos.reset();
baos.write(b, 0, length );
System.arraycopy(b, 0, b1, off, minLen);
return minLen;
try
synchronized (baos)
if (!closed)
baos.wait();
catch(java.lang.InterruptedException ie)
ie.printStackTrace();
}// end read data
private boolean hasMoreTokens()
String s = null;
try
if (br != null)
if (st == null || !st.hasMoreTokens())
// read in a line, create a st
s = br.readLine();
st = new StringTokenizer(s,"\n\r\t ");
}catch(Exception e)
e.printStackTrace();
return st.hasMoreTokens();
private String nextToken() throws Exception
String token = null;
if(st.hasMoreTokens())
token = st.nextToken();
}else
String s = br.readLine();
st = new StringTokenizer(s,"\n\r\t ");
token = st.nextToken();
return token;
private void processDTDElements(FileInputStream is)
try
// get the file desriptor from the input Stream
FileDescriptor fd = is.getFD();
// create a new buffered reader
br = new BufferedReader(new FileReader(fd));
boolean lookForEndTag=false;
boolean lookForEndAtt=false;
while (hasMoreTokens())
String token = nextToken();
if (lookForEndTag)
if (!token.endsWith(END_ELEMENT))
continue;
}else
lookForEndTag = false;
continue;
if (token.startsWith(XMLTAG))
lookForEndTag = true;
else if (token.startsWith(ELEMENTTAG))
token = nextToken();
if ( elementsList.indexOf(token)<0)
elementsList.addElement(token);
lookForEndTag = true;
else if (token.startsWith(ATTLIST))
String dummy = nextToken(); // discard element name
do
token = nextToken();
if (token.endsWith(">"))
break;
if (attributesList.indexOf(token)<0 )
attributesList.addElement(token);
token = nextToken();
if ( token.startsWith("CDATA") || token.startsWith("ID") )
token = nextToken();
if (token.equals("#FIXED "))
token = nextToken();
lookForEndAtt = token.endsWith(END_ELEMENT);
else if ( token.startsWith("(") )
do
token = nextToken();
}while ( token.indexOf (")") == -1);
token = nextToken();
lookForEndAtt = token.endsWith(END_ELEMENT);
} while (!lookForEndAtt);
}//end if
}//end while
}catch(Exception e)
e.printStackTrace();
}finally
try
br.close();
}catch(Exception e)
e.printStackTrace();
}// end process elements
public void close() throws IOException
closed = true;
synchronized(baos)
baos.notify();
}// end XMLinputCompression classYour problem probably has something to do with where you tell baos (or rather, the thread that it is in) to wait. You have:synchronized (baos)
if (!closed)
baos.wait();
}Which acquires a lock on baos, then tells its own thread to wait without ever relinquishing its lock on baos. So when your main method calls the read method, it hangs immediately when it tries to access baos because it is still locked. So what you're seeing is a basic deadlock condition.
Really, you're not gaining anything with your multithreading in this case. But that's a different issue. -
About the thread (urgent)
hi! everyone,
i have a very urgent problem on thred:
when run server program, UNIX says:"Exception in thread "main"
java.lang.NoClassDefDoundError: MonitorThread"!
plx help!
thanx very much!!
what is meaning of that waring message?
how to deal with it?check your classpath:
currently MonitorThread.class is not in your classpath if you got this message
marvinrouge -
RMI and Threading: Urgent, pls help!
Hi everyone,
I read the previous topics in multithreading but i'm still confused about how RMI works in this case.
I have a client server application with RMI where client runs some time-consuming executables on the server.
(i use Process proc = Runtime.getRuntime().exec(cmd...)...)
Basically I want to make sure that simultaneous requests from different clients execute concurrently, instead of waiting for each other to finish. So my questions are:
1) When mutiple clients are making remote calls, does RMI map each client request to separate thread and execute them simultaneously (if yes, does it have some limit on number of threads that can be created?);
Or will I have to take care of creating threads on the server side for each request myself? if the later is the case, how could I go about doing that?
2) What if all (or some of) the clients are connected from the same VM? How can I ensure that they get executed in different threads, concurrently. Could you pls direct me to ways of implementing it.
any help is greatly appreciated,
yulduz1) When mutiple clients are making remote calls, does RMI map each client request to separate
thread and execute them simultaneously (if yes, does it have some limit on number of threads
that can be created?); Yes, RMI takes care of launching a thread on each remote call. It actually maintains a pool of threads from which, a free thread is assigned a new request. From then on, you have different threads running in server VM (one per each client call).
Or will I have to take care of creating threads on the server side for each request myself? if the
later is the case, how could I go about doing that?No, you dont have to create any thread just for the purpose of handling a remote call.
2) What if all (or some of) the clients are connected from the same VM? How can I ensure that
they get executed in different threads, concurrently. Could you pls direct me to ways of
implementing it.You dont have to do anything extra for achieving this. It doesnt matter whether you are running clients in the same VM or different VMs. If you want concurrency on the client side, you have to make remote calls from different threads. The following code outlines the difference between concurrency and non-concurrency in client VM (and NOT server VM).
class CallerThread extends Thread {
public void run() {
remoteRef.callMethod();
public class Client {
... main() {
// these are not concurrent in client VM bcos the second call happens only after first one returns
remoteRef.callMethod1();
remoteRef.callMethod2();
CallerThread t1, t2;
// these two calls are concurrent on the client side as they're called from two different threads
t1.start();
t2.start();
}regds,
CA -
hi all,
i have an application which forks out one or more threads.now if in between i need to save information and close down one thread what do i do.There are many ways to keep a reference to your Threads. You can use an array, a Collection, or in the code below, I hold a reference to the Threads in a DefaultListModel, which is used by a JList to show the Threads that are running.
import java.awt.FlowLayout;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import javax.swing.DefaultListModel;
import javax.swing.JButton;
import javax.swing.JFrame;
import javax.swing.JList;
import javax.swing.JScrollPane;
public class App extends JFrame {
public static int NUMBER_OF_PIPES = 5;
private JList list;
private DefaultListModel model = new DefaultListModel();
public App() {
this.list = new JList(this.model);
JScrollPane scrollList = new JScrollPane(this.list);
JButton startButton = new JButton("Start");
JButton stopButton = new JButton("Stop");
this.getContentPane().setLayout(new FlowLayout());
this.getContentPane().add(startButton);
this.getContentPane().add(stopButton);
this.getContentPane().add(scrollList);
startButton.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent e) {
startPipelines();
stopButton.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent e) {
stopSelectedPipelines();
public void startPipelines() {
for (int j = 0; j < NUMBER_OF_PIPES; j++) {
Pipeline pipeline = new Pipeline("Pipe" + j);
this.model.addElement(pipeline);
pipeline.start();
public void stopSelectedPipelines() {
Object[] pipelines = this.list.getSelectedValues();
for (int j = 0; j < pipelines.length; j++) {
((Thread) pipelines[j]).interrupt();
this.model.removeElement(pipelines[j]);
public static void main(String[] args) {
JFrame app = new App();
app.pack();
app.setVisible(true);
app.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
public class Pipeline extends Thread {
private String name;
public Pipeline(String n) {
this.name = n;
public void run() {
while(!Thread.interrupted()) {
try {
//do something here
System.out.println(this.name);
Thread.sleep(500); // or yield();
} catch (InterruptedException e) {
this.interrupt();
public String toString() {
return this.name;
} -
Hi,
I am not sure i am posting this in the correct area. Please bear and advice.
My application needs to run a thread contiuously for every 1 hr. I have made the coding in servlet as
package invservlet;
import javax.servlet.*;
import javax.servlet.http.*;
import java.io.IOException;
import java.util.Timer;
import java.util.TimerTask;
import java.util.Date;
import java.util.Calendar;
import sample.Reminder;
public class SampleReminder extends HttpServlet{
Timer timer;
Date date=new Date();
Calendar calc=Calendar.getInstance();
public void init(){
timer = new Timer();
timer.schedule(new Reminder(),calc.getTime(),1*1000*60*60);
public void doService(HttpServletRequest request,HttpServletResponse response) throws ServletException,IOException{
public void destroy(){
timer.cancel();
super.destroy();
and the execution file is
package sample;
import java.util.TimerTask;
import java.util.Date;
import box.util.SendMail;
public class Reminder extends TimerTask{
SendMail sendMail=new SendMail();
public void run() {
taskBody();
public void taskBody()
try{
sendMail.SendMail("192.168.0.33","[email protected]","[email protected]","","","Test log mail","This is a test mail for every 1 hour"+new Date());
}catch(Exception e){System.out.println("ERROR IN Remainder");}
BUT EVERY 2 - 3 DAYS I AM GETTING MY TOMCAT HANGING. I THINK THE PROBLEM IS IN THE THREAD. PLEASE ADVICE. THANKS.Sorry, forget to add some more points which may help for analysation.
My application will fetch more than 1000 records for single transaction.
And also some times in will be transferred (sendRedirect) to another page with nearly 20 fields of data.
Will this also create problem? -
HI SAP Gurus
we are going to apply SAP notes , today do i need any furthur configuration required for that or SPS will already configured, plese help me out
thank you in advanceHello Goutham,
Kindly clarify whether you are taking about Payroll US or Payroll Canada,
If it is Payroll US,
then all the relevant note's and HRSP Level is document in the year end page
"Service.sap.com/hrusa" --> Year end
Also you can put watch this thread for year end thread for payroll US
"US - Year End 2011
If it is Payroll Canada,
then all the relevant notes and HRSP Level is document in the year end page
"service.sap.com/hrcanada" --> Year end
Also you can put watch this thread for year end thread for payroll canada
"CA - Year End 2011
With Regards,
S.Karthik -
Thread problem or jvm problem?
Hello, I've posted message on this link and now I've finished my project. Now, I have a different problem: that's why I'm posting this message here.
if you want me to post my project code, I can , but I think it's not necessary for now... So, there are 5 classes; Main, Thread1 extends Thread, thread2 extends Thread, Thread3 extends Thread and ThreadFactory... in main method; factory instance is called for the creation of threads; so in main three type of thread instance created by factory. And right after that threads starts running and thread1 finished first, thread2 finished second, and thred3 finished third; However, the program itself never ends. There is a problem with thread endings. I've also make dubugging. Main thread creates the three of them and first main thread finishes second thread1 and the other three never finishes... keeps running.
when main thread end it's state becomes zombie and thread1 also becomes zombie tooo.... but the other 2 of them never ends. I've tried may� things to do that: I've used finalyze() method too. Nothing chanced.
I guessed that this may happen becouse of JVM... so what do you suggest for ending threads in a sequence like thread1, thread2, thread3, main?no help?
-
URGENT : replacing letters in an expression
Hi all
I think that I should post this topic here because I think it concerns SQL functions. Here is the problem :
I am developping a forms application . There is a listbox named FORMULA containing list of formulas. When I choose a formula from that list then there is a program which exctracts all of its operands. For example if the formula is : (a+b)*abs(c-d) then the operands are : a,b,c and d.
Then I populate another listbox named OPERANDS with these operands. So the value of the OPERANDS listbox is either a or b or c or d in our example.
I held the expression of the formula in a global variable so it can be accessible anywhere in my application.
When I choose one of the operands from the OPERANDS listbox , for example b,then I enter its value , for example 5, in a text field named VALUE ,and then I click on a button to replace the letter "b" in the formula with the value I entered , which is 5. So I want to get an expression like this : (a+5)*abs(c-d) .
But the problem is that when I run the application then all letters "b" in the formula are replaced by 5 . So even the expression "abs", which is a pl/sql function, is replaced by "a5s". And I do not want that to happen.
Here is how I proceeded :
formula := replace(formula,operands,value); where "formula" is the global variable containing the formula expression, "operands" is the variable containing the value of the OPERANDS listbox which is "b" here, and "value" is the variable containing the value 5.
So how can I avoid this misreplacement ?
Thank you very much indeed.post it where you want, but only once...
I will follow the other thread
URGENT : replacing some letters in an expression -
Urgent : kanban process flow
Hai pp guru's
Any one please send the kanban process flow ppt .
I have to submit seminar for this month end .
very urgent.Hai arun
Thank you yaaar....any other link for kanban, please forward . -
Confusion using Thread.sleep() method
I tried it in this program
class NewThread implements Runnable {
String name; // name of thread
Thread t;
NewThread(String threadname) {
name = threadname;
t = new Thread(this, name);
System.out.println("New thread: " + t);
t.start(); // Start the thread
// This is the entry point for thread.
public void run() {
try {
for(int i = 5; i > 0; i--) {
System.out.println(name + ": " + i);
Thread.sleep(1000);
} catch (InterruptedException e) {
System.out.println(name + "Interrupted");
System.out.println(name + " exiting.");
class MultiThreadDemo {
public static void main(String args[]) {
new NewThread("One"); // start threads
new NewThread("Two");
new NewThread("Three");
try {
// wait for other threads to end
Thread.sleep(10000);
} catch (InterruptedException e) {
System.out.println("Main thread Interrupted");
System.out.println("Main thread exiting.");
}the output is
one: 5
two: 5
three 5
delay of 1 second
one:4
two: 4
three: 4
delay of 1second
what all i know about sleep() is that it pause the currently executing thread for specified time. hence in above program when first thread runs and prints value 5 then it should get paused for 1 second cause there is Thread.sleep(1000) after println() statement.
and output should be
one: 5
delay of 1 second
two: 5
delay of 1 second
three: 5
delay of 1 second
but this is not actually happens. may be i am wrong about Thread.sleep method() or something else.
would you guys please clear it?
regards
sanThread.sleep() only sleeps the current thread. As each thread runs concurrently they all print concurrently and all sleep concurrently.
-
Cleaner thread pegging cpu ?
Hi All,
I have an application that uses JE. After several restarts and with db around 10G in size, cpu runs high when I open the db. Repeated thread dump points me to cleaner thread:
At Time 1 :
"Cleaner-1" daemon prio=6 tid=0x0352e400 nid=0x1654 runnable [0x03adf000]
java.lang.Thread.State: RUNNABLE
at java.io.RandomAccessFile.readBytes(Native Method)
at java.io.RandomAccessFile.read(Unknown Source)
at com.sleepycat.je.log.FileManager.readFromFileInternal(FileManager.jav
a:1456)
At Time 2:
"Cleaner-1" daemon prio=6 tid=0x0352e400 nid=0x1654 runnable [0x03adf000]
java.lang.Thread.State: RUNNABLE
at java.io.RandomAccessFile.readBytes(Native Method)
at java.io.RandomAccessFile.read(Unknown Source)
at com.sleepycat.je.log.FileManager.readFromFileInternal(FileManager.jav
a:1456)
- locked <0x170f0778> (a java.io.RandomAccessFile)
at com.sleepycat.je.log.FileManager.readFromFile(FileManager.java:1377)
at com.sleepycat.je.log.FileReader.fillReadBuffer(FileReader.java:786)
at com.sleepycat.je.log.FileReader.readData(FileReader.java:661)
at com.sleepycat.je.log.FileReader.readNextEntry(FileReader.java:297)
at com.sleepycat.je.cleaner.FileProcessor.processFile(FileProcessor.java
:384)
at com.sleepycat.je.cleaner.FileProcessor.doClean(FileProcessor.java:232
- locked <0x15281a78> (a com.sleepycat.je.cleaner.FileProcessor)
at com.sleepycat.je.cleaner.FileProcessor.onWakeup(FileProcessor.java:13
7)
at com.sleepycat.je.utilint.DaemonThread.run(DaemonThread.java:140)
at java.lang.Thread.run(Unknown Source)
Any thoughts on whats causing this ?
Thanks, Regards
VissuThanks for your response. We have 3 BDB stores. Stats from all three at two different time periods are posted below:
At Time 1:
------------------ DB NAME store1 BDB STATS START ---------------------
Compression stats
splitBins=0
dbClosedBins=0
cursorsBins=0
nonEmptyBins=0
processedBins=0
inCompQueueSize=0
Eviction stats
nEvictPasses=192
nNodesSelected=7,257
nNodesScanned=72,984
nNodesExplicitlyEvicted=4,054
nRootNodesEvicted=1
nBINsStripped=3,202
requiredEvictBytes=544,584
Checkpoint stats
nCheckpoints=3
lastCheckpointId=1,071
nFullINFlush=54
nFullBINFlush=2
nDeltaINFlush=10,869
lastCheckpointStart=0x18/0x3e8b1e6f
lastCheckpointEnd=0x18/0x3ea6cbf3
endOfLog=0x18/0x3ea6cbf3
Cleaner stats
cleanerBacklog=6
nCleanerRuns=1
nCleanerDeletions=0
nINsObsolete=0
nINsCleaned=0
nINsDead=0
nINsMigrated=0
nLNsObsolete=0
nLNsCleaned=0
nLNsDead=0
nLNsLocked=0
nLNsMigrated=25,370
nLNsMarked=0
nLNQueueHits=0
nPendingLNsProcessed=0
nMarkedLNsProcessed=25,329
nToBeCleanedLNsProcessed=41
nClusterLNsProcessed=0
nPendingLNsLocked=0
nCleanerEntriesRead=139,424
Cache stats
nNotResident=23,045
nCacheMiss=22,740
nLogBuffers=3
bufferBytes=3,145,728
dataBytes=100,772,127
adminBytes=424,471
lockBytes=240
cacheTotalBytes=104,342,566
sharedCacheTotalBytes=0
nSharedCacheEnvironments=0
IO Stats
nRandomReads=14,557
nRandomWrites=75
nSequentialReads=72,336
nSequentialWrites=0
nRandomReadBytes=32,032,768
nRandomWriteBytes=75,582,820
nSequentialReadBytes=2,329,355,350
nSequentialWriteBytes=0
Logging stats
nFSyncs=3
nFSyncRequests=3
nFSyncTimeouts=0
nRepeatFaultReads=7,537
nTempBufferWrite=0
nRepeatIteratorReads=0
nFileOpens=13
nOpenFiles=4
totalLogSize=9,640,994,599
------------------ DB NAME store1 BDB STATS END ---------------------
------------------ DB NAME store2 BDB STATS START ---------------------
Compression stats
splitBins=0
dbClosedBins=0
cursorsBins=0
nonEmptyBins=0
processedBins=0
inCompQueueSize=0
Eviction stats
nEvictPasses=250
nNodesSelected=9,918
nNodesScanned=99,748
nNodesExplicitlyEvicted=5,265
nRootNodesEvicted=1
nBINsStripped=4,652
requiredEvictBytes=553,226
Checkpoint stats
nCheckpoints=4
lastCheckpointId=1,072
nFullINFlush=54
nFullBINFlush=2
nDeltaINFlush=13,069
lastCheckpointStart=0x18/0x3e8b1e6f
lastCheckpointEnd=0x18/0x3ea6cbf3
endOfLog=0x19/0x26
Cleaner stats
cleanerBacklog=6
nCleanerRuns=1
nCleanerDeletions=0
nINsObsolete=0
nINsCleaned=0
nINsDead=0
nINsMigrated=0
nLNsObsolete=0
nLNsCleaned=0
nLNsDead=0
nLNsLocked=0
nLNsMigrated=29,285
nLNsMarked=0
nLNQueueHits=0
nPendingLNsProcessed=0
nMarkedLNsProcessed=29,244
nToBeCleanedLNsProcessed=41
nClusterLNsProcessed=0
nPendingLNsLocked=0
nCleanerEntriesRead=145,740
Cache stats
nNotResident=27,487
nCacheMiss=27,101
nLogBuffers=3
bufferBytes=3,145,728
dataBytes=100,581,101
adminBytes=688,215
lockBytes=240
cacheTotalBytes=104,415,284
sharedCacheTotalBytes=0
nSharedCacheEnvironments=0
IO Stats
nRandomReads=16,864
nRandomWrites=97
nSequentialReads=75,976
nSequentialWrites=0
nRandomReadBytes=37,252,096
nRandomWriteBytes=98,205,476
nSequentialReadBytes=2,364,861,517
nSequentialWriteBytes=0
Logging stats
nFSyncs=3
nFSyncRequests=3
nFSyncTimeouts=0
nRepeatFaultReads=8,666
nTempBufferWrite=0
nRepeatIteratorReads=0
nFileOpens=13
nOpenFiles=4
totalLogSize=9,663,617,794
------------------ DB NAME store2 BDB STATS END ---------------------
------------------ DB NAME store3 BDB STATS START ---------------------
Compression stats
splitBins=0
dbClosedBins=0
cursorsBins=0
nonEmptyBins=0
processedBins=0
inCompQueueSize=0
Eviction stats
nEvictPasses=250
nNodesSelected=9,918
nNodesScanned=99,748
nNodesExplicitlyEvicted=5,265
nRootNodesEvicted=1
nBINsStripped=4,652
requiredEvictBytes=553,226
Checkpoint stats
nCheckpoints=4
lastCheckpointId=1,072
nFullINFlush=72
nFullBINFlush=2
nDeltaINFlush=14,561
lastCheckpointStart=0x18/0x3fe81963
lastCheckpointEnd=0x19/0xa8c83
endOfLog=0x19/0xa8c83
Cleaner stats
cleanerBacklog=6
nCleanerRuns=1
nCleanerDeletions=0
nINsObsolete=0
nINsCleaned=0
nINsDead=0
nINsMigrated=0
nLNsObsolete=0
nLNsCleaned=0
nLNsDead=0
nLNsLocked=0
nLNsMigrated=31,084
nLNsMarked=0
nLNQueueHits=0
nPendingLNsProcessed=0
nMarkedLNsProcessed=31,043
nToBeCleanedLNsProcessed=41
nClusterLNsProcessed=0
nPendingLNsLocked=0
nCleanerEntriesRead=146,431
Cache stats
nNotResident=27,491
nCacheMiss=27,105
nLogBuffers=3
bufferBytes=3,145,728
dataBytes=100,601,879
adminBytes=449,652
lockBytes=240
cacheTotalBytes=104,197,499
sharedCacheTotalBytes=0
nSharedCacheEnvironments=0
IO Stats
nRandomReads=16,872
nRandomWrites=98
nSequentialReads=76,459
nSequentialWrites=1
nRandomReadBytes=37,339,136
nRandomWriteBytes=98,205,514
nSequentialReadBytes=2,377,213,763
nSequentialWriteBytes=691,356
Logging stats
nFSyncs=4
nFSyncRequests=4
nFSyncTimeouts=0
nRepeatFaultReads=8,667
nTempBufferWrite=0
nRepeatIteratorReads=0
nFileOpens=15
nOpenFiles=4
totalLogSize=9,664,308,611
------------------ DB NAME store3 BDB STATS END ---------------------
At Time 2:
------------------ DB NAME store1 BDB STATS START ---------------------
Compression stats
splitBins=0
dbClosedBins=0
cursorsBins=0
nonEmptyBins=0
processedBins=0
inCompQueueSize=0
Eviction stats
nEvictPasses=1,211
nNodesSelected=51,452
nNodesScanned=517,594
nNodesExplicitlyEvicted=25,454
nRootNodesEvicted=2
nBINsStripped=25,996
requiredEvictBytes=542,075
Checkpoint stats
nCheckpoints=19
lastCheckpointId=1,087
nFullINFlush=633
nFullBINFlush=284
nDeltaINFlush=69,089
lastCheckpointStart=0x19/0x169d56ee
lastCheckpointEnd=0x19/0x16c8999f
endOfLog=0x19/0x171e57d2
Cleaner stats
cleanerBacklog=6
nCleanerRuns=1
nCleanerDeletions=0
nINsObsolete=0
nINsCleaned=0
nINsDead=0
nINsMigrated=0
nLNsObsolete=0
nLNsCleaned=0
nLNsDead=0
nLNsLocked=0
nLNsMigrated=113,048
nLNsMarked=0
nLNQueueHits=0
nPendingLNsProcessed=0
nMarkedLNsProcessed=113,007
nToBeCleanedLNsProcessed=41
nClusterLNsProcessed=0
nPendingLNsLocked=0
nCleanerEntriesRead=252,418
Cache stats
nNotResident=95,125
nCacheMiss=93,645
nLogBuffers=3
bufferBytes=3,145,728
dataBytes=100,409,969
adminBytes=820,596
lockBytes=240
cacheTotalBytes=104,376,533
sharedCacheTotalBytes=0
nSharedCacheEnvironments=0
IO Stats
nRandomReads=51,953
nRandomWrites=477
nSequentialReads=136,332
nSequentialWrites=2
nRandomReadBytes=136,701,952
nRandomWriteBytes=484,828,017
nSequentialReadBytes=3,166,856,255
nSequentialWriteBytes=828,678
Logging stats
nFSyncs=19
nFSyncRequests=19
nFSyncTimeouts=0
nRepeatFaultReads=27,760
nTempBufferWrite=0
nRepeatIteratorReads=0
nFileOpens=16
nOpenFiles=5
totalLogSize=10,051,494,660
------------------ DB NAME store1 BDB STATS END ---------------------
------------------ DB NAME store2 BDB STATS START ---------------------
Compression stats
splitBins=0
dbClosedBins=0
cursorsBins=0
nonEmptyBins=0
processedBins=0
inCompQueueSize=0
Eviction stats
nEvictPasses=1,484
nNodesSelected=64,150
nNodesScanned=645,302
nNodesExplicitlyEvicted=31,175
nRootNodesEvicted=3
nBINsStripped=32,971
requiredEvictBytes=545,715
Checkpoint stats
nCheckpoints=23
lastCheckpointId=1,091
nFullINFlush=786
nFullBINFlush=369
nDeltaINFlush=83,587
lastCheckpointStart=0x19/0x1c867553
lastCheckpointEnd=0x19/0x1cbf4c23
endOfLog=0x19/0x1da9a82d
Cleaner stats
cleanerBacklog=6
nCleanerRuns=1
nCleanerDeletions=0
nINsObsolete=0
nINsCleaned=0
nINsDead=0
nINsMigrated=0
nLNsObsolete=0
nLNsCleaned=0
nLNsDead=0
nLNsLocked=0
nLNsMigrated=137,251
nLNsMarked=0
nLNQueueHits=0
nPendingLNsProcessed=0
nMarkedLNsProcessed=137,210
nToBeCleanedLNsProcessed=41
nClusterLNsProcessed=0
nPendingLNsLocked=0
nCleanerEntriesRead=284,941
Cache stats
nNotResident=115,933
nCacheMiss=114,144
nLogBuffers=3
bufferBytes=3,145,728
dataBytes=100,332,651
adminBytes=929,276
lockBytes=240
cacheTotalBytes=104,407,895
sharedCacheTotalBytes=0
nSharedCacheEnvironments=0
IO Stats
nRandomReads=62,928
nRandomWrites=584
nSequentialReads=151,506
nSequentialWrites=2
nRandomReadBytes=183,549,952
nRandomWriteBytes=594,201,681
nSequentialReadBytes=3,364,667,387
nSequentialWriteBytes=828,678
Logging stats
nFSyncs=23
nFSyncRequests=23
nFSyncTimeouts=0
nRepeatFaultReads=33,167
nTempBufferWrite=0
nRepeatIteratorReads=0
nFileOpens=16
nOpenFiles=5
totalLogSize=10,161,297,881
------------------ DB NAME store2 BDB STATS END ---------------------
------------------ DB NAME store3 BDB STATS START ---------------------
Compression stats
splitBins=0
dbClosedBins=0
cursorsBins=0
nonEmptyBins=0
processedBins=0
inCompQueueSize=0
Eviction stats
nEvictPasses=1,505
nNodesSelected=65,097
nNodesScanned=654,826
nNodesExplicitlyEvicted=31,615
nRootNodesEvicted=3
nBINsStripped=33,478
requiredEvictBytes=529,755
Checkpoint stats
nCheckpoints=24
lastCheckpointId=1,092
nFullINFlush=809
nFullBINFlush=375
nDeltaINFlush=87,260
lastCheckpointStart=0x19/0x1e00e932
lastCheckpointEnd=0x19/0x1e335c8d
endOfLog=0x19/0x1e3e8bae
Cleaner stats
cleanerBacklog=6
nCleanerRuns=1
nCleanerDeletions=0
nINsObsolete=0
nINsCleaned=0
nINsDead=0
nINsMigrated=0
nLNsObsolete=0
nLNsCleaned=0
nLNsDead=0
nLNsLocked=0
nLNsMigrated=143,591
nLNsMarked=0
nLNQueueHits=0
nPendingLNsProcessed=0
nMarkedLNsProcessed=143,550
nToBeCleanedLNsProcessed=41
nClusterLNsProcessed=0
nPendingLNsLocked=0
nCleanerEntriesRead=288,443
Cache stats
nNotResident=117,507
nCacheMiss=115,697
nLogBuffers=3
bufferBytes=3,145,728
dataBytes=100,356,995
adminBytes=953,476
lockBytes=240
cacheTotalBytes=104,456,439
sharedCacheTotalBytes=0
nSharedCacheEnvironments=0
IO Stats
nRandomReads=63,792
nRandomWrites=594
nSequentialReads=152,665
nSequentialWrites=2
nRandomReadBytes=190,541,824
nRandomWriteBytes=604,059,370
nSequentialReadBytes=3,390,746,461
nSequentialWriteBytes=828,678
Logging stats
nFSyncs=24
nFSyncRequests=24
nFSyncTimeouts=0
nRepeatFaultReads=33,586
nTempBufferWrite=0
nRepeatIteratorReads=0
nFileOpens=16
nOpenFiles=5
totalLogSize=10,171,054,372
------------------ DB NAME store3 BDB STATS END ---------------------
Thread dumps show cleaner doing different things but mostly working with files.
Of all the threads from thread dump, Cleaner is the only one is runnable state - dont know what it is trying to do but CPU is high (dual core machine and one core is almost at 90%).
At time 3 (thread dump shows cleaner thread again)
"Cleaner-1" daemon prio=6 tid=0x03137800 nid=0x153c runnable [0x03adf000]
java.lang.Thread.State: RUNNABLE
at java.util.zip.Adler32.updateBytes(Native Method)
at java.util.zip.Adler32.update(Unknown Source)
at com.sleepycat.je.log.ChecksumValidator.update(ChecksumValidator.java:
61)
at com.sleepycat.je.log.FileReader.validateChecksum(FileReader.java:589)
at com.sleepycat.je.log.FileReader.readNextEntry(FileReader.java:314)
at com.sleepycat.je.cleaner.FileProcessor.processFile(FileProcessor.java
:384)
at com.sleepycat.je.cleaner.FileProcessor.doClean(FileProcessor.java:232
- locked <0x1542f998> (a com.sleepycat.je.cleaner.FileProcessor)
at com.sleepycat.je.cleaner.FileProcessor.onWakeup(FileProcessor.java:13
7)
at com.sleepycat.je.utilint.DaemonThread.run(DaemonThread.java:140)
at java.lang.Thread.run(Unknown Source)
At time 4
"Cleaner-1" daemon prio=6 tid=0x03137800 nid=0x153c runnable [0x03adf000]
java.lang.Thread.State: RUNNABLE
at java.io.RandomAccessFile.readBytes(Native Method)
at java.io.RandomAccessFile.read(Unknown Source)
at com.sleepycat.je.log.FileManager.readFromFileInternal(FileManager.jav
a:1456)
- locked <0x1a201ca8> (a java.io.RandomAccessFile)
at com.sleepycat.je.log.FileManager.readFromFile(FileManager.java:1377)
at com.sleepycat.je.log.FileReader.fillReadBuffer(FileReader.java:786)
at com.sleepycat.je.log.FileReader.readData(FileReader.java:661)
at com.sleepycat.je.log.FileReader.readNextEntry(FileReader.java:297)
at com.sleepycat.je.cleaner.FileProcessor.processFile(FileProcessor.java
:384)
at com.sleepycat.je.cleaner.FileProcessor.doClean(FileProcessor.java:232
- locked <0x1528be68> (a com.sleepycat.je.cleaner.FileProcessor)
at com.sleepycat.je.cleaner.FileProcessor.onWakeup(FileProcessor.java:13
7)
at com.sleepycat.je.utilint.DaemonThread.run(DaemonThread.java:140)
at java.lang.Thread.run(Unknown Source)
Values have timestamps (nano) and versions + actual value which is about 300 bytes.
JDK = 1.6.04, JE 3.3.62. this experiment was done on XP.
Any help is appreciated.
Regards
Vissu -
Urgent - MV not getting refreshed
I created a MV as under.
CREATE MATERIALIZED VIEW schema.abc_mv
TABLESPACE "aaa"
REFRESH FAST ON DEMAND START WITH sysdate+0 NEXT SYSDATE+5/1440
AS SELECT *
FROM abc@dblink;
Its not getting refreshed. Yesterday one record was inserted in the abc table but the MV was not refreshed. I tried refreshing the MV manually by running the below script but its still not working. PLEASE HELPPPP!
BEGIN
DBMS_MVIEW.REFRESH('abc_mv');
END;For urgent issues please log with metalink
-
Surprisingly fast locking of single thread
The question in this thread
http://forums.adobe.com/thread/1080275?tstart=0
was correctly answered within two minutes by Bill, and his answer was marked as correct and the thread locked, probably shortly after Bill's posting.
What I find susprising is that the Reader forum has hundreds of similar questions and answers (see Pat's complain here http://forums.adobe.com/thread/1079699?tstart=0) , but only a handful of them are marked as Answered. And, without checking, I would say that (almost) none of these threads have been locked.
Bill, was that you?Locking dead-ended threads is one tool we can use to maintain an effective customer experience. Experts on the forum tend to ignore answered questions precisely because they're answered, so thread-hijackers have much less chance of getting help compared to when they post a new question. As Bill and John have said, if someone searches the forums for a keyword and hits one of the threads that were started in the wrong place we absolutely do not want them replying to it.
Locks are applied for three basic reasons:
The thread is in the wrong place and couldn't be moved due to lack of information (outright duplicate posts are removed when they're noticed - please report any you find).
The thread has deviated from the original topic or has violated the Guidelines (e.g. it's descended into a slanging match).
The post is for information only (e.g. FAQ pages).
If there is an active and pertinent conversation within a thread it won't be locked, even if a Correct reply has been selected, but there are some threads which are so old or so trivial there's no reason anyone should reply to them. These forums are used for internal reporting and it assists with that process to have a number of similar-but-separate questions in the database as opposed to one thread with several conversations crossing each other.
There are some forums which are read-only, e.g. legacy or beta versions of software, but there will always be a new and open forum for current issues if the product still exists.
Current policy is for hosts to assign a Correct status to answers as and when they are identified, allowing time for the OP to make the decision first. Historically we didn't do this so there are hundreds of thousands of old threads which are 'answered' but not marked as such. It's a very long process to go through and retag them - and there's little benefit from doing so. -
Urgent: ORA-04030 from PL/SQL code
Hi, we are running a data conversion program for Oracle Applications which works in the following logic
1. There is a loader program which uses SQLLoader to load 6.6L records from flat files to custom staging table
2. There is a Validation program which validates (for business requirements) records available in the custom staging table. Based on the validation results the program updates the Status field (a column of the table) to ERROR or SUCCESS. This program uses pl/sql table types with bulk insert and bulk update. While we run the program for less number of records it works fine, but when the volume of data is high (6.6L) we get the following exception:
ORA-04030 (out of process memory when trying to allocate ... bytes).
As an work around we have used "dbms_session.free_unused_user_memory;" statement after every plsql table.DELETE call. But still we get the issue. Can anyone suggest us whats going wrong? If we use of Global Temp Table in place of pl/sql table will it help?
Thanks /SantanuDuplicate Thread
Urgent: ORA-04030 from Routing Conversion Validation Program
Maybe you are looking for
-
TS2755 iMessage not receiving as normal text after leaving Wi-Fi
When I start a conversation with someone in a Wi-Fi zone, with iMessage turned on, it send in a blue bubble. When I leave the wifi zone and keep the conversation going its turns green, the problem is that once I leave the wifi zone in a iMessage star
-
Can I set up a RAID 1 Array by adding a drive to an existing install?
Hi All: I have a K8N Neo2 with a 160GB Seagate SATA drive on it, and just bought an identical drive that I want to use for a RAID 1 array. My question is this: Do I need to do a complete reformat with the OS in order to setup RAID 1? With my old sy
-
I posted this question on FCX forum but maybe its more appropriate here. I bought FCX for $99, upgraded to FCX HD for $99 because it came with Soundtrack and then spent another $99 to upgrade to Soundtrack Pro. Because I own Soundtrack Pro it looks t
-
[solved] Thunar - icons in right-click-menu are gone
Hi there. Since some time my icons in the thunar right-click-menu are gone. I guess they disappeared with thunar 1.4 but I'm not sure. Is there a way to make them come back? I have a hand full of custom actions and the icons help me to distinguish th
-
I have a 5th generation iPod nano. I downloaded an audiobook on Itunes. It will not let me sync saying this computer is not authorized. Anyone know what to do?