Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8490185
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T22:02:44+00:00 2026-06-10T22:02:44+00:00

I have a Spring 3 application using openJPA as persistence management, following section works

  • 0

I have a Spring 3 application using openJPA as persistence management, following section works fine in STS/Tomcat

@Transactional
createBalance(){
.....
    Balance balance = new SummaryBalance();
    balance.setName(name);
    balance.setCurrency(currency);
    balance.setClosingTimestamp(closingTime);
    balance.setStatus(BalanceStatus.OPEN);
    balance.persist(); // persist !!
 ......

    balance.setCloseAmount(amount);
    balance.setLastUpdateTimestamp(now);
}

However, when deploying same code in websphere 7, the closeAmount and lastUpdate does not update(both fields in DB didn’t get update but from log both field can return values by their getter) then show up as null, but changes to other fields before persist() do take effect when the method finished. So I bet when the method finishing WS didn’t flush the changes towards these fields.

I thought the JPA(regardless of vendor) should keep the balance entity object managed after persist() and flush the object after the method is finished with later changes. Turns out Websphere 7 doesn’t make it. Even I put a merge() method

    balance.setCloseAmount(amount);
    balance.setLastUpdateTimestamp(now);
    balance.merge();

still does not help.

Questions:

  1. OpenJPA has already been included as dependencies in the deployment, but why still websphere need to involve with the JPA management?
  2. How to solve the problem?

Thanks in advance.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T22:02:46+00:00Added an answer on June 10, 2026 at 10:02 pm

    I’m not sure that this exactly answers your question, but I think you should do some reconfiguration to use WebSphere capabilities, please check Spring 3.1 documentation

    11.8.1 IBM WebSphere

    On WebSphere 6.1.0.9 and above, the recommended Spring JTA transaction
    manager to use is WebSphereUowTransactionManager. This special adapter
    leverages IBM’s UOWManager API, which is available in WebSphere
    Application Server 6.0.2.19 and later and 6.1.0.9 and later. With this
    adapter, Spring-driven transaction suspension (suspend/resume as
    initiated by PROPAGATION_REQUIRES_NEW) is officially supported by IBM!

    and

    11.9.1 Use of the wrong transaction manager for a specific DataSource

    Use the correct PlatformTransactionManager implementation based on
    your choice of transactional technologies and requirements. Used
    properly, the Spring Framework merely provides a straightforward and
    portable abstraction. If you are using global transactions, you must
    use the org.springframework.transaction.jta.JtaTransactionManager
    class (or an application server-specific subclass of it) for all your
    transactional operations. Otherwise the transaction infrastructure
    attempts to perform local transactions on resources such as container
    DataSource instances. Such local transactions do not make sense, and a
    good application server treats them as errors.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'd like to run my Spring application using STS, but I have no idea
I have a Spring application deployed in JBoss EAP server, using the following settings:
I have an extremely simple web application running in Tomcat using Spring 3.0.2, Hibernate
I have developed demo application using spring struct and hibernate and getting following error
I have an application using Tomcat/Spring 3/JPA/Hibernate but my merges do not commit to
I have this web application using Spring Web Flow framework. In my main page
I have a web application using spring annotations extensivley and I have my proguard
I'm creating a web application using spring mvc. I have started to incorporate the
I creating a web application using JSF,Hibernate,Spring. I have added a filter for checking
I am using spring mvc in my application,when i created user i have to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.