java - Spring Nested Transaction Generic Example -


can body provide insight here..

i have been having hard time, while getting through spring @transactional(propagation nested)

i have been searching on net , here, unable find generic example of specific type regarding this..

    @transactional(required)     mtdone(user userobj1, user userobj2)     {     somebean.mtdtwo( userobj1);     somebean.mtdthree(userobj2);      }  @transactional(nested) mtdtwo(userobj1)  { //calling dao , insert data database daoobj.save(userobj1); //this data must not rolled back,  //  though exception thrown in next method }  @transactional(required) mtdthree(userobj2)  { //calling dao second time , insert data database daoobj.save(userobj2);   /////some exception thrown here  } 

so want save methodtwo data db, , must not rolled though exception thrown in next method..

i want achieve using transaction(nested)

please give me suggestions..


Comments

Popular posts from this blog

Ansible - ERROR! the field 'hosts' is required but was not set -

customize file_field button ruby on rails -

SoapUI on windows 10 - high DPI/4K scaling issue -