NON-transactional session bean access entity bean

We are currently profiling our product using Borland OptmizeIt tool, and we
found some interesting issues. Due to our design, we have many session beans which
are non transactional, and these session beans will access entity beans to do
the reading operations, such as getWeight, getRate, since it's read only, there
is no need to do transaction commit stuff which really takes time, this could
be seen through the profile. I know weblogic support readonly entity bean, but
it seems that it only has benefit on ejbLoad call, my test program shows that
weblogic still creates local transaction even I specified it as transaction not
supported, and Transaction.commit() will always be called in postInvoke(), from
the profile, we got that for a single method call, such as getRate(), 80% time
spent on postInvoke(), any suggestion on this? BTW, most of our entity beans are
using Exclusive lock, that's the reason that we use non-transactional session
bean to avoid dead lock problem.
Thanks

Slava,
Thanks for the link, actually I read it before, and following is what I extracted
it from the doc:
<weblogic-doc>
Do not set db-is-shared to "false" if you set the entity bean's concurrency
strategy to the "Database" option. If you do, WebLogic Server will ignore the
db-is-shared setting.
</weblogic-doc>
Thanks
"Slava Imeshev" <[email protected]> wrote:
Hi Jinsong,
You may want to read this to get more detailed explanation
on db-is-shared (cache-between-transactions for 7.0):
http://e-docs.bea.com/wls/docs61/ejb/EJB_environment.html#1127563
Let me know if you have any questions.
Regards,
Slava Imeshev
"Jinsong HU" <[email protected]> wrote in message
news:[email protected]...
Thanks.
But it's still not clear to me in db-is-shared setting, if I specifiedentity
lock as database lock, I assumed db-is-shared is useless, because foreach
new
transaction, entity bean will reload data anyway. Correct me if I amwrong.
Jinsong
"Slava Imeshev" <[email protected]> wrote:
Jinsong,
See my answers inline.
"Jinsong Hu" <[email protected]> wrote in message
news:[email protected]...
Hi Slava,
Thanks for your reply, actually, I agree with you, we need to
review
our db
schema and seperate business logic to avoid db lock. I can not say,guys,
we need
to change this and that, since it's a big application and developedsince
EJB1.0
spec, I think they are afraid to do such a big change.Total rewrite is the worst thing that can happen to an app. The
better aproach would be identifying the most critical piece and
make a surgery on it.
Following are questions in my mind:
(1) I think there should be many companies using weblogic serverto
develop
large enterprise applications, I am just wondering what's the maintransaction/lock
mechanism that is used? Transional session / database lock,
db-is-shared
entity
I can't say for the whole community, as for my experience the standard
usage patthern is session fasades calling Entity EJBs while having
Required TX attribute plus plain transacted JDBC calls for bulk
reads or inserts.
is the dominant one? It seems that if you speficy database lock,
the
db-is-shared
should be true, right?Basically it's not true. One will need db-is-shared only if thereare
changes
to the database done from outside of the app server.
(2) For RO bean, if I specify read-idle-timeout to 0, it shouldonly
load
once at the first use time, right?I assume read-timeout-seconds was meant. That's right, but if
an application constantly reads new RO data, RO beans will be
constantly dropped from cache and new ones will be loaded.
You may want to looks at server console to see if there's a lot
of passivation for RO beans.
(3) For clustering part, have anyone use it in real enterpriseapplication?
My concern, since database lock is the only way to choose, how aboutthe
affect
of ejbLoad to performance, since most transactions are short live,if high
volume
transactions are in processing, I am just scared to death about
the
ejbLoad overhead.
ejbLoad is a part of bean's lifecycle, how would you be scared ofit?
If ejbLoads take too much time, it could be a good idea to profile
used SQLs. Right index optimization can make huge difference.
Also you may want cosider using CMP beans to let weblogic
take care about load optimization.
(4) If using Optimization lock, all the ejbStore need to do
version
check
or timestamp check, right? How about this overhead?As for optimistic concurrency, it performs quite well as you can
use lighter isolation levels.
HTH,
Slava Imeshev
"Jinsong Hu" <[email protected]> wrote in message
news:[email protected]...
We are using Exclusive Lock for entity bean, because of we do
not
want
to
load
data in each new transaction. If we use Database lock, that means
we
dedicate
data access calls to database, if database deadlock happens,
it's
hard
to
detect,
while using Exclusive lock, we could detect this dead lock in
container
level.
The problem is, using Exclusive concurrency mode you serialize
access to data represented by the bean. This aproach has negative
effect on ablity of application to process concurrent requests.As
a
result the app may have performance problems under load.
Actually, at the beginnning, we did use database lock and usingtransactional
The fact that you had database deadlocking issues tells that
application logic / database schema may need some review.
Normally to avoid deadlocking it's good to group database
operations mixing in updattes and inserts into one place so
that db locking sequence is not spreaded in time. Moving to
forced serialized data access just hides design/implementation
problems.
session bean, but the database dead lock and frequent ejbLoad
really
kill
us,
so we decided to move to use Exclusive lock and to avoid dead
lock,
we
change
some session bean to non-transactional.Making session beans non-transactions makes container
creating short-living transactions for each call to entity bean
methods. It's a costly process and it puts additional load to
both container and database.
We could use ReadOnly lock for some entity beans, but since weblogicserver will
always create local transaction for entity bean, and we found
transaction
commit
is expensive, I am arguing why do we need create container leveltransaction for
read only bean.First, read-only beans still need to load data. Also, you may seeRO
beans
contanly loading data if db-is-shared set to true. Other reason
can
be
that
RO semantics is not applicable the data presented by RO bean (forinstance,
you have a reporting engine that constantly produces "RO" data,
while
application-consumer of that data retrieves only new data and neverasks
for "old" data). RO beans are good when there is a relatively stable
data
accessed repeatedly for read only access.
You may want to tell us more about your app, we may be of help.
Regards,
Slava Imeshev
I will post the performance data, let's see how costful
transaction.commit
is.
"Cameron Purdy" <[email protected]> wrote:
We are currently profiling our product using Borland
OptmizeIt
tool,
and we
found some interesting issues. Due to our design, we have
many
session
beans which
are non transactional, and these session beans will access
entity
beans
to
do
the reading operations, such as getWeight, getRate, since
it's
read
only,
there
is no need to do transaction commit stuff which really takes
time,
this
could
be seen through the profile. I know weblogic support readonly
entity
bean,
but
it seems that it only has benefit on ejbLoad call, my test
program
shows
that
weblogic still creates local transaction even I specified
it
as
transaction not
supported, and Transaction.commit() will always be called
in
postInvoke(),
from
the profile, we got that for a single method call, such as
getRate(),
80%
time
spent on postInvoke(), any suggestion on this? BTW, most of
our
entity
beans are
using Exclusive lock, that's the reason that we use
non-transactional
session
bean to avoid dead lock problem.I am worried that you have made some decisions based on an improper
understand of what WebLogic is doing.
First, you say "non transactional", but from your description
you
should
have those marked as tx REQUIRED to avoid multiple transactions
(since
non-transactional just means that the database operation becomesits
own
little transaction).
Second, you say you are using exclusive lock, which you shouldonly
use
if
you are absolutely sure that you need it, (and note that it
does
not
work in
a cluster).
Peace,
Cameron Purdy
Tangosol, Inc.
http://www.tangosol.com/coherence.jsp
Tangosol Coherence: Clustered Replicated Cache for Weblogic
"Jinsong Hu" <[email protected]> wrote in message
news:[email protected]...
>

Similar Messages

  • Declarative Transactions, Session Beans & JDBC

    Hi (this is really a newbie question),
    If I executed an SQL Update statement in a Stateless Session Bean via JDBC,
    is my call to the database enlisted in the container transaction
    automatically? (Of course, I am assuming the correct TxRequired settings
    are set on the deployment descriptors for the Session Bean.)
    Asked in another way, how does JDBC "talk" to the EJB container to let it
    know that it is being called within a Transactional Context and that all
    activities with the database should then be enlisted in a transaction
    automatically? Where does this "smartness" come in? Or does this not happen
    at all - do I have to "obtain" the JDBC connection object from the EJB
    container instead of writing directly to JDBC?
    Thanks in advance,
    Abdullah Kauchali

    Correct.
    I'd also recommend (where possible), doing the DataSource JNDI lookup in
    your setSessionContext method and storing it away in a member variable.
    There's usually no reason to do it on every method call.
    -- Rob
    Abdullah Kauchali wrote:
    Okay,
    After some investigations, this is what I've learned:
    1. To get automatic transactional enlistment (in a distributed tx), you
    have to make your EJB container aware of the JDBC datasource (viz. you have
    to create a Transactional DataSource). This is done by creating necessary
    entries in a configuration XML file so that the container can connect to the
    JDBC datasource when fired-up;
    2. You then only create your Connection object via a reference (JNDI to be
    exact) to the connection object and NOT directly with JDBC (this was my
    confusion in fact). Something like this:
    //obtain the conduit to the JNDI resource manager factory
    javax.sql.DataSource objDS = (javax.sql.DataSource)
    context.lookup("~some jndi
    reference~");
    //now get the connection object - notice no "javax" but "java"
    java.sql.Connection objCon = objDS.getConnection();
    3. By doing 2. above you are actually using a "Resource Manager Connection
    Factory" to get your Connection object for subsequent SQL Updates;
    4. As long as your JDBC driver supports the javax.sql.DataSource interface
    and provided Transactional Context is propagated from any root call to your
    worker Session Bean, you get automatic transaction enlistment of the SQL
    Updates with your EJB container;
    Please correct me if I have concluded wrongly,
    Regards
    Abdullah
    "Abdullah Kauchali" <ak@ak> wrote in message
    news:[email protected]...
    Hi (this is really a newbie question),
    If I executed an SQL Update statement in a Stateless Session Bean viaJDBC,
    is my call to the database enlisted in the container transaction
    automatically? (Of course, I am assuming the correct TxRequired settings
    are set on the deployment descriptors for the Session Bean.)
    Asked in another way, how does JDBC "talk" to the EJB container to let it
    know that it is being called within a Transactional Context and that all
    activities with the database should then be enlisted in a transaction
    automatically? Where does this "smartness" come in? Or does this nothappen
    at all - do I have to "obtain" the JDBC connection object from the EJB
    container instead of writing directly to JDBC?
    Thanks in advance,
    Abdullah Kauchali

  • Message redelivery with non-transactional message bean JMS standard or weblogic standard?

    It is my understanding (or maybe my assumption) that a message is
              re-queued only if the transaction attribute of a container-managed
              message bean is set to "Required" and the message is PERSISTENT. So if
              it's set to "NotSupported", and thus, message receival is not within a
              transaction, the message would be un-queued and thus never be
              redelivered, should a failure occur within the bean. I discovered that
              even if the message bean is set as "NotSupported", should a failure
              occur within the bean, the message is re-queued to be received again
              at a later time.
              I'm very confused as to whether this mechanism is a JMS standard, or a
              feature of Weblogic. Well, maybe I'm just confused about message
              delivery/re-delivery. I understand that the JMS standard requires
              guaranteed delivery of a message to a receiver. Does this mean a
              message is only considered delivered if an acknowledgement is
              received, regardless of the transaction level? In other words, is the
              JMS standard that a message is considered delivered only if
              acknowledgement is indicated through the container, regardless of the
              transaction level of the message bean itself?
              

    You're right on the second part. That is, a JMS message is not considered to
              be "delivered" until it is acknowledged. There are a number of ways to make
              this happen when programming to the raw JMS API -- a look at the Javadoc for
              JMS or a good JMS book should clarify how to do this.
              With a message-driven bean, the EJB container acknowledges the message after
              you've successfully returned from the "onMessage" method. If you throw a
              RuntimeException from the "onMessage" method, or if it's an MDB with a
              transaction mode of "Required" and you call "setRollbackOnly" on the
              "MessageDrivenContext" object -- then your message will be redelivered.
              Regardless of how a message is acknowledged, if it's not acknowledged then
              it will be redelivered. This has nothing to do with whether the message is
              persistent. The difference is that if a message is persistent, then the JMS
              server is required to keep a copy on stable storage until the message is
              acknowledged so that if the JMS server itself crashes, the message will not
              be lost. For a non-persistent message, on the other hand, if the JMS server
              crashes, then the message may be lost.
              greg
              "Justin" <[email protected]> wrote in message
              news:[email protected]...
              > It is my understanding (or maybe my assumption) that a message is
              > re-queued only if the transaction attribute of a container-managed
              > message bean is set to "Required" and the message is PERSISTENT. So if
              > it's set to "NotSupported", and thus, message receival is not within a
              > transaction, the message would be un-queued and thus never be
              > redelivered, should a failure occur within the bean. I discovered that
              > even if the message bean is set as "NotSupported", should a failure
              > occur within the bean, the message is re-queued to be received again
              > at a later time.
              >
              > I'm very confused as to whether this mechanism is a JMS standard, or a
              > feature of Weblogic. Well, maybe I'm just confused about message
              > delivery/re-delivery. I understand that the JMS standard requires
              > guaranteed delivery of a message to a receiver. Does this mean a
              > message is only considered delivered if an acknowledgement is
              > received, regardless of the transaction level? In other words, is the
              > JMS standard that a message is considered delivered only if
              > acknowledgement is indicated through the container, regardless of the
              > transaction level of the message bean itself?
              

  • Use transacted session in MDB

              Hi,
              If I use transacted session in MDB with container managed transaction, dose the
              weblogic ignore the transacted setting or start in it's own transaction. I looked
              the JMS Tutorial from Sun, the J2EE server just ignore the transacted setting,
              treated it as non-transacted session.
              Thanks
              

              Thanks, Greg. I created another XAQCF in MQ JMSADMIN, but still did not help. The
              strange part is when this exception happens, in the Event Viewer there is a Message:
              An internal Websphere MQ Error has occurred'. In the Trace Log of MQ, the Major
              Error Code reported is arcE_XAER_PROTO.
              Has anyone encountered this error? The same code works fine when enlist an XAQCF
              defined in Weblogic and PUT into a Weblogic JMS Queue instead within the same
              XA Transaction. I am attaching the stack trace to this message, just in case,
              someone has useful pointers to help me. May be this is MQ Specific though I made
              sure I have the latest FixPack for MQ installed.
              Thanks,
              Sridhar
              "Greg Brail" <[email protected]> wrote:
              >Yeah. This comes up from time to time. MQ is upset because it wants to
              >be
              >enlisted in the JTA transaction, but JTA is not enlisting it because
              >it
              >thinks it's already enlisted. It thinks it's already enlisted because
              >the
              >same MQ connection factory was used for the MDB input queue, even though
              >it's a different JMS connection and session.
              >
              >You can avoid this by creating another "XAQCF" object in the MQ JNDI
              >space
              >and giving it a different name. If you do that -- essentially use different
              >connection factories for the MDB's input and output queues -- then this
              >will
              >work.
              >
              >Also, the transaction enlistement code in 8.1 that supports the
              >"resource-ref" feature avoids this problem.
              >
              > greg
              >
              >"Sridhar Krishnaswamy" <[email protected]> wrote in message
              >news:[email protected]...
              >>
              >> Hi Greg:
              >> I assume you meant to getXAResource() from an Object of type
              >XAQueueSession. Here
              >> is the code I tried within the onMessage() method of the MDB:
              >>
              >> XAQueueConnectionFactory factory = (XAQueueConnectionFactory)
              >ctx.lookup("XAQCF")
              >> ;
              >> XAConnection connection = factory.createXAQueueConnection() ;
              >>
              >> XAQueueSession mqSession = connection.createXAQueueSession() ;
              >> XAResource mqResource = mqSession.getXAResource() ;
              >> Transaction tran = TxHelper.getTransaction() ;
              >> tran.enlist(mqResource) ;
              >>
              >> //Then I was going to get the QueueSession Object from XAQueueSession,
              >obtain
              >> the Queue
              >> //Object from JNDI, create the Sender
              >> //and call the send. But I commented out these calls. Even then, after
              >the
              >onMessage
              >> Method
              >> // completes, I get the following error:
              >>
              >> javax.transaction.SystemException: start() failed on resource
              >'com.ibm.mq.MQXAResource':
              >> XAER_PROT : Routine was invoked in an improper context
              >> javax.transaction.xa.XAException: XA Operation failed. see errorcode
              >(which I
              >> am assuming is XAER_PROT).
              >>
              >> Any idea, what I am doing wrong?
              >>
              >>
              >>
              >>
              >> "Greg Brail" <[email protected]> wrote:
              >> >In 7.0, you can do your MQ "put" inside the same JTA transaction that
              >> >was
              >> >used to receive the message for the MDB, but you have to do the
              >transaction
              >> >enlistment yourself. Basically, you have to use the class
              >> >weblogic.transaction.TxHelper class to get a reference to the current
              >> >transaction, then call "enlistResource" on the transaction using the
              >> >JTA
              >> >"XAResource" that you get from the MQ JMS "Session" object. I'm sure
              >> >we've
              >> >posted the code in this newsgroup before, but I don't know where,
              >so
              >> >it
              >> >would look something like:
              >> >
              >> >// First, get the MQ QueueSession object you're going to use to send
              >> >the
              >> >message
              >> >QueueSession mqSession = mqConnection.createQueueSession(false, 0);
              >> >XAResource mqResource = mqSession.getXAResource();
              >> >weblogic.transaction.Transaction tran =
              >> >weblogic.transaction.TxHelper.getTransaction();
              >> >tran.enlistResource(mqResource);
              >> >// Now send your message
              >> >
              >> >In 8.1, this will still work, but it's not necessary. If you register
              >> >the MQ
              >> >XA connection factory as a "resource-reference" in your EJB deployment
              >> >descriptors and look it up using java:comp/env the way the documentation
              >> >link way below describes, then this transaction enlistment happens
              >> >automatically. This only happens when you use the "resource-reference"
              >> >feature (which means that old code will still work if it does NOT
              >use
              >> >this
              >> >feature), and it's only in 8.1.
              >> >
              >> > greg
              >> >
              >> >"Sridhar Krishnaswamy" <[email protected]> wrote in
              >message
              >> >news:[email protected]...
              >> >>
              >> >> Hi Greg:
              >> >> Is the Statement
              >> >>
              >> >> 'But in this case, you don't get a "non-transactional" session,
              >but
              >> >actually a
              >> >> session that participates in the current JTA transaction for the
              >thread
              >> >where
              >> >> your EJB is running'
              >> >>
              >> >> also true in the case of an MDB running in Weblogic 7.0 (Container
              >> >Managed
              >> >Transactions)
              >> >> driven by an XAQCF and a Foreign JMS Provider such as MQSeries?
              >In
              >> >other
              >> >words,
              >> >> if I want the MDB to PUT the Message into an MQSeries Queue, can
              >the
              >> >PUT
              >> >be invoked
              >> >> under the Context of the Same XA Transaction? My understanding is
              >that
              >> >WebLogic
              >> >> 7.0 doesn't support send
              >> >> messages out of an MDB within the same XA transaction if the MDB
              >is
              >> >> XA-driven by a foreign JMS provider. Please let me know if this
              >is
              >> >false.
              >> >If true,
              >> >> does Weblogic 8.1 also have this restriction?
              >> >>
              >> >> Thanks,
              >> >> Sridhar Krishnaswamy.
              >> >>
              >> >> "Greg Brail" <[email protected]> wrote:
              >> >> >What do you mean by "use transacted session in MDB?" Are you creating
              >> >> >a new
              >> >> >session inside your MDB, or do you mean something else?
              >> >> >
              >> >> >The only Sun thing I can think of is in code that looks like this:
              >> >> >
              >> >> >InitialContext ctx = new InitialContext();
              >> >> >QueueConnectionFactory qcf = ctx.lookup("java:comp/env/jms/QCF");
              >> >> >Queue queue = ctx.lookup("java:comp/env/jms/Queue");
              >> >> >QueueConnection connection = qcf.createQueueConnection();
              >> >> >// Create "transacted" session:
              >> >> >QueueSession session = connection.createQueueSession(true, 0);
              >> >> >QueueSender sender = session.createQueueSender(queue);
              >> >> >TextMessage message = session.createTextMessage("Hello, world");
              >> >> >sender.send(message);
              >> >> >connection.close();
              >> >> >
              >> >> >If you do this, and exactly this, inside an EJB, including the
              >use
              >> >of
              >> >> >"java:comp/env/jms", in WebLogic Server 8.1, then we do indeed
              >ignore
              >> >> >the
              >> >> >"transacted" flag when you create the session, just like Sun says
              >> >we
              >> >> >should
              >> >> >in the EJB and J2EE specs. But in this case, you don't get a
              >> >> >"non-transactional" session, but actually a session that participates
              >> >> >in the
              >> >> >current JTA transaction for the thread where your EJB is running.
              >> >> >
              >> >> >The idea is that if you are working inside an EJB, you don't use
              >> >transacted
              >> >> >sessions -- you use the transaction control given to you by the
              >EJB
              >> >> >container, including the UserTransaction interface and/or the various
              >> >> >container-managed transaction flags, rather than the JMS "transacted
              >> >> >session".
              >> >> >
              >> >> >You can find more information here:
              >> >> >
              >> >> >http://e-docs.bea.com/wls/docs81/jms/j2ee_components.html
              >> >> >
              >> >> > greg
              >> >> >
              >> >> >"Jen" <[email protected]> wrote in message
              >> >> >news:[email protected]...
              >> >> >>
              >> >> >> Hi,
              >> >> >>
              >> >> >> If I use transacted session in MDB with container managed
              >transaction,
              >> >> >dose the
              >> >> >> weblogic ignore the transacted setting or start in it's own
              >> >transaction.
              >> >> >I
              >> >> >looked
              >> >> >> the JMS Tutorial from Sun, the J2EE server just ignore the
              >transacted
              >> >> >setting,
              >> >> >> treated it as non-transacted session.
              >> >> >> Thanks
              >> >> >
              >> >> >
              >> >>
              >> >
              >> >
              >>
              >
              >
              [eRRORS.txt]
              

  • How to get transacted session in direct mode with jmsra adapter

    Hi,
    I use MQ 4.4u1 release with GF in EMBEDDED mode. I configured several connection factories with NoTransaction/LocalTransaction/XATransaction support. In my app I get a connection factory from JNDI tree, create connection/session/producer and send several messages to queue. Everything works fine when I don't use transactions. But, when I want to send messages in one transaction, the connection always provided to me non-transacted session. The session created via
    Session session = connection.createSession(true, Session.SESSION_TRANSACTED);
    request. I check the session transacted state and acknowledge mode right after i get it:
    log.fine("Session: " + session + "; transacted: " + session.getTransacted() + "; ackMode: " + session.getAcknowledgeMode());
    The log shows me that the session is not transacted and ackMode is 0 (DUPS_OK_ACKNOWLEDGE). If I try to commit the session after messages were sent I get the correct exception:
    javax.jms.IllegalStateException: MQJMSRA_DS4001: commit():Illegal for a non-transacted Session:sessionId=3361979872663370240
    Does anyone know how to get transactional session in direct mode?
    Thanks, Denis.

    I mentioned LOCAL because I misread your post and thought you were suggesting that LOCAL mode behaved differently.
    If you want to send messages in a transaction from within a Servlet then I think you're expected to use a UserTransaction: Here's an example that worked for me:
            Connection connection = outboundConnectionFactory.createConnection();
            Session session = connection.createSession(true, Session.SESSION_TRANSACTED);
            userTransaction.begin();
            MessageProducer producer = session.createProducer(outboundQueue);
            int numberOfMessages = 10;
            for (int i = 0; i<numberOfMessages; i++) {
                Message message = session.createTextMessage("Hello world");
                producer.send(message);
            userTransaction.commit();
            connection.close();I obtained the UserTransaction with this resource declaration:
        @Resource(name = "java:comp/UserTransaction")
        private UserTransaction userTransaction;The EJB spec explicitly states that local transactions aren't supported in EJBs; I haven't found such an explicit statement for Servlets but suspect that JMSRA is taking the same approach.
    As for imq.jmsra.direct.disableCM property - this appears to disable connection pooling and from your post changes other behaviour as well. How did you find out about it (other than by examining the code)? As far as I can see this is not a documented feature and is not necessarily tested or supported.

  • Problems accessing fields in a CMP entity bean from a session bean

    Hello everybody,
    I'm getting the next problem: when I try to access a field in a CMP entity bean that I have instantiated from a session bean (trhoug entitybean.getNameOfField), I get the error "the entity bean does not exist in the database".
    This entity bean is accessing a table in an external database (not the DB of the WAS), but I know that it's getting the correct data from the table, since  I check the entitybean.size() and the entitybean.findByPrimaryKey(), and I get the right information. For some reason, the only thing that it doesn't work in the entity bean are the getter/setter methods (I created them automatically after having created the entity fields).
    I access the entity bean through its local interface...
    I know it's really difficult to give an answer with so few details, but... does anybody think I forgot something important to configure??
    Thank very much in advance!!
    Isidro

    getter and setter methods for cmp-fields are abstract.
    getter and setter methods for cmr-fields are abstract.
    "John Lee" <[email protected]> wrote:
    >
    Hi:
    Which method in a CMP Entity bean should be abstract? just only SetXXX
    and
    GetXXX?
    Thanks!
    John Lee

  • How to use same transaction when calling CMP entity beans and  DAO (JDBC)

    We are currently using Weblogic 8.1 SP2 with an Oracle 10g database (using XA thin and non-XA drivers).
    We have a session bean that invokes an entity bean and a DAO (data access object pattern) in order to add data in 2 separate tables (account and history). Rows are added to the first (account) table using a CMP Entity bean while inserts are done in the 2nd (history) table using a DAO. Here is some pseudo code:
    addHistorySessionBean (trans-attribute="Required")
    begin
    Step #1 - call addAccountEntityBean (trans- attribute="Required")
    Step #2 - call addHistoryDAO (get datasource, connection)
    end
    The 2nd table (history) has a foreign key constraint to ensure that the corresponding key exists in the first (account) table. Unfortunately, DAO inserts on the 2nd (history) table fail with a foreign key constraint violation (INTEGRITY CONSTRAINT VIOLATION - PARENT KEY NOT FOUND!) since they cannot see the row added to the 1st (account) table in step #1 by the CMP entity bean.
    How does one ensure that all this is done in a single transaction ? It appears that the app server creates two seperate transactions (one for the session bean facade and the entity bean and a 2nd transaction (when we retrieve a connection using the same data source JNDI name) for the DAO.
    A post on server side suggested using a "<resource-ref>" in the session bean to tie the two potentially separate transactions together, but that does not work for us. However, I am not sure if we are doing that correctly. After we define the resource ref in the session facade bean, do we use the resource ref "name" attribute to lookup the datasource or do we still lookup the datasource by JNDI name ? Do we need to define the resource-ref tag in the entity bean also ?
    Does Weblogic allow using a single transaction for this type of a scenario ? How does one specify within Weblogic that the same transaction should be utilized by the entity bean and any subsequent DAOs?
    People have also suggested that we defer constraint checking until the transaction(s) are committed but that sounds like a work acount without addressing this issue. Would postponing the constraint checking in Oracle cause any additional overhead ?
    Any suggestions with specific examples or documentation on how to address this issue will be gratefully appreciated.

    Thanks for your suggestion. Unfortunately, this does not work since it appears that there are 2 separate transactions going on here. One, the original one initiated by the session bean and used by the entity bean and the other initiated by the DAO. Any other ideas appreciated.
    Hi,
    Try setting the delay-database-inserts tag to
    ejbCreate in RDBMS descriptor file.
    http://bernal/stage/wls/docs81/ejb/DDreference-cmp-jar
    .html#1113981
    vasanthi ramesh

  • Transaction not rolling back in stateless session bean

              Hi,
              I am facing a problem...
              I have one stateless session bean which does multiple updates in SYBASE database.I
              am using non-transactional datasource. Bean calls a method of data access obejct
              whcih internally calls more than one one mehtod to update different tables.If
              any of update fails then I am explicitly thorwing EJBException. Still it is not
              rolling back.
              I have one more application where similar situation is there but only difference
              is that there we have Entity bean and updates are being done through store method.
              In that case with same datasource it is rolling back perfectly.
              I have tried with transactional datasource as well but it didn't work.Then I tried
              to put setAutoCommit(false) in my connection class which gives me connection.But
              then it is not allowing me to enter into my application.
              In deployment descriptor for both the beans transaction attribute is required
              for all methods.
              Regards.
              Rahul.
              

              Hi,
              I am facing a problem...
              I have one stateless session bean which does multiple updates in SYBASE database.I
              am using non-transactional datasource. Bean calls a method of data access obejct
              whcih internally calls more than one one mehtod to update different tables.If
              any of update fails then I am explicitly thorwing EJBException. Still it is not
              rolling back.
              I have one more application where similar situation is there but only difference
              is that there we have Entity bean and updates are being done through store method.
              In that case with same datasource it is rolling back perfectly.
              I have tried with transactional datasource as well but it didn't work.Then I tried
              to put setAutoCommit(false) in my connection class which gives me connection.But
              then it is not allowing me to enter into my application.
              In deployment descriptor for both the beans transaction attribute is required
              for all methods.
              Regards.
              Rahul.
              

  • Making AQ usage transactional across session beans, using mosly JMS syntax

    I need to determine what I need to have in place in order for JMS/AQ messages to be "fully transactional".
    I have a J2EE server application that will send JMS/AQ messages to a queue. I have a standalone application that reads messages from the queue, does some work, and then makes calls on multiple session beans (hosted in the original J2EE server application). Actually, it would likely be multiple calls to the same session bean method.
    Once the standalone application reads a message from the queue, I need to ensure that if any action performed as a result of that message fails, that all the operations performed, including the removal of the message from the queue, are rolled back.
    First of all, if I use an Oracle XA-compliant datasource, if one of the session bean calls fail, I can rollback the current transaction, but will this properly roll back any work that earlier session bean calls (made on the same transaction) did, even if they were successful (at the time)? Note that I have two JVMs, one running the J2EE application, and the other a standalone application reading from the queue.
    Second, on committing or rolling back the message retrieval itself, I noticed from examples in the Oracle AQ Application Developer's Guide that if I create my QueueSessions with "AQDriverManager.createAQSession()", that I can pass a Connection object, and then later "commit" or "rollback", manually, perhaps if I got an EJBException from a session bean call.
    However, I am trying to write my JMS/AQ code so that it uses as little of the direct AQ api as possible, staying with the standard JMS api. As a result, I'm using the JMS version of this, which is "QueueConnection.createQueueSession()". When I do this, however, it seems as if I lose control over the transaction.

    Ok, I think I've answered some of this for myself, but I still have some concerns.
    I see that the QueueSession object that I get back from "queueConnection.createQueueSession()" is likely going to actually be an instance of the "AQjmsSession" class, so I can cast to that, and then I can call "commit" or "rollback".
    What is unclear from the javadoc description is what happens when "close()" is called on the session object. Does this do an implicit "commit()", perhaps unless "rollback()" has already been called?
    I'm still a little uncertain about whether the scope of my transaction will be wide enough to protect everything that needs to be protected.
    For instance, I assume that my transaction starts when my consumer (not in an application server) reads the message from the queue. At that point, my consumer does some "screen-scraping" work. When it's done, it will call a session bean on the application in the application server (separate JVM, in other words), which will create some EJB entity objects and also insert raw database rows. The session bean will then return, and then the original method which read a message from the queue will be completed.
    What I need to know is what will happen if ANYTHING in that process fails, either in the external consumer, or in the session bean, or creating EJB entities? That is, will the entire transaction be rolled back, undoing the EJB entity creations AND the removal of the message from the message queue?
    If this can possibly work, I'm assuming this would be utilizing an XA datasource, or a non-emulated data source (which I think means the same thing).

  • CMT and using non-Weblogic JMS in a session bean

              I am writing a session bean which sends a JMS message using a non-weblogic JMS
              provider. This bean is marked for CMT and I want the JMS send to participate in
              this CMT as well. My understanding is that I should be able to do this by defining
              a <resource-ref> element in the ejb-jar.xml and a corresponding <resource-descriptor>
              element in the weblogic-ejb-jar.xml file. The bean would then use the <res-ref-name>
              defined under the <resource-ref> element to lookup the connection factory. What
              do I have to put in weblogic-ejb-jar.xml file to make sure that the connection
              factory specified in <res-ref-name> maps to a connection factory that is in a
              foreign JNDI provider (e.g. in the non-Weblogic JMS provider's JNDI) and not in
              Weblogic's JNDI?
              Thanks in advance for your help.
              

    It sounds like you're using Tibco JMS to receive messages from the MDB, and
              then to send out a message. WLS 7.0 will handle the transaction enlistment
              properly when it receives messages for the MDB, but you'll have to enlist
              the JMS provider yourself when you send the message, using the white paper
              that Tom pointed you to as a guide.
              In WLS 8.1, coming soon, we'll automatically enlist the provider in the
              transaction if you look it up using a "resource-ref" element in the EJB like
              you described. Today, you can use that element but no transaction
              enlistement is being done.
              greg
              "Venkat" <[email protected]> wrote in message
              news:[email protected]...
              >
              > We also need this feature.
              > We are using Weblogic 7.0 and Tibco JMS 3.0,
              > which supports XA.
              >
              > We are mainly interested in subscribing using MDB
              > and publishing using a session bean in one transaction.
              > Do you think by using resource-refs in conjunction
              > with registering with Weblogic JNDI during startup
              > can do the job?
              >
              > Or how about using XAConnectionFactory and XASession
              > classes for JMS publishing ?
              >
              > Thanks.
              >
              > Tom Barnes <[email protected]> wrote:
              > >Hi Mihir,
              > >
              > >Support for automatic enlistment of foreign JMS vendors
              > >via the resource-ref approach is not available in WLS.
              > >This support will be available in the next release:
              > >limited access beta is available now, public beta is available
              > >in 2-3 months. You are the first customer I've heard of that
              > >asked for this feature. Very cool. Good timing.
              > >
              > >As you are not using WebLogic JMS, you will need to do the
              > >transaction enlistment yourself. This isn't that hard
              > >to do. I suggest that you refer to the integrating foreign
              > >JMS vendor white-paper available on dev2dev.bea.com.
              > >Also, refer to the integrating transactions with
              > >MQSeries integration paper, which will likely serve your
              > >purposes better. Note that some JMS vendors
              > >have problems with concurrent transactions in a single
              > >JMS connection, or with transactions that attempt
              > >to switch threads (eg. suspend() in one thread
              > >and resume() in another).
              > >
              >
              >http://dev2dev.bea.com/resourcelibrary/whitepapersdetail.jsp?highlight=whit
              epapers&filePath=components%2Fdev2dev%2Fresourcelibrary%2Fwhitepapers%2Fwp_j
              msproviders.htm
              >
              >http://dev2dev.bea.com/resourcelibrary/whitepapersdetail.jsp?highlight=whit
              epapers&filePath=components%2Fdev2dev%2Fresourcelibrary%2Fwhitepapers%2Fwp_j
              tatransactions.htm
              > >
              > >Tom
              > >
              > >mihir sharma wrote:
              > >> I am writing a session bean which sends a JMS message using a
              non-weblogic
              > >JMS
              > >> provider. This bean is marked for CMT and I want the JMS send to
              participate
              > >in
              > >> this CMT as well. My understanding is that I should be able to do this
              > >by defining
              > >> a <resource-ref> element in the ejb-jar.xml and a corresponding
              <resource-descriptor>
              > >> element in the weblogic-ejb-jar.xml file. The bean would then use the
              > ><res-ref-name>
              > >> defined under the <resource-ref> element to lookup the connection
              factory.
              > >What
              > >> do I have to put in weblogic-ejb-jar.xml file to make sure that the
              > >connection
              > >> factory specified in <res-ref-name> maps to a connection factory that
              > >is in a
              > >> foreign JNDI provider (e.g. in the non-Weblogic JMS provider's JNDI)
              > >and not in
              > >> Weblogic's JNDI?
              > >>
              > >> Thanks in advance for your help.
              > >>
              > >
              >
              

  • Accessing the same stateful session bean from multiple clients in a clustered environment

    I am trying to access the same stateful session bean from multiple
              clients. I also want this bean to have failover support so we want to
              deploy it in a cluster. The following description is how we have tried
              to solve this problem, but it does not seem to be working. Any
              insight would be greatly appreciated!
              I have set up a cluster of three servers. I deployed a stateful
              session bean with in memory replication across the cluster. A client
              obtains a reference to an instance of one of these beans to handle a
              request. Subsequent requests will have to use the same bean and could
              come from various clients. So after using the bean the first client
              stores the handle to the bean (actually the replica aware stub) to be
              used by other clients to be able to obtain the bean. When another
              client retrieves the handle gets the replica aware stub and makes a
              call to the bean the request seems to unpredictably go to any of the
              three servers rather than the primary server hosting that bean. If the
              call goes to the primary server everything seems to work fine the
              session data is available and it gets backed up on the secondary
              server. If it happens to go to the secondary server a bean that has
              the correct session data services the request but gives the error
              <Failed to update the secondary copy of a stateful session bean from
              home:ejb20-statefulSession-TraderHome>. Then any subsequent requests
              to the primary server will not reflect changes made on the secondary
              and vice versa. If the request happens to go to the third server that
              is not hosting an instance of that bean then the client receives an
              error that the bean was not available. From my understanding I thought
              the replica aware stub would know which server is the primary host for
              that bean and send the request there.
              Thanks in advance,
              Justin
              

              If 'allow-concurrent-call' does exactly what you need, then you don't have a problem,
              do you?
              Except of course if you switch ejb containers. Oh well.
              Mike
              "FBenvadi" <[email protected]> wrote:
              >I've got the same problem.
              >I understand from you that concurrent access to a stateful session bean
              >is
              >not allowed but there is a
              >token is weblogic-ejb-jar.xml that is called 'allow-concurrent-call'
              >that
              >does exactly what I need.
              >What you mean 'you'll get a surprise when you go to production' ?
              >I need to understand becouse I can still change the design.
              >Thanks Francesco
              >[email protected]
              >
              >"Mike Reiche" <[email protected]> wrote in message
              >news:[email protected]...
              >>
              >> Get the fix immediately from BEA and test it. It would be a shame to
              >wait
              >until
              >> December only to get a fix - that doesn't work.
              >>
              >> As for stateful session bean use - just remember that concurrent access
              >to
              >a stateful
              >> session bean is not allowed. Things will work fine until you go to
              >production
              >> and encounter some real load - then you will get a surprise.
              >>
              >> Mike
              >>
              >> [email protected] (Justin Meyer) wrote:
              >> >I just heard back from WebLogic Tech Support and they have confirmed
              >> >that this is a bug. Here is their reply:
              >> >
              >> >There is some problem in failover of stateful session beans when its
              >> >run from a java client.However, it is fixed now.
              >> >
              >> >The fix will be in SP2 which will be out by december.
              >> >
              >> >
              >> >Mike,
              >> >Thanks for your reply. I do infact believe we are correctly using
              >a
              >> >stateful session bean however it may have been misleading from my
              >> >description of the problem. We are not accessing the bean
              >> >concurrently from 2 different clients. The second client will only
              >> >come into play if the first client fails. In this case we want to
              >be
              >> >able to reacquire the handle to our stateful session bean and call
              >it
              >> >from the secondary client.
              >> >
              >> >
              >> >Justin
              >> >
              >> >"Mike Reiche" <[email protected]> wrote in message
              >news:<[email protected]>...
              >> >> You should be using an entity bean, not a stateful session bean
              >for
              >> >this application.
              >> >>
              >> >> A stateful session bean is intended to be keep state (stateful)
              >for
              >> >the duration
              >> >> of a client's session (session).
              >> >>
              >> >> It is not meant to be shared by different clients - in fact, if
              >you
              >> >attempt to
              >> >> access the same stateful session bean concurrently - it will throw
              >> >an exception.
              >> >>
              >> >> We did your little trick (storing/retrieving handle) with a stateful
              >> >session bean
              >> >> on WLS 5.1 - and it did work properly - not as you describe. Our
              >sfsb's
              >> >were not
              >> >> replicated as yours are.
              >> >>
              >> >> Mike
              >> >>
              >> >> [email protected] (Justin Meyer) wrote:
              >> >> >I am trying to access the same stateful session bean from multiple
              >> >> >clients. I also want this bean to have failover support so we want
              >> >to
              >> >> >deploy it in a cluster. The following description is how we have
              >tried
              >> >> >to solve this problem, but it does not seem to be working. Any
              >> >> >insight would be greatly appreciated!
              >> >> >
              >> >> >I have set up a cluster of three servers. I deployed a stateful
              >> >> >session bean with in memory replication across the cluster. A client
              >> >> >obtains a reference to an instance of one of these beans to handle
              >> >a
              >> >> >request. Subsequent requests will have to use the same bean and
              >could
              >> >> >come from various clients. So after using the bean the first client
              >> >> >stores the handle to the bean (actually the replica aware stub)
              >to
              >> >be
              >> >> >used by other clients to be able to obtain the bean. When another
              >> >> >client retrieves the handle gets the replica aware stub and makes
              >> >a
              >> >> >call to the bean the request seems to unpredictably go to any of
              >the
              >> >> >three servers rather than the primary server hosting that bean.
              >If
              >> >the
              >> >> >call goes to the primary server everything seems to work fine the
              >> >> >session data is available and it gets backed up on the secondary
              >> >> >server. If it happens to go to the secondary server a bean that
              >has
              >> >> >the correct session data services the request but gives the error
              >> >> ><Failed to update the secondary copy of a stateful session bean
              >from
              >> >> >home:ejb20-statefulSession-TraderHome>. Then any subsequent requests
              >> >> >to the primary server will not reflect changes made on the secondary
              >> >> >and vice versa. If the request happens to go to the third server
              >that
              >> >> >is not hosting an instance of that bean then the client receives
              >an
              >> >> >error that the bean was not available. From my understanding I
              >thought
              >> >> >the replica aware stub would know which server is the primary host
              >> >for
              >> >> >that bean and send the request there.
              >> >> >
              >> >> >Thanks in advance,
              >> >> >Justin
              >>
              >
              >
              

  • Multiple users accessing entity bean with same PK

    Hi,
    Some body please clarify the below issue.
    (EJB 1.1, WAS3.5)
    I have two app servers and two clones each clone is running in each app server.
    Stateful session bean access Entity beans to update/read record in the database.
    According to my requirement multiple users can access the same entity data (same primary key). Suppose user A created a Stateful session bean SB1 and the SB1 created Entity1 with PK1, this is happening at clone1.
    User B accessed the site and the request went to Clone2 and a new SB2 created, but the SB2 need to access the database with Same PK1.
    For the above situation, I guess container can not create a new Entity bean with PK1 because EB with PK1 is already there and it tries to allocate same EB1 with SB2, so if two requests are concurrent do the SB2 wait to get the handle of the EB1?
    Is there any way to create two Entity beans with same Primary Key at the same time but in different clone?
    Thanks,
    Sagar

    Hi,
    The concurrency level has to be set at the level of database and the database will take care of consistency & integrity of the data. So specity the concurrency level on the database connection in each appserver.

  • EJB 3.0 Session bean transfers null Entity

    Hello all
    I am having trouble trying to transfer an Entity from a stateful session bean to a JSP. When I try an identical method with a java client within the OC4J container of JDeveloper, it works fine. However when I deploy the application to OracleAS 10.1.3, I get a null pointer on the entity.
    Please help. I have been stuck on this for about 3 weeks, and I've followed documentation to the letter as far as I can see.
    Here is the code for the JSP, the (simplified) bean and the Entity in question.
    Bean:
    import java.util.List;
    import javax.annotation.Resource;
    import javax.ejb.Stateful;
    import javax.persistence.EntityManager;
    import javax.persistence.Query;
    @Stateful(name="cart")
    public class CartBean implements CartRemote, CartLocal  {
        @Resource
        protected EntityManager manager;
        public CartBean() {
             public User getUser(String username){
                    User user = manager.find(User.class, username);
             return user;
        }The JSP:
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
    "http://www.w3.org/TR/html4/loose.dtd">
    <%@ page contentType="text/html;charset=windows-1252"%>
    <%@ page import="com.evotec.ereq.CartLocal" %>
    <%@ page import="com.evotec.ereq.User" %>
    <%@ page import="javax.naming.InitialContext" %>
    <%@ page import="java.util.List" %>
    <%@ page import="java.util.ArrayList" %>
    <%!String m_username = "pbarrett";%>
    <%!String emailAddress = "";%>
    <%
    try {
        InitialContext ctx = new InitialContext();
        CartLocal cart = (CartLocal) ctx.lookup("java:comp/env/cart");
            User user = cart.getUser(m_username);
            emailAddress = user.getEmailAddress();
    %>
    <html>
    <body>
    you are: <%= m_username %><BR>
    your email address is: <%= emailAddress %><BR>
    </body>
    </html>
    <%
    catch (Exception e){
        e.printStackTrace();
    %>and the User entity:
    import java.io.Serializable;
    import java.sql.Timestamp;
    import static javax.persistence.AccessType.FIELD;
    import javax.persistence.Column;
    import javax.persistence.Entity;
    import javax.persistence.Table;
    import javax.persistence.Id;
    @Entity(access=FIELD)
    @Table(name="USERS")
    public class User implements Serializable {
        @Column(name="CREATION_DATE")
        protected Timestamp creationDate;
        @Column(name="DISPLAY_NAME")
        protected String displayName;
        @Column(name="EMAIL_ADDRESS")
        protected String emailAddress;
        @Id
        @Column(name="USERNAME")
        protected String username;
        @Column(name="USER_ID")
        protected Long userId;
        @Column(name="USER_STATUS")
        protected Long userStatus;
        public User() {
              //JDeveloper-generated getters and setters
    }I should point out that I have established that the null pointer is not coming from the CartLocal lookup.
    Any help welcome, thanks in advance.
    Paul

    Hi,
    Thanks for the quick response.
    I have tried this approach before but when I try and deploy to the server, I get this message:
    @PersistenceContext annotation can only be used when a javax.spi.PersistenceProvider is installed.
    Is this a missing jar file? If so, which one?
    Thanks
    Paul

  • How to achieve Entity Bean methods ONLY by calling them from a Session Bean

    Hi,
    I used a session bean as a business facade to a entity bean.
    In the session bean I achieve the entity bean with a jndiContext.lookup("java:comp/env/ejbEntityBean").
    Now I am looking for a solution that it is only possible to call the entity bean methods or the whole entity bean from the corresponding session bean.
    In other words: "How can I forbid the access to the entity bean, if the calling object is not the corresponding session bean?"
    --->
    I only found a way the regulate the access to the entity bean methods by declaring a security-role.
    But the existence of the security-role at runtime depends on the calling user-authorizations!
    Is there a way to set the entity-security-role within the session bean context?
    Best Regards
    Steffen

    Hi Srikanth Reddy.T,
    sorry, I am not looking for a special tag  <entity-security-role>.
    I am looking for a way to specifiy that my session bean "has" the special security-role (in my case "WebZaehlerEjbRole") of my entity bean "in my case "WebZaehlerEjbRole") that is necessary to call the methods (findAlleEntries, findByWindowId,...) of my entity-bean.
    Here is the relevant part of my ejb-jar.ml:
         <assembly-descriptor>
              <security-role>
                   <role-name>WebZaehlerEjbRole</role-name>
              </security-role>
              <method-permission>
                   <description>method-permission</description>
                   <role-name>WebZaehlerEjbRole</role-name>
                   <method>
                        <ejb-name>WebZaehlerBean</ejb-name>
                        <method-name>findAllEntries</method-name>
                        <method-params/>
                   </method>
                   <method>
                        <ejb-name>WebZaehlerBean</ejb-name>
                        <method-name>findByWindowId</method-name>
                        <method-params>
                             <method-param>java.lang.Long</method-param>
                        </method-params>
                   </method>
    Regards,
    Steffen

  • Setting transaction isolation level in a session bean

    Hi all!
    In a stateless session bean (EJB3) with container managed transactions I need to set the transaction isolation level to SERIALIZABLE.
    The idea is to prevent lost update on database when multiple accesses occur concurrently.
    Thanks in advance for your patience,
    Tommaso

    Hi all!
    In a stateless session bean (EJB3) with container managed transactions I need to set the transaction isolation level to SERIALIZABLE.
    The idea is to prevent lost update on database when multiple accesses occur concurrently.
    Thanks in advance for your patience,
    Tommaso

Maybe you are looking for

  • Smalloc error while doing a ttcmd execute

    Hi, I am trying to insert a set of 8 values in the DB. 4 of which are varchar2 and 2 of them are timestamp and 1 number(10) and 1 number(15,4). When I try to insert without setting the params for the number fields in TTCmd::setParam for the two numbe

  • I think i deleted my whole iphoto library!!

    like the iphoto icon was on my toolbar and i daw it got moved to my desktop so i wanted to keep my desktop clean so i moved it to trash and it asked me for my password so i typed it in and then i emptied my recyclebin and when i dumped my trash sudde

  • Some Query Regarding SAP NetWeaver Features

    Hi friends,     Can u give me some simple questions answers regarding NetWeaver : 1> What is the oldest and latest versions of NetWeaver and in which SAP versions it runs ? 2> Whether we can write Report(Type 1) or Module Pool (Type M) programs in Ne

  • Form returned in .txt format

    I have designed a form in Adobe Designer 7.0 and have used it several times and it has worked just fine. The returned forms come back in the _data.xml format and I can import the data easily. I wonder why the last one somebody sent came back in .txt

  • Inputs required on BAdi HRBAS00INFTY

    Hi, I want to update a custom infotype based on the changes happening in a standard infotype(1001) irrespective of the transactions like ppome , ppo01,etc. I found a BAdi HRBAS00INFTY which i can use I guess. Could you please provide me some input on