Weblogic's thread management

Hi, I'm thinking on some issues related to Weblogic thread management.
Suppose I start a thread (either on an startup class or from a servlet) that
I want to perform some background work (I have readed it's out of the specs
to start transactions from a thread launched in a servlet... yea I know it
;) ) well the problem is. How do I know when the Weblogic server is being
shutting down?.
I have seen on Weblogic's console that when an script like the
./stopWeblogic.sh one is executed it calls a Weblogic method in order to do
that... then the Weblogic starts to destroy servlets, undeploys EJBs and, at
the end a message like "Waiting 20 seconds for threads to stop" or something
like that is written to the console.
The question is, how does Weblogic notify the running threads that they
should stop?, will it work for a thread launched in a startup class or from
a servlet?, does the thread has to extend from an special Weblogic class?.
If this isn't possible, would it work overriding the destroy() method of the
servlet to call a method of the thread that stops it properly?. I know it
will be called anytime the webapp is redeployed or if the servlet is hot
reloaded, but it's fine to me.
Thanks in advance, regards
Ignacio.

Hi, I'm thinking on some issues related to Weblogic thread management.
Suppose I start a thread (either on an startup class or from a servlet) that
I want to perform some background work (I have readed it's out of the specs
to start transactions from a thread launched in a servlet... yea I know it
;) ) well the problem is. How do I know when the Weblogic server is being
shutting down?.
I have seen on Weblogic's console that when an script like the
./stopWeblogic.sh one is executed it calls a Weblogic method in order to do
that... then the Weblogic starts to destroy servlets, undeploys EJBs and, at
the end a message like "Waiting 20 seconds for threads to stop" or something
like that is written to the console.
The question is, how does Weblogic notify the running threads that they
should stop?, will it work for a thread launched in a startup class or from
a servlet?, does the thread has to extend from an special Weblogic class?.
If this isn't possible, would it work overriding the destroy() method of the
servlet to call a method of the thread that stops it properly?. I know it
will be called anytime the webapp is redeployed or if the servlet is hot
reloaded, but it's fine to me.
Thanks in advance, regards
Ignacio.

Similar Messages

  • Weblogic Thread Management

    Hello Buddies,
    We are facing performance problem in our J2EE application. For our application, Native Thread Management is enabled(EnableNativeIO=true).
    But, while starting the weblogic server(managed server), we are getting the following message.
    ####<Oct 16, 2008 12:40:25 PM BST> <Warning> <Socket>
    <wrohstsco10> <gc3-wrohstsco10>
    <ListenThread.Default> <<WLS Kernel>> <>
    <BEA-000402> <There are: 9 active sockets, but the maximum
    number of socket reader threads allowed by the configuration is: 8. You
    may want to alter your configuration.>
    Can any one suggest on this?
    Regards
    Senthil Nathan M

    you know that Native IO is enabled if you see "Native IO Enabled" in the server log at startup. This means that it founds the native IO shared libraries at startup.
    You've probably already seen this, but this is from the WebLogic docs, at <http://e-docs.bea.com/wls/docs100/messages/Socket.html>
    <strong>BEA-000402</strong>
    <strong><em>Warning: </em></strong>There are: <em>numSockets</em> active sockets, but the maximum number of socket reader threads allowed by the configuration is: <em>getMaxSocketReaders</em>. You may want to alter your configuration.
    <strong>Description</strong>
    A non-native IO is being used, and the number of
    socket reader threads is less than the number of active sockets.
    Performance may degrade significantly. It is recommended that you
    change the socket reader settings to improve the performance.
    <strong>Cause</strong>
    When non-native IO is used, IO is performed in a
    blocking manner. Therefore, if the number of socket reader threads is
    less than the number of active sockets, performance may degrade
    significantly.
    <strong>Action</strong>
    Increase ThreadPoolPercentSocketReaders and/or
    ThreadPoolSize, and/or decrease SocketReaderTimeoutMinMillis and/or
    SocketReaderTimeoutMaxMillis.
    This would imply what you understand. If you are seeing "Native IO Enabled" in your server log, but you are getting that warning, then I would first simply follow the advice in the message description that applies if you are using non-native IO. After experimenting with that (whether it works or not), I would file a support case asking first why you're getting that warning if you have native IO enabled, and whether following this advice for non-native IO should resolve your problem.

  • Why can't Weblogic 12c find Managed Bean by annotation,which in a jar?

    the detail:
    why can't Weblogic 12c find Managed Bean by annotation,which in a jar?

    Hi,
    I got the same problem with weblogic 12c.
    Somehow this guy got it working by using CDI and creating an empty beans.xml, it did not work for me.
    i found the tricky problem is that should put a empty but include the <beans> tag beans.xml file.
    http://www.coderanch.com/t/562233/JSF/java/WebLogic-Eclipse-Indigo-develop-JSF
    I also tried to skip managedbean and use CDI ( @named ) but then I get some jboss weld exceptions on the value attribute of some jsf components.
    I also saw this post
    Can't seem to get a trivial CDI example to work on Weblogic 12c
    I don't use OEPE very often so I'll need to kick this around a little when I get a chance.
    Just as an out there kind of thought, OEPE does use the split-directory model for deployment by default -- perhaps try adjusting it to use the exploded archive model instead, just as a test to see if it removes the error?
    Right click the server config and select Properties > WebLogic > Publishing > Publish as exploded archive
    It seems like the Virtual Application deployment model of OEPE doesn't support CDI.
    thanks
    Edited by: Edwin Biemond on Dec 28, 2011 10:07 PM
    Edited by: Edwin Biemond on Dec 28, 2011 10:25 PM

  • Automating start / restart of WebLogic Admin and managed servers on MS Windows

    Hi All,
    Please help me to do the automation of start and stop scrip of Oracle Weblogic 10.3.6 and Forms and Reports 11.1.2.2.0(Managed Servers) On Windows server 2008.
    Here are two options for automating start / stop of WebLogic Admin and managed servers on MS Windows. Please suggesst which one is standrad procedure.
    Use NodeManager (installed as a MS Windows Service)
    or 
    Create Windows Service(s) for the server(s) - no NodeManager
    Following Document : 1060058.1
    Please suggest me the best practice. Many thanks in advance.
    Kind Regards,
    Mohan

    Hi Borys,
    Thank you for quick reply...
    If we use the first option "Create Windows Service(s) for the server(s) - no NodeManager" then we will be facing issue Like "Admin Server or Managed Server may go into an unhealthy or failed state but the JVM is still running"
    In the document : 1060058.1 : Mentioned as Important Note: The second option has a limitations.
    Limitaion is below when we use first option : "Create Windows Service(s) for the server(s) - no NodeManager" -
    Windows Services Manager only monitors the JVM process. If the JVM process fails (shuts down), then Windows Services Manager will attempt to restart it. But there are some scenarios where the Admin Server or Managed Server may go into an unhealthy or failed state but the JVM is still running. The Windows Service will not know to restart the process in these cases. If a server is started using NodeManager, NodeManager would recognize such a state and restart the process accordingly. Furthermore, if you start up managed servers via a MS Windows Service, you cannot monitor and/ or stop the managed server via the Weblogic Admin Console and/or Fusion Middleware ( Enterprise Manager ) Control.
    I have implemented the second option "Use NodeManager starting admin and manged servers via WLST script" - Python script. Its working well without issue...No Limitation...
    Script Contains Below :
    print "================== Start scripts of Managed servers and Admin server ======================"
    nmConnect(userConfigFile='D:/myFiles/myuserconfigfile.secure',userKeyFile='D:/myFiles/myuserkeyfile.secure',host='00.0.00.00',port='5556',domainName='ClassicDomain',domainDir='D:\Oracle\Middleware\user_projects\domains\ClassicDomain',nmType='ssl')
    print "================== Adminserver Starting ================================================"
    nmStart('AdminServer')
    connect('weblogic','Password1','10.4.93.117:7001')
    print "================== MANAGED SERVER (FROMS) Starting ====================================="
    start('WLS_FORMS','Server')
    print "================== MANAGED SERVER (REPORTS) Starting ==================================="
    start('WLS_REPORTS','Server')
    exit()
    HOPE WE WILL MEET AGAIN AND AGAIN...
    Many thanks for your comments!
    Kind Regards,
    Mohan

  • Taskdef class  weblogic.ant.taskdef.management.WLdeployn  cannot be found.

    Hi,
    we are deploying war in weblogic server but getting error like taskdef class  weblogic.ant.taskdef.management.WLdeployn  cannot be found.*
    we are creating directory and copying required jars in to that directory and we referening that directory name in classpath of taskdef .
    <!--property defined -->
    <property name="wl_jar" value="${wllib}/weblogic.jar"/>
    <!--copy jars into wllib directory -->
    <target name="copylibs">
    <mkdirdir="wllib"/>
    <copyto dir="wllib" file="weblogic.jar" verbose="true" preservelastmodified="true" />
    </target>
    <!--weblogic taskdef for deploy war on weblogic server. -->
    <taskdef name="wldeploy" classname="weblogic.ant.taskdefs.management.WLDeploy" >
    <classpath >
    <pathelement location="${wl_jar}"/>
    </classpath>
    </taskdef>
    But getting taskdef class weblogic.ant.taskdef.management.WLdeployn cannot be found .
    please give me a solution.
    Thanks,

    Hi
    This error "java.lang.NoClassDefFound weblogic/util/debug" kind of looks familiar while running some standalone Java client programs that refer to stuff deployed on Weblogic. The ideal way to fix is generate wlfullclient.jar and add that in the classpath. Adding or calling setDomainEnv.sh (.cmd) will also work, but try using this wlfullclient approach also. The below post have the links that has all the details.
    Re: Corrupted JAR:C:\workspace\weblogic.jar
    Thanks
    Ravi Jegga

  • Weblogic.developer.interest.management has moved!

    This newsgroup has been relocated. Going forward, please use the weblogic.developer.interest.management newsgroup, which will be located in the [url http://forums.bea.com/category.jspa?categoryID=2004]WebLogic Server/Java EE Newsgroups folder, located at:
    http://forums.bea.com/category.jspa?categoryID=2004.

    Sorry, I miss the right the subject.
    Look for the same message but with the following subject:
    error deploying ejb on wl8.1sp2: trace not help
    regards,
    pedro salazar.

  • Help needed with diagnosis of WebLogic server thread dump

     

    Sorry, my mistake - I was trying to search for "weblogic" before the dump file
    loaded fully.... I am not very familiar with VisiBroker and may be totally
    wrong, but my guess is it creates a thread for each connection/client. I would
    look for VisiBroker properties or settings that could limit the runaway creation
    of threads....
    Arunabh
    "Dimitri I. Rakitine" wrote:
    It is, preceded by lots and lots of CORBA (visibroker) threads. Is it
    possible that application code
    creates new ORBs more often than it should ?
    "Arunabh Hazarika" <[email protected]> wrote in message
    news:[email protected]...
    The attached file does not look like a WebLogic Server thread dump.....
    Arunabh
    Kapil Singh Pawar wrote:
    I am running a web application on WebLogic server 6.0 sp2 + rp1 (HP-UX).
    After
    I start loading the web application with more users I constantly get thejava.lang.OutOfMemoryError.
    I tried increasing the max_thread_proc kernel parameter to 2048 but thatdoes
    not seem to help much. Here is the error that I get on the WebLogicServer console.
    <Oct 7, 2002 5:00:27 PM GMT+02:00> <Error> <HTTP><[WebAppServletContext(1828590,i2)]
    Servlet failed with Exception
    java.lang.OutOfMemoryError: max threads limit being reached in VM
    at java.lang.Thread.start(Native Method)
    at netscape.ldap.LDAPConnThread.<init>(LDAPConnThread.java:112)
    atnetscape.ldap.LDAPConnection.getNewThread(LDAPConnection.java:1117)
    atnetscape.ldap.LDAPConnection.connect(LDAPConnection.java:1034)
    at netscape.ldap.LDAPConnection.connect(LDAPConnection.java:915)
    at netscape.ldap.LDAPConnection.connect(LDAPConnection.java:759)
    atcom.i2.scm.LDAP.ScmLDAPDefaultAuthenticate.authenticate(ScmLDAPDefaultAuthen
    ticate.java:129)
    at scmldap.service(scmldap.java:452)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
    atweblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java
    :213)
    atweblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletCo
    ntext.java:1302)
    atweblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java
    :1676)
    at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:137)
    at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120)
    >
    I am posting the thread dump obtained at the OutOfMemoryError stage. Anyhelp
    in diagnosing the thread dump and possible fix for this error is highlyappreciated.
    For information sake, while the web application encountersOutOfMemoryError the
    example web apps and WebLogic console application work fine. So it looksto be
    a case of memory outage only for my custom application.
    Thanks
    Kapil Singh Pawar
    Name: thread_dump.txt
    thread_dump.txt Type: Plain Text (text/plain)
    Encoding: base64--
    Dimitri

  • NOTICE:  Posts to be moved to weblogic.developer.interest.management

    In an effort to improve support of our newsgroups, we are combining a few of them.
    As of Friday, October 12, this newsgroup will be discontinued. The posts will
    be moved to the following newsgroup: weblogic.developer.interest.management.
    Please post your questions regarding the management console to that newsgroup.
    Thank you,
    Lauren Wright -- WLS Product Manager

    These posts really belongs in the weblogic.developer.interest.weblogicenterprise
    instead...
    "\"Lauren Wright\" lauren.wright" wrote:
    In an effort to improve support of our newsgroups, we are combining a few of them.
    As of Friday, October 12, this newsgroup will be discontinued. The posts will
    be moved to the following newsgroup: weblogic.developer.interest.general. Please
    post your question to that newsgroup.
    Thank you,
    Lauren Wright -- WLS Product Manager

  • Weblogic Threads Management

    Can anybody tell me how weblogic 6 manage threads? When it crerate a thread? When
    the threads finished??
    Or a document where I can read something about it???
    Thanks in advanced

    Creates on startup. Finishes on shutdown.
    Peace,
    Cameron Purdy
    Tangosol, Inc.
    http://www.tangosol.com
    +1.617.623.5782
    WebLogic Consulting Available
    "D. L. I" <[email protected]> wrote in message
    news:3add567b$[email protected]..
    >
    Can anybody tell me how weblogic 6 manage threads? When it crerate athread? When
    the threads finished??
    Or a document where I can read something about it???
    Thanks in advanced

  • NDC and weblogic thread management

    Hi,
    we consider to use the Log4J NDC to log the Session ID of a request. The
    Session ID will be pushed/popped on each request entering weblogic server.
    Log4J binds this kind of information to the current thread. Is it reasonable
    to do this as long as there is no remote call of an EJB (which could be
    executed in another thread or server, of course)?
    Thanks!
    Raphael

    Hi Chuck,
    thanks for your answer. Log4J uses the current WLS thread and does not
    create a new one. Our problem was to know if WLS does some thread switching
    during the execution of a bean method. In that case the "contextual
    information" would be lost. In other words, is it legal to use
    java.lang.InheritableThreadLocal inside a EJB request?
    Bye,
    Raphael
    >
    Raphael,
    Isn't the Nested Diagnostic Context going to use the current WLS executethread
    for 'popping' and 'push' contextual information? In other words, I don'tthink
    it creates a new thread to perform this functionality. If that is thecase, I
    wouldn't think you would have an issue with this technique
    Chuck Nelson
    Developer Relations Engineer
    BEA Technical Support

  • Weblogic server and managed servers sudden shutdown

    Hi,
    when trying to restart both the admin and managed osb servers. after some time the admin and managed servers are getting shut down. This is what the information i got from logs. Appreciate your help in this regard
    ####<Aug 18, 2011 12:51:44 PM EDT> <Info> <Health> <weblogic.GCMonitor> <<anonymous>> <> <8beb4c4d69347bb8:6c6553af:131ddaf5db4:-7ff7-0000000000000011> <1313686304697> <BEA-310002> <38% of the total memory in the server is free>
    ####<Aug 18, 2011 12:52:06 PM EDT> <Error> <JDBC> <[ACTIVE] ExecuteThread: '7' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <8beb4c4d69347bb8:6c6553af:131ddaf5db4:-7ff7-0000000000000109> <1313686326579> <BEA-001112> <Test "SELECT 1 FROM DUAL" set up for pool "GLTOdatasource" failed with exception: "oracle.jdbc.xa.OracleXAException".>
    ####<Aug 18, 2011 12:52:06 PM EDT> <Info> <JDBC> <[ACTIVE] ExecuteThread: '7' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <8beb4c4d69347bb8:6c6553af:131ddaf5db4:-7ff7-0000000000000109> <1313686326580> <BEA-001128> <Connection for pool "GLTOdatasource" closed.>
    ####<Aug 18, 2011 12:52:44 PM EDT> <Info> <Health> <weblogic.GCMonitor> <<anonymous>> <> <8beb4c4d69347bb8:6c6553af:131ddaf5db4:-7ff7-0000000000000011> <1313686364766> <BEA-310002> <61% of the total memory in the server is free>
    ####<Aug 18, 2011 12:56:45 PM EDT> <Info> <Health> <weblogic.GCMonitor> <<anonymous>> <> <8beb4c4d69347bb8:6c6553af:131ddaf5db4:-7ff7-0000000000000011> <1313686605051> <BEA-310002> <44% of the total memory in the server is free>
    ####<Aug 18, 2011 12:58:18 PM EDT> <Info> <Security> <[ACTIVE] ExecuteThread: '6' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <8beb4c4d69347bb8:6c6553af:131ddaf5db4:-7ff7-0000000000000111> <1313686698580> <BEA-090516> <The CredentialMapper provider has preexisting LDAP data.>
    ####<Aug 18, 2011 1:02:23 PM EDT> <Notice> <WebLogicServer> <Thread-1> <<WLS Kernel>> <> <8beb4c4d69347bb8:6c6553af:131ddaf5db4:-7ff7-0000000000000117> <1313686943979> <BEA-000388> <JVM called WLS shutdown hook. The server will force shutdown now>
    ####<Aug 18, 2011 1:02:23 PM EDT> <Alert> <gifosb_admin> <Thread-1> <<WLS Kernel>> <> <8beb4c4d69347bb8:6c6553af:131ddaf5db4:-7ff7-0000000000000117> <1313686943996> <BEA-000396> <Server shutdown has been requested by <WLS Kernel>>
    ####<Aug 18, 2011 1:02:24 PM EDT> <Notice> <WebLogicServer> <Thread-1> <<WLS Kernel>> <> <8beb4c4d69347bb8:6c6553af:131ddaf5db4:-7ff7-0000000000000117> <1313686944005> <BEA-000365> <Server state changed to FORCE_SUSPENDING>
    Thanks,
    Bharath

    <JVM called WLS shutdown hook. The server will force shutdown now>This is your JVM process which is getting killed and hence server is forced to shutdown. On which OS, servers are running? How are you starting the server? If you are on windows, DO NOT close the command prompt through which you started the server.
    Regards,
    Anuj

  • How to increase the Weblogic Session Threads

    Hi Everyone,
    We have been using replicated-if-clustered property of session-descriptor element of weblogic.xml and things were smooth and fine until our application didnt grow. Now there is a heavy traffic on the application and we want to increase the session replication thread count to more then 2 servers. Does anyone have any idea how to go about it? I dont see a way of defining how many servers the session should be replicated. Right now it does on the 2 servers which forms the cluster. Is there really any difference between replicated and replicated-if-clustered property?
    Thanks a Lot in Advance for answering my queries.
    Yogendra N Joshi.

    user13017505 wrote:
    Hi Everyone,
    We have been using replicated-if-clustered property of session-descriptor element of weblogic.xml and things were smooth and fine until our application didnt grow. Now there is a heavy traffic on the application and we want to increase the session replication thread count to more then 2 servers. Does anyone have any idea how to go about it? I dont see a way of defining how many servers the session should be replicated. Right now it does on the 2 servers which forms the cluster. Is there really any difference between replicated and replicated-if-clustered property?
    Thanks a Lot in Advance for answering my queries.
    Yogendra N Joshi.To start with persistent store/session replication options:
    •memory—Disables persistent session storage.
    •replicated—Same as memory, but session data is replicated across the clustered servers.(No Persistent store)
    •replicated_if_clustered—If the Web application is deployed on a clustered server, the in-effect persistent-store-type will be replicated. Otherwise, memory is the default.
    http://download.oracle.com/docs/cd/E12840_01/wls/docs103/webapp/weblogic_xml.html
    Regarding increasing traffic on the servers:
    If there is heavy traffic on the servers and both servers in a cluster are utilized fully, you can add more managed servers to the cluster and load balance the requests amongst them equally.
    The sessions will be replicated across all the servers in a cluster as you have session replication enabled already.
    But for increasing load/traffic we will have to analyze the capacity of the present setup and then add more servers to the cluster as required.
    Regards,
    Swapna

  • Weblogic Kernel Thread Queue - Count

    Kernel thread count is configurable, the kernel thread queue can be configured
    to grow.
    The socket reader threads are a %age of the kernel thread queue. Does it mean
    that the number of socket reader threads (allocated as %age of the kernel threads)
    change as the kernel thread count changes dynamically ?
    thanks,
    Parag

    A [STUCK] thread is a WebLogic managed thread that WebLogic has decided has been busy for too long.  This might be quite normal for a background process or batch process.  It does not necessarily indicate a real problem.  The object allocation and subsequent GC is also normal behaviour.
    So is your thread really stuck or is it just running for longer than WebLogic is configured to expect?  You can use WebLogic thread pool configurations and the CommonJ API to avoid threads being marked as [STUCK] by declaring that they are long running (and assuming you're using a new enough version of WebLogic that honours this - it used to still mark them as [STUCK]).
    If your thread is truly stuck it is more likely to be to do with your code than an object allocation / GC issue.

  • Thread management in servlet

    Here is the problem that i am trying to solve - and get better understanding of issues to look out for.
    1) Problem to solve
    Clients sends an http request to an distributor server. The request contains a list of tasks. Each such task can be sent to a particular handling server (out of a known set) which can handle the request. Each task has a task type, which identifies which server the request needs to be passed to. The responses from the handler servers are then to be collected and passed back the client as a consolidated response.
    On the distributor server, the servlet thread that is handling the request will
    a. need to spread the requests for various handling servers
    b. send the requests in parallel to handling servers
    b. get all the responses , consolidate and send back
    2)Proposed solution
    I was thinking of having a thread pool - one thread for each handling server, initialized within servlet . When the distributor server receives a request - the tasks would be spread to these handling threads. The distributor thread would then wait, until the handling threads notify.
    When a notification is received - the distributor thread will need to check if all responses are received. If not - it would need to wait (till a max_timeout) else return the response to client
    3)Questions
    - This involves waiting on the thread created by serlvet container (the distributor thread) and creating a threadpool. Thread creation and management by application in web-container is generally dissuaded - but given this issue - i see no other alternative
    suggestions ? Its been a long email - thanks for considering
    Fred

    How many clients for the entry server do you presume for the application ? I ask this because it is very possible that the server to remain without available threads and give errors. If you use different servers for the final requests I suppose that are some very time consuming processes. What kind of application are running on these servers so that you want to use this kind of distributed computing ?
    Why did you choose as an entry point a servlet container and http request for this kind of problem ? Do you need a graphic response in the browser ? If the response time is too long, the browser (Internet Explorer) will show exception and will not wait for the response (for this you must set some variabiles on client). Also the J2EE server must be set so that not to throw a time-out exception.
    To prevent these, you could do so that not to block the distributor thread and let it send the answer back to the client. Then you can tell to client browser to query the server from time to time to check the status of the execution (you can do that from javascript). When the execution is ready you can retrun the response to the client. Doing this way you will not block the application server threads.
    Now in the back end, you must somehow to take some identificators from the processes and sent them back to the client.
    You can use a database to make the bridge between the central server and the other processes (here you can put the processes identificators). When the processes end up they update their results in the database.
    The client, when will make the repetitive requests, will check the status of the processes in the database with given identificators.
    Sounds like an interesting project.

  • Weblogic Explicit Transaction Management

    Hi,
    I am in need of managing mutiple transactions which access two different databases which are not Oracle (NON XA) but still I want to implement 2 Phase Commit.
    I read documents about JTA, and tried to use TransactionManager . But I am not able to create a XaResource with my weblogic JNDI lookup. It is just return a type cast exception saying not able to convert form RmiDataSource to XaDataSource. Transaction class's enlistResource() method only accepts XaReource. Can you suggest a solution for acheving mutiple database transactions to be commited or rolledback as per need. In shot how to manage transactions explicitly in Weblogic 10.

    OK, now I'm catching up. Do you see that exception thrown in your calling
    code, i.e. does your code as posted catch that exception?
    If so, you most probably are not using the proper connection pool -- you
    should be using the JTS pool not just a WL pool -- and so the connection is
    not participating in the transaction.
    Peace,
    Cameron Purdy
    Tangosol Inc.
    Tangosol Coherence: Clustered Coherent Cache for J2EE
    Information at http://www.tangosol.com/
    "Sunil Naik" <[email protected]> wrote in message
    news:3c26a505$[email protected]..
    >
    "Cameron Purdy" <[email protected]> wrote:
    Why do you say it is not working? Do you get a compile error? An
    exception?
    A partial commit? Deadlock? Horse head in your bed? Out of memory?
    Peace,
    Hi Cameron,
    Actually , while testing the method ,I am deliberately making the3 rd
    method call throw an Exception and exit.In that case what I expect is thatthe
    work done in the first two method calls should be rolled back. i.e.Therows should
    not be inserted in the database.This is not happening.The inserts made inthe
    earlier two methods are being commited.
    Hope it is clear now.
    Thanx,
    sunil
    Cameron Purdy
    Tangosol Inc.
    Tangosol Coherence: Clustered Coherent Cache for J2EE
    Information at http://www.tangosol.com/
    "Sunil Naik" <[email protected]> wrote in message
    news:3c230f17$[email protected]..
    Hi,
    I have written a StatelessSession Bean. There is a method in thisbean
    which
    calls methods of Other BMP Beans.All these methods have to be partof one
    Transaction.Below
    I have shown in Pseudocode ,how I am handling it.
    //This is the SessionBean Method
    public void processDocument()
    UserTransaction Utrx = SessionContext.getUserTransaction();
    try
    Utrx.begin();
    Bean1.method1();//this method inserts a row in the database
    Bean2.method2();// this method inserts a row in another table
    Bean3.method3();//deletes a row
    // couple of other method calls
    Utrx.commit();
    catch()
    //catch Exceptions and rollback.

Maybe you are looking for

  • How to delete a report from SAP BO?

    is there a way to delete a report from SAP BO that won't be right clicking on it, organize, then delete. Something from the database because I have a report that for some reason has more than 2 million iterations trying to run and is making my server

  • PE02(functions and rules)!!

    hi can we use function(custom) in the rule and pass the parameters at run  time like we do in case of operation(ie in the rule itself..eg zcustX...where X is an indicator)?

  • When trying to open reader - An internal error occurred

    I have just downloaded Acrobat Reader X 10 to my laptop, which is running Windows Vista. When I try to open the program, either through the menus, or by trying to open a pdf document, I ger the message "An internal error occurred". No other informati

  • How to run file-to-file scenario

    Hello, I have just done my first exercise in XI, File-to-File Scenario. I ran the scenario in RWB in Component Monitoring by giving the Payload from the Message Mapping.  It ran successfully. But I am not able to run the same scenario by giving my so

  • Custom Finders

    Is it possible to implement a finder that achieves "Select from myTable where id1='abc' and id2='def' and id3='ghi'" The number of arguments in where being variable (i.e 1 to 3). I tried using a finder with the following EjbQL "SELECT OBJECT(p) FROM