Weblogic: ONE thread cause CPU soaring(50%+),NEVER die,why?

hi,
My environment is as follows:
APPSERVER: weblogic 8.1.4 sp4
JDK: IBM jdk1.4
OS: AIX 5.3
DB: oracle
our app model is as follows:
user | server | cluster
user1 \************/server1
user2 -- proxy server -- server2
user3 / ***********\server3
(https) (http)
the proxy server and server1/2/3 are all in one domain(server1/2/3 one cluster),
once we restart the proxy server,everything looks fine,but 1 or 2 days
later,the CPU start soaring,from 10~20% to 50%(proxy server cpu usage),
however,the server1/2/3 are all healty(cpu not high),if we restart server1/2/3
the problem still exist, and after some time,the cpu would be up to 90%+,then
we MUST restart the proxy server,then everything ok again.
Now the cpu is 50%+,we checked the proxy server's active threads,and found ONE
thread whose id is 252 continue exist and the request never change during one day.
the thread state is :
252 13262 weblogic.t3.srvr.SSLListenThread$1@2778a170 n/a n/a
then we get the thread dump by kill -3,we get this info about this thread:
at 0xD3764B18 in
"ExecuteThread: '252' for queue: 'weblogic.kernel.Default'" (TID:0x300C2168, sys_thread_t:0x7E6F08A8, state:R, native ID:0x10506) prio=5
at com.rsa.jsafe.JCMPInt.addVectors(Unknown Source)
at com.rsa.jsafe.JCMPInt.addInPlace(Unknown Source)
at com.rsa.jsafe.JCMPInt.subtractSigned(Unknown Source)
at com.rsa.jsafe.JCMPInt.modInvertSchroeppel(Unknown Source)
at com.rsa.jsafe.JCMPInt.modInvert(Unknown Source)
at com.rsa.jsafe.JA_RSA.generateBlindingValues(Unknown Source)
at com.rsa.jsafe.JA_RSA.generateBlindingValuesBuffer(Unknown Source)
at com.rsa.jsafe.JA_RSAPrivateKey.getKeyDataBlind(Unknown Source)
at com.rsa.jsafe.JA_RSAPrivateKey.getKeyData(Unknown Source)
at com.rsa.jsafe.JA_KeyData.getKeyData(Unknown Source)
at com.rsa.jsafe.JA_RSA.generalDecryptInit(Unknown Source)
at com.rsa.jsafe.JA_RSA.decryptInit(Unknown Source)
at com.rsa.jsafe.JG_AsymmetricCipher.doDecryptInit(Unknown Source)
at com.rsa.jsafe.JSAFE_AsymmetricCipher.decryptInit(Unknown Source)
at com.rsa.jsafe.JSAFE_AsymmetricCipher.decryptInit(Unknown Source)
at com.certicom.tls.provider.cipher.JSAFE_RSA.init(Unknown Source)
at com.certicom.tls.record.handshake.ServerStateSentHelloDone.handle(Unknown Source)
at com.certicom.tls.record.handshake.HandshakeHandler.handleHandshakeMessage(Unknown Source)
at com.certicom.tls.record.handshake.HandshakeHandler.handleHandshakeMessages(Unknown Source)
at com.certicom.tls.record.MessageInterpreter.interpretContent(Unknown Source)
at com.certicom.tls.record.MessageInterpreter.decryptMessage(Unknown Source)
at com.certicom.tls.record.ReadHandler.processRecord(Unknown Source)
at com.certicom.tls.record.ReadHandler.readRecord(Unknown Source)
at com.certicom.tls.record.ReadHandler.readUntilHandshakeComplete(Unknown Source)
at com.certicom.tls.interfaceimpl.TLSConnectionImpl.completeHandshake(Unknown Source)
at javax.net.ssl.impl.SSLSocketImpl.startHandshake(Unknown Source)
at com.bea.sslplus.CerticomSSLContext.forceHandshakeOnAcceptedSocket(Unknown Source)
at weblogic.security.utils.SSLContextWrapper.forceHandshakeOnAcceptedSocket(SSLContextWrapper.java(Compiled Code))
at weblogic.t3.srvr.SSLListenThread$1.execute(SSLListenThread.java(Compiled Code))
at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java(Compiled Code))
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java(Compiled Code))
we start google,but nothing found about this problem.The only way to solve this problem now is to restart
the proxy server,can anyone help me to solve this problem? any response is appreciated!!!
cowrie / 2009-6-3

why,please help me ....

Similar Messages

  • Space designer causing cpu spike overload

    Hope you guys can help with this, it's beginning to annoy me. I'm currently unable to use space designer reliably. I had this problem in Logic 8 and it's still happening in 9. I have one instance of SD in my current project and it's causing cpu spikes that are giving me errors. The funny thing is that the error happens just after a region that is being sent to the reverb has ended. the cpu meter then gradually rises until the error stops playback. If I turn SD off i don't get these problems or if I disable SD via automation when it's not needed it seems ok also. What the **** is this about? The thing is I really like the sound of SD and miss it when I have to use different reverbs. Anyone else having these issues? I read on another thread that setting all your inputs to "no input" helps but for me it doesn't. What else can I try?
    cheers
    p

    Thanks for your input.
    Just to clarify, I am getting the spike once the audio data stops sending through the SD plugin (whilst the song is still playing). So, for example I may send a 10 second bit of audio through the plug - this works fine. Then once the audio stops sending and the reverb trail finishes....I then get the CPU going mad - and yet there is complete silence within the song - there is nothing else playing!
    This has got to be a bug or conflict of some kind - my computer spec is massive and should be able to cope with a stereo bit of audio through one plugin! (Hope this makes sense.)
    There have been a couple of posts similar but no answers as yet...
    Wondering whether it is a conflict with UAD plugins or something which limits the reproduction of this bug...I have noticed that if I remove all UAD plugins from the channel strip in question, the error tends not to reappear - but the issue is unique to the SD plugin.
    Danny

  • Shutting down a panel in one thread from another thread.

    For various reasons, I have a program with two threads (actually more than two, but only two are concerned here). One is the main panel that runs at startup, another is a Virtual O'Scope panel with a real-time display. Everything works more or less well, until it's time to exit the program.
    The main program starts by calling a routine to display the VO'scope; this routine calls CmtScheduleThreadPoolFunctionAdv to schedule the VOscope thread with the function VOscopePanelMain.
    VOscopePanelMain initializes things, displays the VOscope panel, and then calls RunUserInterface(); to process events in the VOscope panel.
    When it comes time to close the window, closing the panel (the X box in the upper right corner) triggers the panel callback CB_VoscopePanel, which processes the EVENT_CLOSE: event by calling QuitUserInterface(0); which, in turn, causes RunUserInterface to return to VOscopePanelMain, which then shuts things down, closes the panel properly, and exits. So far so good.
    int CVICALLBACK CB_VoscopePanel (int panel, int event, void *callbackData,
            int eventData1, int eventData2)
        int    iPanelHeight, iPanelWidth, iV2ControlLeft, iV2ControlWidth, iWidth,
            iT2ControlTop, iT2ControlHeight, iHeight, iLeft, iGap, iScreenTop, iScreenLeft,
            iTop, iBoxWidth;
        switch (event) {
            break;
        case EVENT_GOT_FOCUS: //happens when first displayed or refreshed
        case EVENT_PANEL_SIZE: //size the controls on the panel
           ... do stuff here;
            break;
        case EVENT_CLOSE:
            QuitUserInterface(0);  //stop VOscopePanelMain, which in turn closes the panel and cleans stuff up.
            break;
        return 0;
    However, I also want the panel to stop when I close the main program. The only way that I know how to do this cleanly is to have the main program (which has closed all of its panels and is in the process of shutting down) call VOSCOPE_Close_VOScope () which, in turn, calls CallPanelCallback (iHandle_VOscope, EVENT_CLOSE, 0, 0, 0); (which forces a call to CB_VoscopePanel above with the EVENT_CLOSE event), which should call QuitUserInterface, which should cause the RunUserInterface in VOscopePanelMain to return and let it continue to shut down. In addition, after calling CallPanelCallback, the shutdown routine calls CmtWaitForThreadPoolFunctionCompletion to wait for the VOscopePanelMain thread to actually quit and clean up before proceeding.
    But, of course, it doesn't since, and it took me a while to realize this. The call to QuitUserInterface isn't coming from inside of the VOscopePanelMain thread, it's coming from the main panel's thread - which is already in the process of shutting down. So, the main panel thread is telling itself to quit, VOscopePanelMain never gets the QuitUserInterface message, and things stall.
    So: how do I have one thread tell a panel in another thread to cleanly close? Or do I have to get complicated and either replace RunUserInterface in VOscopePanelMain with a loop that processes events manually and looks for a flag, or figure out something with a thread-safe queue? Any help appreciated.
    Attachments:
    Voscope.c ‏76 KB

    Sorry for delay in answering, it took me a while to find time to build up a working example.
    The attached program spawns a thread in a new thread pool and permit you to choose whether to close it from the main thread or the spawned thread itself.
    It appears that in such a minimal configuration the process works as expected. There may be some different configuration in your actual program that prevents this.
    Proud to use LW/CVI from 3.1 on.
    My contributions to the Developer Zone Community
    If I have helped you, why not giving me a kudos?
    Attachments:
    ThreadPoolWithGUI.zip ‏7 KB

  • DW FTP is slow and causes CPU Spike

    Does anyone know why DW causes the CPU to jump up when it is
    performing FTP operations? I'm new to DW and maybe this is normal,
    but it shouldn't be. When I perfrom FTP activities, DW usually
    takes up about 60-70% of the CPU???
    Also, why is the FTP client so slow?
    Dreamweaver takes so much longer than other FTP clients. I
    compared it's usage to SmartFTP, FileZilla, and Windows built in
    FTP, and Dreamweaver is so slow on a magnitude of 20x - 30x. For a
    quick test I tried to pull down a directory using dreamweaver. I
    have all the files local already, so I told DW not to overwrite the
    files...so you would think it should speed through all the files
    and realize that they are all dups and not download anything, for a
    directory with 15 files in it, i would think this FTP operation
    should take about 2 seconds. but it takes dreamweaver about 4
    minutes to complete this, all my other FTP clients can figure this
    out in under 5 seconds, and they don't need to spike the CPU to do
    it.
    A quick search on the web tells me that I am not the only
    person with these problems.
    I really hope Adobe plans on fixing the FTP problems.
    Technical details:
    Dreamweaver CS3.
    Windows Vista SP1, 4GB ram, Fujitsu T4220

    I've had a related, ongoing problem with CS3 running up the
    CPU and acting
    slow for just about every operation for no apparent reason.
    It goes in
    surges, and just acts like molasses half the time, very
    annoying. It is to
    the point that I really don't use CS3, I use DW8, but try to
    use CS3 here
    and again to see if it has started working or if there is
    some patch
    released. This is on my XP workstation at work, and my Vista
    workstation at
    home. Both systems run CS3 slow enough that I just don't use
    CS3. This has
    been going on for over a year, since I got my copy of CS3.
    Too bad really, because I am tasked with approving CS3 for
    use by the rest
    of our WEB team and I haven't been able to do that, so we
    continue to use
    DW8. We are missing out on Spry integration and are slowly
    switching over
    to Eclipse and Aptana instead. I think that if the CPU bug
    isn't fixed, CS3
    will be the version that has us switch away entirely. The
    only hope seems to
    be if they release the next version of DW before we can
    completely switch
    away. We are a smallish state agency and only have 8 DW
    licenses, but
    that's seven licenses they missed out on the upgrade path
    with unless this
    is fixed (mine is the only upgraded so far). It just isn't
    useable in its
    present state. :-\
    "HenryHill" <[email protected]> wrote in
    message
    news:[email protected]...
    > This has been a problem with Dreamweaver for a while
    now. I would have
    > thought
    > that Adobe would have fixed the FTP issues, or at least
    improved upon them
    > by
    > now.
    >
    > One of the things you can try is to disable the
    "Maintain synchronization
    > information" checkbox in the "Remote Info" section of a
    site definition.
    > although, you won't get the benefit of synchronization
    in Dreamweaver, but
    > you
    > will get speed improvements, and your computer's CPU
    won't spike and sound
    > like
    > a jumbo jet taking off every time you perform a FTP
    operation.
    >
    > You can also try submitting a bug report as "John T
    Smith" recommended,
    > but I
    > can pretty much guarantee you it won't do any good. We
    have submitted
    > many
    > reports over the years and never heard anything.
    >
    > Your best bet is to go with an external FTP client such
    as FileZilla
    > (free!).
    > You get the benefit of multiple connections so your
    uploads/downloads are
    > faster, plus it gives you a lot more feedback as the
    FTPing is occuring,
    > such
    > as transfer speed, how many files have transfered, how
    many are left, any
    > errors. it will also auto detect if passive FTP is
    needed, you can pause,
    > stop, restart, it also shows you the exact ftp commands
    that it is sending
    > and
    > what the responses are from the server. These are things
    that Adobe
    > should
    > have included in the FTP client. As far as most of us
    are concerned, the
    > FTP
    > client built into Dreamweaver is in the dark ages
    compared to modern day
    > FTP
    > clients.
    >
    > Their are a lot of benefits to the built in client, but
    for us, the
    > negatives
    > out weigh the positives.
    >
    >
    >

  • Weblogic spiking to 99% CPU resources while processing inbound JMS messages

    We have an Integration Gateway server that is receiving data into a JMS queue from SAP/TIBCO and a legacy system for processing. We have Weblogic 8.1 SP3 and the server is running ClarifyCRM 12.5 Integration Gateway components including Tuxedo. In the past few weeks, Weblogic has been hanging up multiple times trying to receive this data from these systems. Specifically java.exe process used by Weblogic spikes to 99% CPU and the server becomes completely unresponsive. So far the only workaround we have is shutting down Weblogic, moving the incoming messages stored in the JM file store that are hanging the server to a different location so that they won't be processed by Weblogic and then restart Weblogic.
              What we see when this happens is that the hung up messages stay in the "Messages Pending" queue.
              A developer has mentioned that this may be happening because the threads handling the messages are hanging.
              I want to know if there is a tool from BEA to view and edit the JMS File Store on the file system to further analyze the incoming messages.

    I agree about the older version. However this particular version and service pack are the only ones that have been tested in our production and dev environments. So currently I don't have any options but to use it. However the system has been running relatively fine for the past 1-1.5 years.
              Do you happen to know the name of that tool that you mentioned below?
              Thanks in advance.

  • Java threads consume CPU in sleep state (??)

    Hi,
    I'm using the PRSTAT command on Solaris for the first time.
    I am investigating high CPU usage problem in my application. So to monitor the CPU usage I used the prstat and mpstat command. My machine is a 2-CPU box.
    The prstat -L -p <pid> command output is as follows:
    PID     UNAME  ... ....  STATE           CPU      PROCESS / LWPID
    2962   bea                   run           7.6%           java / 5
    2962   bea                   run           5.6%           java / 38
    2962   bea                   run           5.6%           java / 22
    2962   bea                   sleep         5.5%           java / 21
    2962   bea                   sleep         5.4%           java / 36
    2962   bea                   cpu2          5.2%           java / 23
    2962   bea                   sleep         5.1%           java / 29
    2962   bea                   run           5.1%           java / 37
    2962   bea                   sleep         4.9%           java / 34
    2962   bea                   run           4.9%           java / 15
    2962   bea                   run           1.1%           java / 12
    2962   bea                   sleep         1.0%          java / 33
    2962   bea                   run           0.6%           java / 14
    2962   bea                   run           0.0%           java / 17
    ..... This shows that of all the threads in my app only one thread(23) is currently on the CPU and is using 5.2% of CPU. But why are the threads in sleep and runnable state consuming CPU?
    Also the mpstat output shows high CPU usage:
    CPU minf mjf xcal  intr ithr  csw icsw migr smtx  srw syscl  usr sys  wt idl
      0   8   0  366  428   61   994   387  40   70     0 10941  95   4    0    1
      2   3   0  370  1003  563 1362  648   42   61    0  5374    92   2   0    6If my application is taking only ~57% according to sum of values from prstat, why is my mpstat showing 95% and 92% usage on EACH of my CPUs...??
    I'm unable to interpret the result.
    Any help would be really useful to me at this moment.
    .

    Hi,
    Your question should be posted in a unix forum instead of a java forum. The question, and the answer is not related to java.
    The reason that prstat shows processes in sleaping state is that it doesn't create a snaphost at one point in time. It does instead show an average over some time (don't know the period), so the process has been running and consumed cpu, or is generally running, but currently sleeping.
    Kaj

  • Stuck Thread causing heap to grow steeply and resulting in crash

    Hi,
    We have an ADF application deployed in weblogic 10.3.2.
    We have few PL/SQL's and SQL's which are complex and take around 5 minutes of time to complete at times. We also have the script running in database to kill long running queries so that it helps us to get rid of weblogic stuck threads to some extent.
    Now when ever there is an SQL running for long time , we see a stuck thread casuing heap to grow very fast and casuing server to crash.
    I know after a particular point of idle time thread is marked as stuck , but why does it filling the heap space - does stuck threads always causes heap to grow or is it just my specific case
    any pointers on how to debug this issue to find the root cause.
    Thanks,
    Naresh

    I think this setup needs profiling. To start-off, i would recommend collecting heap dump or jrf (if jrockit), instructions for them are available on net, as it varies with jvm versions and vendors.
    Post that you should look for the thread which you believe is stuck and a possible cause using OQL in memory analyzer tool over the heap dumps.
    Conceptually, till the time the objects (or data if you say) is being referenced, JVM cannot garbage collect it. So, I would say we need to figure out what are the contents of the heap, before coming to a conclusion that the threads which are stuck is causing the issue. Why I say so it that, I have seen in past that many-a-times, we suspect stuck threads to be an issue but it turns out to be that we are "knocking the wrong door".
    Long running threads (aka STUCK thread in WLS), will normally cause memory issues, if the references/task that its trying to perform has a large local data (i.e. data with the thread scope), so it the time the thread is not released the data is alive (irrespective of the fact that the data is used or not).
    Now, my first thought of this situation is that stuck thread is not an issue, considering that you are not able to replicate this in UAT post simulating stuck threads. Thus please collect some heap dumps (may be when you start observing memory increase) and then review them comparatively, I think that should be helpful.
    AJ

  • Putting ActiveX(packager) in CTabCtrl will cause CPU increase up to 100%

    Putting ActiveX(packager) in CTabCtrl will cause CPU increase up to 100%, and the whole system hangs.(When the test application loses its focus).
    Could you tell me why?
    Thanks.

    Ken McEwen wrote:
     Have reinstalled Lion overnight and it seems to be limping along this morning, although the wi-fi is dropping repeatedly.  
    How I wish I had followed my usual rule and waited until at least OSX 10.7.1 before installing.
    How did you "reinstall?" Others are reporting that installing from scratch is working better. If you're going to keep trying with Lion, I'd recommend posting in the Lion forum: https://discussions.apple.com/community/mac_os/mac_os_x_v10.7_lion (wow, I almost said "Windows forum," hmmm ).
    I may get in at 7.1, more likely at 7.2, but only if things look like they've changed enough. This appears to me to be on par with the change from 9 to X, and I waited until 10.2.3 with that one. If/when I do change, I'll have an up to the minute SL clone ready to reinstall if needed, and even then, I'll probably put 10.7 on an external HD.

  • Servlet spawning multiple threads causes server to freeze PC

    I'm attempting to write a servlet which, upon receipt of a particular GET request, spawns a thread to do various work which can then be queried by a different GET request. A third type of GET request stops a specified thread.
    This is working fine, except that I can only seem to have spawned one thread at a time. When I spawn another thread, my entire PC stops responding (even Windows Task Manager becomes so sluggish that I cannot kill the server) , and I have to do a hard reset of my PC. I'm using Sun Java System Application Server. The server logs do not contain any errors. I've tried the NetBeans debugger a bit, and it seems to happen when I call the start() method of the Thread.
    This is my first experience with servlets, as well as my first experience with Sun Java System Application Server. I'm also not a Java expert by any means. I'm sure I'm doing something stupid, but I haven't a clue what.
    I can post my code if necessary, but does anyone have any idea what could be causing the server to stop responding just because a servlet spawns two threads? Should I post my code?
    Sorry if this is a n00b question. Thanks in advance.

    I think you may need to spawn it into HTML frame. Each frame will perform
              and download independently.
              Is it what you need ?
              Siros
              "sam ernie" <[email protected]> wrote in message
              news:[email protected]..
              > Hi,
              >
              > In our application, the content of the main page is being
              > retrieved from different databases. All the requests originiate from
              > one JSP to different databases to retrieve the info. As the JSP
              > processes each of the request sequentailly, there is considerable delay
              > before the contents are displayed to the user.
              >
              > What I want to acheive is spawn multiple threads and display the content
              > to the user in fractions as each thread returns. For eaxmple, if the
              > user has subscribed to three news servers.. I want to be able to
              > display the news from first server to the user without waiting to
              > recieve response from the other two servers.
              >
              > What is the best approach to follow for such requirements ?? Any
              > thoughts on this would be highly appreciated.
              >
              > Thanks,
              >
              > Sam
              >
              

  • How can I pass an exception from one thread to another thread

    If I create a new class, that will extends the class Thread, the methode run() can not be use with the statement Throws Exeption .
    The question now: Is there any possibility to pass an exception from one thread to another thread?
    Thx.

    It really depends on what you want to do with your exception. Is there some sort of global handler that will process the exceptions in some meaningful way? Unless you have that, there's not much point in throwing an exception in a thread, unless you simply want the stack trace generated.
    Presuming that you have a global handler that can catch exceptions, nest your Exception subclass inside a RuntimeException:
    public class NestedRuntimeException extends RuntimeException
        private final m_nestedException;
        public NestedRuntimeException(final Exception originalException)
            super("An exception occurred with message: " + originalException.getMessage());
            m_nestedException;
        public Exception getNestedException()
            return m_nestedException;
    }Your global handler can catch the NestedRuntimeException or be supplied it to process by the thread group.

  • I get two message threads for one contact. One for sms and one for iMessage since I updated to iOS 7. How can I get them both into one thread?

    Ever since I upgraded to iOS7 just two of my contacts I get two message threads for them. One containing their iMessages to me and the other with just regular sms messages. In Contacs, their email and phone number are saved under one name. How can I get the iMessages and sms to come through under one thread in my messaging app again?

    I am having this trouble also, my partner creates a new message to send to me, or sends a picture and it always comes through as an MMS and not using iMessage ...
    will try deleting everything and starting again!

  • Posting topic to more than one thread and in different categories...

    Is there anything in the TOU we can "refer" to when users post the same topic in more than one thread and to add to that, more then one category? Case in point: http://discussions.apple.com/thread.jspa?messageID=8806009#8806009 (This is just one example)
    Limnos had a valid point. If we had a section in the TOU we could copy/paste from, I think it would help if we could refer to authority, ie., TOU.
    Thanks!
    Carolyn

    I wouldn't get into too much of a flury about that with end users. Notify as needed and let the moderators decide if it needs to be deleted. A good rule of thumb is you want the discussions to have:
    Everyone should feel comfortable reading Submissions and participating in discussions.
    That's from Terms of Use.
    And then there is:
    You agree to not interfere with or disrupt the Site.
    I'm seeing that logically one can conclude directing users not to crosspost may be considering interference with the site. I may suggest someone post in another forum if a solution is not transparent in the forum they are using, but that's as far as I'm comfortable bending the rules.
    I'm trying hard to keep my thumbs away from the keyboard when I see duplicate posts.

  • Copy variable from one thread to another

    My program requires user to input a java file which contains the run() method.
    In the input file, user can declare variables and use those variables inside the run method. User also need to enter the number of threads to be spawned.
    The problem is how can I construct some method like "copy" which can copy the variable from one thread to another in my program? I can't do that since I don't know the name of the variables that the user inputted.
    I've tried this:
    class helloworld extends thread{
    void run(){
    String a="hello";
    String b="world";
    copy(0,1,a,b)
    class myProgram {
    Class c = Class.forName(fileName);         // file name of user's file     
    Thread t[] = new Thread[p];             // p is number of threads
         for (int i=0; i<p; i++){             // create threads      
                   t[i] = (Thread) c.newInstance();  
                   t.start();
    public void copy(int sourThread, int destThread, String s1, String s2){
    t[sourThread].s1=t[destThread].s2
    But it doesn't work. It said "cannot resolve symbol s1 and s2".
    please help. urgent. Thanks a lot in advance.

    You need to seriously reconsider what you're allowing the user to do. The short answer to your problem is to use a shared, synchronized associative array.
    However, since the user can specify any number of threads, you will have to resolve deadlocks, and the fact that you're asking this question suggests you will have problems doing so until you have read up on threads and shared variables in more detail. (I don't mean to be dismissive. Deadlocks and shared variables have to be customized to the application, i.e., you have to figure out just when each thread will need access to the variable, what kind of access, and when.)
    In the meantime, take a step back and take a look at the big picture.
    From what you've said, I would guess a common example of your application is that I want to be able to read file "foo.dat", uppercase each letter in the file, and write it out to "fooXXX.dat" where XXX reflects the thread number. And specify any number of threads I want.
    Threads would not be the best way to accomplish this. Do this serially.
    Alternatively, I could interpret your problem as in you need to create a main() function that's capable of reading someone else's dot-class file, clone the object and start it. In which case, why do you want to share variables? If the user did his job correctly, then his file will already contain shared variables (or copy them as appropriate). All you have to do is clone the object via the new keyword, then call start() in it.
    You cannot share something when you don't know what you're sharing.
    The third option is that you're doing this as an academic exercise (i.e., homework). Granted, yes, your professor may ask you to do things illogically just to prove they can be done. Unfortunately, we're not supposed to help you in that case. People who read this forum generally try to find logical and efficient ways of doing things.

  • Why has mail on the ipad grouped several emails from different people with different subject matter into one thread?

    This is really annoying.
    The email initially started with me sending to one person. Which we then conversed several times without any issues.
    I then sent a separate email completely unrelated to someone on a completely different email address, but when they replied back somehow their reply joined the same thread as this other email i sent initially.
    Thinking that it might be a one of... I ignored it.
    However, just now, an email i created through the LinkedIn app, which i sent from LinkedIn to a contact, somehow joined that first thread, when the person on linked in replied back to me.
    Obviously i receive an email to my Mail account whenever someone messages me on linked in... But why on earth would that reply automatically get grouped into the completely different thread of emails?
    I NOW have emails to three different people who are completely unrelated with three completely unrelated subjects, that are appearing in one thread with no obvious way to separate these.
    Any solutions or suggestions? I've tried to move them, but it will only let me move the the messages into different folders, and not my inbox as separate messages.

    Hi Anya!
    Thanks for the response. Regarding your question, Yes, I have confirmed that people were receiving multiple copies.
    I've confirmed this as I had left a Gmail message open on my browser window and opened that same message from Mail: As I was writing the response from Mail, without sending anything, new notifications started to appear over the same message in the browser window, notifying me there were new messages from Myself! So when I started to open those "new replies", I came to the conclusion that as I was typing, a draft was being saved and sent as a new message at the same time, therefore sending a lot of emails until I finished to write the message without knowing...
    Hard to explain but hope I've made my point.
    Thanks!
    D

  • More than one Thread accessing the same records in the database

    Hi, I have more than one thread accessing a synchronized method called getMinPrimaryKey() which gets the lowest of the primary key frm the table based on the a flag which is set to true. once it is retrieved the same method also sets the flag as false so it is not retrieved the second time. so next time a different thread calls this method it should retrieve the next available lowest primarmy key.
    but even when i have the method as synchronized different threads keep returning the same primary key instead of getting the next sequence. can some one let me know where I might go wrong and what could be the solution. is it because when once i retrieve the record and set the flag as false, i also need to commit it?, which could be the reason the select query still picks up the same primary key. please help me out on this.
    thanks,
    Harish

    Correction. If different threads always return the same key then your table isn't getting up dated. If different threads sometimes return the same key, then either the database is committing lazily, or else the threads are calling getMinPrimaryKey on different objects and so are not executing atomically with respect to each other.

Maybe you are looking for

  • Some CSS Links not displaying correctly

    Hi folks, I've been building a new site, but am having problems with some of the CSS links. The normal links are working fine. However, I've created a class that should display some of the links in bold - but it doesn't work! This is the CSS: .bold-l

  • A formal request.

    I would like to formally address an issue regarding Adobe's support of the Linux platform. As a professional, I have been using Linux for years. I started my technical consulting and support business running Linux primarily on my desktops and servers

  • Audit Manager for portal server

    The Audit manager in plumtree only logs activities on "Admin Portal Server". Is there a way to audit activitites of "portal server" ????

  • Epson Perfection 1660 Scanner Win7 64bit driver

    Anyone get this scanner or similar to work with Win 7 64bit? Seen some fake Trojan Horse software out there, and got the supposedly 32 bit win 7 download Epson recomends, but no luck. This was a fast scanner

  • Export image - Best quality

    I have a pdf in which i need to export an image in the best possible quality,how shall i achieve that?I've already tried saving as a tiff or a jpg and wasn't happy with the result.