transactions

Weblogic Transaction Timeout : how to set in admin console in WebLogic AS 8.1

I face the following exception: weblogic.transaction.internal.TimedOutException: Transaction timed out after 300 seconds this is set within the Stateless Session EJB Bean as javax.transaction.UserTransaction jtaTransaction.setTransactionTimeout(300) but I cannot figure out, where in the application console to set this property. ...

Transaction mode for file operations in Java

Hi there, Perhaps what I'm trying to explain here doesn't make any sense, so I'd like to apologize in advance. Anyway, I will try. I'm trying to read from a file, perform some database operations and move the content to another file. I was wondering if it is possible to perform all this operations in an atomic way in Java, so if anythi...

JPA and Spring transactions - please explain

Hi, today I have coded a test case for my application, to see how transactions behave. And I have found that nothing works the way I thought it does. I have a Spring-based application using Hibernate as JPA provider, backed by MySQL. I have DAO objects, extending Spring's JpaDaoSupport. These are covered by Spring's transaction managem...

Database-sessions in Spring

Hi guys, I'm quite new to Spring, and I would like to understand a bit more about sessions. I've mapped a legacy database with Hibernate annotated entities and built a couple of service objects to fetch, retrieve etc. My entities also contain other entities (mapped through foreign keys) and sets of entities. When I traverse the entitiy ...

Entity Framework: Cannot access a disposed object. Transaction

We are using Entity Framework and running unit tests within a transaction scope. We were origianally getting the error in the title. I have managed to isolate the problem some what. using (TransactionScope scope1 = new TransactionScope()) { using (TransactionScope scope2 = new TransactionScope()) ...

SubSonic2.2 SharedDbConnectionScope and TransactionScope Transaction Confusion

ARGH!!! There seems to be a little confusion surrounding the SharedDbConnectionScope and TransactionScope objects to enable wrapping your SubSonic queries within a transaction. The docs suggest specifying the using SharedDbConnectionScope wrapped around the using TransactionScope... using(SharedDbConnectionScope scope = new SharedDbC...

MySQL transaction isolation levels broken?

I can't seem to get MySQL 5.0.32 on 32bit x86 Debian to honour transaction isolation levels. I've reduced my problem to its simplest form, tested with the mysql command-line client: -- On node writer: -- DROP TABLE test; CREATE TABLE test ( name VARCHAR(255) ); set autocommit=0; set transaction isolation level read committed; beg...

Is it possible to defer referential integrity checks until the end of a transaction in SQL Server?

I recently read in Fowler's PofEA that some database engines allow you to defer RI checks until the end of the transaction. Is this possible in SQL Server? The problem comes with some scenarios where I am trying to save changes that include insertions and deletions, it can be tricky to determine the correct order in which to perform th...

How do I create a SQL Server agent without using a GUI?

I am using Angel LMS and its built on a SQL Server platform. I believe its 2005, but not 100% sure about that. Anyway, maybe my pseudo-code will shed light on that answer. Also single quotes must be used for strings and the concatenate character is +. I need to have something run 2-5 times a day (the frequency is not determined yet...

Why isn't Snapshot isolation supported with Distributed Transactions in SQL Server

Question is in the title. I'd just love to understand why this isn't supported? Just to clarify this is MS Sql Server 2005 / 2008. ...

How to find long running transactions in Websphere MQ Series?

In a J2EE environment the MQ server log shows the following: Process(954584.5) User(mqm) Program(amqzmuc0) AMQ7469: Transactions rolled back to release log space. .... While increasing the logfile size/space might be a temporary solution, the definitive solution must be to identify the culprit process/queue that causes this long transa...

FbDataAdapter Update throwing NullReferenceException

When updating a DataTable with 1850-ish new rows to a FbDataAdapter I get a NullReferenceException during execution. Usually it succeeds in inserting around 1200 records, sometimes more, sometimes less... However when stepping through the code with the debugger, it sometimes inserts the entire recordset, no problem. I am using the Fir...

Hierarchy of TransactionScope

Is it possible to have a hierarchy of transaction scopes? If the outer transaction scope does a dispose, what will happen to changes made in the inner transaction scope? My particular problem is that I have test code that runs code that has a transaction scope. When I call a second set of code with a transaction scope I get "Cannot acc...

Import DotNetNuke users using transactions with DNN classes

I'm developing a module in DNN 4.9 to import users. My problem is that I need transaction support but have to use DNN classes to import/create users. Out of the box the classes don't seem to support transactions. Anybody got experience with this or knows how to do that? I'm using the following object to create users: UserController.C...

Multiple TransactionScope problem

Hi, I want to create a transaction, writing some data in a sub-transaction, reading the data back, and rollback the transaction. using(var transaction = new TransactionScope()) { using(var transaction = new TransactionScope()) { // save data via LINQ / DataContext transaction.Complete(); } // G...

How can I implement a class that is aware of TransactionScope?

I have a WCF service that is performing some updates across a couple of databases and Active Directory. Since Active Directory is not able to support transactions, I want to implement then in a "DirectoryRepository" class that will perform a compensating action when a rollback occurs. my code is using TransactionScope... using(var scop...

Default Transaction Timeout

I used to set Transaction timeouts by using TransactionOptions.Timeout, but have decided for ease of maintenance to use the config approach: <system.transactions> <defaultSettings timeout="00:01:00" /> </system.transactions> Of course, after putting this in, I wanted to test it was working, so reduced the timeout to 5 seconds, ...

Trouble configuring AspectJ LTW with Tomcat and Spring

Hi all, I'm having some problems getting load-time weaving to work with Spring in my Tomcat 6 webapp. I only want to use it for transactions (so that self-invocation respects transactional annotations, which it doesn't with AOP proxying). It appears that the weaver is being loaded, but my annotated classes aren't actually being woven. Wh...

Should I be using InnoDB for this?

I am developing a personal PHP/MySQL app, and I came across this particular scenario in my project: I have various comment threads. This is handled by two tables - 'Comments' and 'Threads', with each comment in 'Comments' table having a 'thread_id' attribute indicating which thread the comment belongs to. When the user deletes a comment...

Access Transactions in Code with Commit and Rollback

I've been asked to try to roll back some database changes if there was an error. Before I even start trying to use a TRANSACTION with either COMMIT or ROLLBACK, could someone tell me if I can do the following in MS Access? void Start() { try { AccessDatabaseOpen(); // Opens the access database foreach (File in FileList) { ...