AWT thread blocking issue.

I have a listener which is called on AWT thread, this listener does lot of backend processing by creating another thread, while the processing is going on the AWT thread is blocked causing painting issue.
public void actionPerformed(ActionEvent e)
// create a new thread
Thread t = new Thread();
t.start();
//wait till the thread t is done
while ( ! t.complete)
wait();
action Permormed is called on AWT thread.
On a website there was solution to this was -
Create a second thread to dispatch Events, popping them off the SystemEventQueue.
How can I achieve this? need your comments....

It is very dangerous to block AWT event dispatch threads. You must never do it. If you need to block your currently active GUI to wait until some process finishes, the common practice is to show modal dialog. This dialog will block the input until the process has finished. After the process finishes, you just hide the dialog.

Similar Messages

  • Thread blocking on java.nio.charset.CoderResult

    Hello all,
    I have a multi-threaded app which does some fairly intestive string operations (basically extracts text from documents for indexing a search system).
    I am seeing a massive bottleneck around the java.nio.charset.CoderResult class. When profiling, I see a whole stack of threads blocking on (waiting for) a monitor on this java.nio.charset.CoderResult class. Seems to be a result of string encoding/decoding (I am often encoding strings as UTF-8).
    Anyone know why the JVM would want my threads to sync on this class? It's creating a huge performance issue for my app. Approximately 15% of ALL the processing time is spent waiting for this class.
    Help!

    I would guess that you're using some of the static methods in the CoderResult class. The static methods CoderResult.unmappableCache(), CoderResult.malformedForLength() and CoderResult.malformedCache all use a static inner class called Cache. Its get() method is synchronized on Cache.class. Since the Cache inner-class is static, any part of your multi-threaded application that goes through the Cache.get() method is going to be waiting for the lock on Cache.class.
    Could you create a CoderResult instance for each thread? That would mean that there would be a different static Cache class for each thread, reducing the number of threads competing for the Cache.class lock.
    I'd have to see some of your code to give a better answer.
    Brian

  • Weblogic 10 jsp compliation thread block problem

    hi
    i am using weblogic 10 and jdk1.5.
    My application is deployed in ear format, with 2 wars, and 20 ejbs.
    The ear works ok with weblogic 8.1.
    In the application , one war passes the request to another war, that's the workflow....
    Now when the request is passed on the second war, a jsp is supposed to open....but the application get stuck there.
    The call is like this in a servlet....
         reqDisp = req.getRequestDispatcher("/newIndex.jsp");
    reqDisp.forward(req, res);
    The new index jsp is not opened....there is no problem with it it comiples ok....i check with weblogic appc...and it is working on weblogic 8.1.
    when i stop the server...the log gives me following exception info.
    "ExecuteThread: '12' for queue: 'default'" daemon prio=6 tid=0x2b8edad0 nid=0xc1
    0 in Object.wait() [0x2da1e000..0x2da1fb64]
    at java.lang.Object.wait(Native Method)
    - waiting on <0x07f94608> (a javelin.client.JobWaiter)
    at java.lang.Object.wait(Object.java:474)
    at javelin.client.JobWaiter.blockUntilFinished(JobWaiter.java:45)
    - locked <0x07f94608> (a javelin.client.JobWaiter)
    at javelin.client.ClientUtilsImpl.build(ClientUtilsImpl.java:838)
    at weblogic.servlet.jsp.JavelinxJSPStub.compilePage(JavelinxJSPStub.java:248)
    at weblogic.servlet.jsp.JspStub.prepareServlet(JspStub.java:200)
    at weblogic.servlet.jsp.JspStub.prepareServlet(JspStub.java:164)
    at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:235)
    - locked <0x07ef8220> (a weblogic.servlet.jsp.JavelinxJSPStub)
    at weblogic.servlet.internal.ServletStubImpl.onAddToMapException(ServletStubImpl.java:391)
    at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:309)
    at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:175)
    at weblogic.servlet.internal.RequestDispatcherImpl.invokeServlet(RequestDispatcherImpl.java:503)
    at weblogic.servlet.internal.RequestDispatcherImpl.forward(RequestDispatcherImpl.java:245)
    at LCDisplayController.handleProcessing(Unknown Source)
    at DisplayControllerServlet.doPost(Unknown Source)
    at DisplayControllerServlet.doGet(Unknown Source) at javax.servlet.http.HttpServlet.service(HttpServlet.java:707)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
    at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:226)
    at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:124)
    at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:283)
    at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:175)
    at weblogic.servlet.internal.RequestDispatcherImpl.invokeServlet(RequestDispatcherImpl.java:503)
    at weblogic.servlet.internal.RequestDispatcherImpl.forward(RequestDispatcherImpl.java:245)
    at com.orbitech.workflow.servlet.WFAppListController.openWorkitem(WFAppListController.java:793)
    at com.orbitech.workflow.servlet.WFAppListController.processRequest(WFAppListController.java:102)
    at com.orbitech.workflow.servlet.WFAppController.doProcessRequest(WFAppController.java:97)
    at com.orbitech.workflow.servlet.WFAppController.doGet(WFAppController.java:64) at javax.servlet.http.HttpServlet.service(HttpServlet.java:707)
    i think the there is thread blocking and the jsp is not getting compiled or smthing....
    i am unable to understnd the exception....
    any help, suggestion ? thanks in advance.

    We are using jBPM and Hibernate in our application which runs fine on other java application servers. On Weblogic we were getting an error:
    org.hibernate.HibernateException: Errors in named queries: GraphSession...........
    By adding:
    <container-descriptor>
    <prefer-web-inf-classes>true</prefer-web-inf-classes>
    </container-descriptor>
    to our weblogic.xml, Weblogic used our Hibernate3 and antl-2.7.6 .jar files which resolved this issue but created multiple CompilationException errors in many .jsp's. (as follows)
    Error 500--Internal Server Error
    weblogic.servlet.jsp.CompilationException: Failed to compile JSP /WEB-INF/jsp/struts/dashboards/portfolio_chart.jsp
    portfolio_chart.jsp:1:1: The validator class: "org.apache.taglibs.standard.tlv.JstlCoreTLV" has failed with the following exception: "java.lang.ClassCastException: weblogic.xml.jaxp.RegistrySAXParserFactory".
    <%@ taglib uri="/jstl-core" prefix="c" %>
    ^---------------------------------------^
    portfolio_chart.jsp:1:1: The validator class: "com.primavera.pvweb.taglib.JSMessageTagLibraryValidator" has failed with the following exception: "java.lang.ClassCastException: weblogic.xml.jaxp.RegistrySAXParserFactory".
    <%@ taglib uri="/jstl-core" prefix="c" %>
    ^---------------------------------------^
         at weblogic.servlet.jsp.JavelinxJSPStub.compilePage(JavelinxJSPStub.java:298)
         at weblogic.servlet.jsp.JspStub.prepareServlet(JspStub.java:216)
         at weblogic.servlet.jsp.JspStub.prepareServlet(JspStub.java:165)
         at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:235)
         at weblogic.servlet.internal.ServletStubImpl.onAddToMapException(ServletStubImpl.java:394)
         at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:309)
    Is this a Weblogic bug ?

  • Thread Problem - (Thread Blocking Problems?)

    Hi Friends
    In my program while using thread i found a problem in this code .
    In this whlie running the 'msg' was printen only after all 5 inputs are given .
    why i was not getting output after one input.why the thread out was waiting for remaining threads input.
    my code is
    import java.io.*;
    class MyThread extends Thread
      BufferedReader bin;
       MyThread()
         super();
         start();
       public void run()
          try
           bin=new BufferedReader(new InputStreamReader(System.in));
           String msg=bin.readLine();
           System.out.println(msg);
          catch(IOException e)
             System.out.println(e);
    public class Threads
         public static void main(String args[])
              for(int i=0;i<5;i++)
                new MyThread();
    }

    Hi Friends
    In my program while using thread i found a problem
    em in this code .
    In this whlie running the 'msg' was printen only
    after all 5 inputs are given .
    why i was not getting output after one input.why
    hy the thread out was waiting for remaining threads
    input.Probably because of how the scheduler was rotating among the threads while waiting for input and queueing up output.
    When you call readLine, that thread blocks until a line is available. So it probably goes to the next thread's readLine, and so on. All threads are probably blocked waiting for input before you enter a single character.
    Something inside the VM has to coordinate the interaction with the console, and between that and your threads, the out stuff just doesn't get a chance to display right away.
    In general, you can't predict the order of execution of separate threads.

  • Thread blocked in printStackTrace

    I find one of my thread blocked in printStackTrace after perform an overload test. But it doesn't wait any java lock. So I don't know what happened.
    Part of dumped thread stack looked like this:
    "Thread: 553" daemon prio=5 tid=0x00598f68 nid=0x23f runnable [95d7f000..95d7fc28]
         at java.lang.Throwable.getStackTraceElement(Native Method)
         at java.lang.Throwable.getOurStackTrace(Throwable.java:591)
         - locked <0xc423b3a8> (a java.lang.Throwable)
         at java.lang.Throwable.printStackTrace(Throwable.java:510)
    My application runs on solaris, sparc machine. JVM is 1.4.2_04-b05.

    Can u pstack the process at this moment? The stacks of all the threads are probably too large to be shown here.
    Show the thread #575. i.e. nid = 0x23f, convert to decimal = 575, maybe its stuck in the native portion.
    Hope this helps.

  • Thread Safety Issue with DOM

    I am parsing an XML into a DOM object using the Xerces parser that is packaged with JDK 1.5.
    First, I create a new instance of the DocumentBuilderFactory and then using the factory, create a new DocumentBuilder. I then parse the XML using the DocumentBuilder to obtain a DOM object.
    Somehow, I am seeing the same DOM object being used for different XMLs.
    Is there a thread safety issue with the Xerces parser?

    certainly, Xerces parser is not thread safe. You have to provide thread safety by making sure that only one thread is allowed to access DocumentBuilder object.

  • Thread Contention Issue , Help !

    public class vipThread implements Runnable
    private static volatile boolean lockMe=false;
    public synchronized static boolean getLock ()
         return lockMe;
    public synchronized static void setLock (boolean lock)
         lockMe = lock;
    public void run ()
    synchronized(this)
                   if(!this.getLock ()) {
                   this.setLock(true);
                   ret = vipRequestProcessor.getNewRequests ();                         
                   this.setLock(false);
    getNewRequests is not a synchronized method. Do i need to have it synchronized ? i do have a thread contention issue here. Couple of threds pickup the same request fromt he database.
    Help appreciated
    thanks
    pras

    public class vipThread implements Runnable
    private static volatile boolean lockMe=false;
    public synchronized static boolean getLock ()
    return lockMe;
    public synchronized static void setLock (boolean
    an lock)
    lockMe = lock;
    public void run ()
    synchronized(this)
    if(!this.getLock ()) {
    this.setLock(true);
    ret = vipRequestProcessor.getNewRequests ();
    this.setLock(false);
    getNewRequests is not a synchronized method. Do i need
    to have it synchronized ? i do have a thread
    contention issue here. Couple of threds pickup the
    same request fromt he database.
    Help appreciated
    thanks
    prasIf the "getNewRequests() method is only called from your vipThread, then you don't have thread contention problem.

  • [svn:bz-trunk] 12951: Changed synchronized PropertyProxyRegistry#getRegistry method to non-synchronized to avoid threads blocking in message push .

    Revision: 12951
    Revision: 12951
    Author:   [email protected]
    Date:     2009-12-15 02:17:31 -0800 (Tue, 15 Dec 2009)
    Log Message:
    Changed synchronized PropertyProxyRegistry#getRegistry method to non-synchronized to avoid threads blocking in message push.
    Checkintests: Pass with the usual 3-4 tests that time out with and without this change.
    QA: Yes
    Doc: No
    Modified Paths:
        blazeds/trunk/modules/core/src/flex/messaging/io/PropertyProxyRegistry.java

    Revision: 12951
    Revision: 12951
    Author:   [email protected]
    Date:     2009-12-15 02:17:31 -0800 (Tue, 15 Dec 2009)
    Log Message:
    Changed synchronized PropertyProxyRegistry#getRegistry method to non-synchronized to avoid threads blocking in message push.
    Checkintests: Pass with the usual 3-4 tests that time out with and without this change.
    QA: Yes
    Doc: No
    Modified Paths:
        blazeds/trunk/modules/core/src/flex/messaging/io/PropertyProxyRegistry.java

  • RDBMS non-thread-safe issue

    <snip>
    This (as you probably know) is due to the fact that the code provided by
    most of the DB vendors is not thread safe.
    <snip>
    Sean's comment, above, speaks to an issue that is causing some concern
    within my (large - 180 projects in development) organisation.
    May I please ask the forum if there are others out there who have an
    understanding of / concern with this "problem"?
    My perception (quite possibly flawed) of the "problem" is that the RDBMS
    cannot multi-thread data access objects. So we find ourselves in a situation
    where we can achieve scaleability in just about all other
    performance-sensitive areas of a system's technical architecture (we're
    using DCE -- but have found that Encina is not advisable except where there
    is a true requirement for heterogeneous distributed 2 phase commit, which we
    don't often see.....) but when we go to hit on the RDBMS, we go back to good
    ole single-threading.
    In certain circumstances, this shortfall of RDBMS technology -- I won't
    mention any names, of course, but the initials are "Oracle" -- seems to be
    hindering our achievement of a desired technical architecture.
    Is this a "Pro*C / PL/SQL stored procedures" problem or is it something that
    is in the RDBMSs' DNA?
    How can we get around it?
    Any comments?
    Regards
    Jon

    Jon
    I agree. But it is the best solution within the constraints of existing
    technology. At least we don't use a process per client. 10 replicated
    copies of a service could service the needs of 100 clients.
    Eric
    >
    At 13:15 6/09/96 EST, you wrote:
    Eric
    Thanks for your response. Yep. I realise that the issue I've presented is
    clearly not something that Forte causes or is responsible for in any way.
    Forte can, as you've pointed out, actually help in this area. But I don't
    think that getting Forte to spawn another instance of a data access server
    is really the best solution. Ie, that's not what we tend to have in mind
    when we think about "scaleability". The best solution is -- perhaps -- to
    get the RDBMS people to thread-safe all code and libraries. I have pointedly
    asked Oracle for a position on this -- and got the usual blank stare.
    I also considered whether people might get upset at me for posting what is
    clearly a non-Forte-specifc question in a Forte forum. But then I went ahead
    and did it anyway. Justification being (assumption follows) that the kind of
    people who hang out on the Forte forum may tend to be more
    architecture-oriented than your run of the mill VB / SQL*Net / PL/SQL stored
    procedures kinda guy/gal, and may be using or considering Forte (plug for
    Forte follows) precisely because it clearly enables a superior architecture.
    Should proably post to the comp.database.oracle forum, but I just don't know
    them as well.
    Regards
    Jon
    From: Eric Gold
    To: McLeod, Jon
    Cc: [email protected]
    Subject: Re: RDBMS non-thread-safe issue
    Date: Friday, 6 September 1996 11:21AM
    Jon
    In response to this message.....read below...
    Sean's comment, above, speaks to an issue that is causing some concern
    within my (large - 180 projects in development) organisation.
    May I please ask the forum if there are others out there who have an
    understanding of / concern with this "problem"?
    My perception (quite possibly flawed) of the "problem" is that the RDBMS
    cannot multi-thread data access objects. So we find ourselves in a situation
    where we can achieve scaleability in just about all other
    performance-sensitive areas of a system's technical architecture (we're
    using DCE -- but have found that Encina is not advisable except where there
    is a true requirement for heterogeneous distributed 2 phase commit, which we
    don't often see.....) but when we go to hit on the RDBMS, we go back to good
    ole single-threading.
    In certain circumstances, this shortfall of RDBMS technology -- I won't
    mention any names, of course, but the initials are "Oracle" -- seems to be
    hindering our achievement of a desired technical architecture.
    Is this a "Pro*C / PL/SQL stored procedures" problem or is it something that
    is in the RDBMSs' DNA?
    How can we get around it?
    Any comments?Jon,
    Go ahead ask the Forum any questions you want. This "problem"
    is not a problem in Forte. What we allow you to do is "replicate" your
    data access services so that each one runs inside its own
    process. Each one of these processes (aka partitions) has its
    own connection to the database. The routing to the replicated
    partitions is transparent to the clients. Clients send a
    message like "DatabaseService.GetCustomer()" and then the Forte
    router sees which replicated copy of the service is not currently
    processing a request and routes it to that free replicate. You
    can dynamically increase or decrease the number of replicated
    copies of the service easily.
    We call this feature "load balancing" in Forte. It is achieved
    by checking a box in the data access service object definition.
    You can dynamically increase/decrease the number of replicates
    and also dynamically move replicates to other nodes in the environment.
    This approach assumes that you are using application driven
    security and not database security. Each replicated copy
    of the service is using the same generic username/password
    to connect to the database.
    I am forwarding this answer to forte-users because others
    might not completely understand this feature.
    Eric
    Eric Gold
    Technical Director
    Forte Australia
    Voice: 61-2-9926-1403
    Fax: 61-2-9926-1401
    Eric Gold
    Technical Director
    Forte Australia
    Voice: 61-2-9926-1403
    Fax: 61-2-9926-1401

  • Thread Blocked Problem

    I Have a multithread application which:
    - access to database
    - write files
    - read files
    - execute external process using exec
    What considerations should I take in order to avoid Threads Blocking? When Thread blocking occurs how can I know what is the cause?
    Thanks!
    T

    http://www.ibm.com/developerworks/library/j-thread.html
    - Saish

  • Why happens when  threads block on I/O?

    I want to know what are the reasons for threads blocking on I/O.Do they block to allow the I/O operation or do they block(enter in waiting state) to allow other threads to continue operation while I/O opeation ?
    If a particular thread is blocked for I/O do other threads get a chance by the Thread Scheduler ?
    If this question has been asked and answered somewhere ,kindly let me know so that i can follow that thread.
    Thanks for your consideration.

    >
    Which thread is that which is "suspended"? The thread which is blocked waiting for the I/O will, um, wait for the I/O. That means it doesn't do anything else. It just waits. That's all. Is that not obvious?
    The "suspended" one is the one which is blocked waiting for the I/O.My question is when say the I/O is complete or the stream closes,won't the thread start executing again if given a chance by the scheduler ?
    Of course that doesn't affect any other threads. And what do you mean by "related to this thread"? There's no such concept. Each thread operates independently, except when they interact by holding locks or waiting for locks.
    "Related to this thread" means thread that share some common resources or say locks.Here i meant any other thread than the one which is blocked for I/O.
    Seems to me your mental model of threads is far too complicated. You need to get rid of all those imaginary concepts you're trying to insert there.That is what i am trying to simplify !!!!

  • Thread Blocking..help

    Hi All,
    I'm finding it hard to understand the concept of Threads blocking, for example, when u have a UI u'll want to run your main work in a different thread than in the event dispatcher thread as that will speed things up with the GUI.
    now let's say we have the following code:
    //Thread to prevent blocking and return control to GUI
    Runnable r = new Runnable() {
    public void run() {
    try
    ThreadThatDoesAlotOfWork.start();
    } catch (Exception e)
    e.printStackTrace();
    if I'll run it within a another thread within the GUI, howcome it doesn't block till all work is done?
    could u provide some code for blocking/non blocking threads..
    can u direct me maybe to helpfull docs somewhere..
    Thanks for the help and hope I'm being clear with my question..

    That article is about synchronisation access to variables by mutiple threads.
    I'm talking about using Threads for speeding things up...
    Thanks for the reply anyway..

  • Archiver  Issue| Automatic replication process | Archiver thread blocking

    Hi,
    Recently, we are facing a strange issue with Archiver auto replication process. Sometime, archiver thread is blocking and auto replication is stalling. We observed this issue after we apply latest OUCM patches downloded from Oracle support site.
    As an work around, we are doing UCM restart.
    Anybody got this kind off issue? We are following this up with Oracle in parallel. Any help regarding this is highly appreciated.
    Gowtham J

    What version/patch set/core update of UCM are you using?
    Jonathan
    http://redstonecontentsolutions.com
    http://corecontentonly.com

  • Client threads block forever in SSLSocketImpl.startHandshake

    Hi --
    We have an application which has 4 threads polling a webservice over HTTPS every 1-2 minutes. We don't control the server platform or webservice framework.
    We've encountered a problem where one by one the threads stop polling. This has occurred 3 times, every time over a weekend (the busiest time for our polling). Each thread "freezes" at a different time; all 4 threads are "frozen" after about 24 hours.
    JVM thread dumps suggests that the polling threads are blocked inside SSLSocketImpl.startHandshake; each one always has the same stacktrace within the JSSE & Axis libraries:
    "SOAP Client Thread: Footy Feed" prio=5 tid=0x2877D388 nid=0x518 runnable [2c3af000..2c3afd8c]
         at java.net.SocketInputStream.socketRead0(Native Method)
         at java.net.SocketInputStream.read(SocketInputStream.java:129)
         at com.sun.net.ssl.internal.ssl.InputRecord.a(DashoA6275)
         at com.sun.net.ssl.internal.ssl.InputRecord.read(DashoA6275)
         at com.sun.net.ssl.internal.ssl.SSLSocketImpl.a(DashoA6275)
         - locked <0A931078> (a java.lang.Object)
         at com.sun.net.ssl.internal.ssl.SSLSocketImpl.j(DashoA6275)
         - locked <0A931068> (a java.lang.Object)
         at com.sun.net.ssl.internal.ssl.SSLSocketImpl.startHandshake(DashoA6275)
         at org.apache.axis.components.net.JSSESocketFactory.create(JSSESocketFactory.java:186)
         at org.apache.axis.transport.http.HTTPSender.getSocket(HTTPSender.java:131)
         at org.apache.axis.transport.http.HTTPSender.writeToSocket(HTTPSender.java:370)
         at org.apache.axis.transport.http.HTTPSender.invoke(HTTPSender.java:88)
         at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
         at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
         at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
         at org.apache.axis.client.AxisClient.invoke(AxisClient.java:147)
         at org.apache.axis.client.Call.invokeEngine(Call.java:2719)
         at org.apache.axis.client.Call.invoke(Call.java:2702)
         at org.apache.axis.client.Call.invoke(Call.java:2378)
         at org.apache.axis.client.Call.invoke(Call.java:2301)
         at org.apache.axis.client.Call.invoke(Call.java:1758)
    ...(our application stacktrace)...
    Client: JDK1.4.1-b21, JBoss 3.2.7RC1, Axis 1.2RC2, Win2k Server SP4, no client certificates
    Server: Apache 1.3.29 (Unix) mod_ssl 2.8.16 OpenSSL 0.9.6j, mod_jk to Tomcat.
    There's at least one firewall between client and server.
    This problem appears similar: <http://issues.apache.org/bugzilla/show_bug.cgi?id=31832> & I've emailed the author.
    I've googled a lot of forums for a solution without success.
    Any help gratefully received.
    Thanks
    -- Richard Barnett

    Thanks for the reply.
    This case is different from that JMeter bug report as it's a SOAP request.
    We're not explicitly setting a timeout, but Axis defaults to a 10 minute timeout on its requests. The source seems to indicate that this doesn't apply when creating SSL sockets (although it is used when creating regular sockets). No timeout occurs in any case.
    -- Richard

  • Session variable and initialization block issues

    We are using OBIEE 10.1.3.3 and utilizes built in security features. (No LDAP or other single sign on). The user or group names are not stored in any external table. I have a need to supplement Group info of the user to the usage tracking we implemented recently as the NQ_LOGIN_GROUP.RESP column contains username instead of group name. So I created a session variable and associated with a new initialization block and also had a junk default value set to the variable. In the initialization block, I wrote the following query and as a result it inserted correct values into the table when the TEST button was clicked from the initialization block form.
    insert into stra_login_data (username, groupname, login_time) values ('VALUEOF(NQ_SESSION.USER)', 'VALUEOF(NQ_SESSION.GROUP)', SYSDATE)
    My intention is to make this execute whenever any user logs on. The nqserver.log reports the following error and it doesn?t insert values into the table.
    [nQSError: 13011] Query for Initialization Block 'SET_USER_LOGIN_BLOCK' has failed.
    [nQSError: 23006] The session variable, NQ_SESSION.USER, has no value definition.
    [nQSError: 13011] Query for Initialization Block 'SET_USER_LOGIN_BLOCK' has failed.
    [nQSError: 23006] The session variable, NQ_SESSION.GROUP, has no value definition.
    When I changed the insert statement as below, this does get populated whenever someone logs in. But I need the values of GROUP associated with the user as defined in the repository.
    insert into stra_login_data (username, groupname, login_time) values ('TEST_USER', TEST_GROUP', SYSDATE)
    Could someone help me out! As I mentioned above, I need the GROUP info into the usage tracking. So, if there is another successful approach, could you please share?
    Thank you
    Amin

    Hi Amin,
    See [this thread|http://forums.oracle.com/forums/thread.jspa?messageID=3376946&#3376946]. You can't use the GROUP session variable in an Init Block unless it has been seeded from an Init Block first. There isn't an easy solution for what you want, but here are some options:
    1) Create a copy of your User => Groups assignments in your RPD in an table so you can use it in your Usage Tracking Subject Area. But this means you will have to replicate the changes in two places so it's not a good solution.
    2) As the GROUP session variable is populated when you login you could theoretically use it a Dashboard and pass it a parameter to write the value to the database. But as I am not sure how can you make fire only once when the user logins it sounds like a bad idea.
    3) Move your User => Groups assignments from your RPD to a DB table. Use OBIEE Write Back or something like Oracle APEX to maintain them.
    I think 3) is the best solution to be honest.

Maybe you are looking for

  • Animated gif icon for an exception instead of the standard icon?

    Hello, is there a possibillity to use an animated gif icon for an exception instead of the red standard icon in a web template? I tried  to change the standard icon s_s_ledr.gif against an animated gif icon in the mime repository, but it does not wor

  • Sharing iphoto library in Shared folder - so frustrated!

    I am so frustrated trying to put the iPhoto Library in the Shared folder, in order to give all users Read & Write access. It worked for about a month, and now my wife suddenly is getting lots of permission problems. I tried making her the "owner" of

  • Apps not downloading - they start then drop out

    I trawled through all the forums/discussions and questions on the support communities but are yet to find a solution. In brief: I am overseas but usually based in the UK (not sure this will have any bearing on the issue but still), my apps on my iPho

  • File sync error after renaming jpg file on desktop

    I changed the file name of a photo in my desktop backup of my Treo 755p photos from the default format of Photo_[date]_xyz.jpg to Matisse by fire2_101208.jpg. The path is: C:\Program Files\Palm\[username]\Photos\offline copy location\7dba\Palm on Car

  • Disabling spotlight for Time Capsule

    Hi, I need to disable (please do not ask the reason, I just need) indexing for backups on the Time Capsule. I know that the help on Spotlight says Time Machine needs spotlight bla bla... and, it can't disable indexing for this. I just don't beleive i