New and Improved 3.13 Beta. Highlights: Shareable filters and dashboards and lots of other goodies. Any feedback can be raised as JIRA issues in the JIRA project.
Issue Details (XML | Word | Printable)

Key: JRA-9343
Type: Bug Bug
Status: Resolved Resolved
Resolution: Fixed
Priority: Major Major
Assignee: Anton Mazkovoi [Atlassian]
Reporter: Anton Mazkovoi [Atlassian]
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
JIRA

Uncommitted transaction and connection leaked if the user votes for an issue while they have already voted or unvotes if they have not voted.

Created: 13/Feb/06 02:28 AM   Updated: 31/Oct/06 11:41 PM
Component/s: Backend / Domain Model
Affects Version/s: 3.5.1
Fix Version/s: 3.5.2

Time Tracking:
Not Specified

File Attachments: 1. File DefaultVoteManager.class (7 kB)


Participants: Anton Mazkovoi [Atlassian]
Since last comment: 2 years, 28 weeks, 1 day ago
Resolution Date: 13/Feb/06 03:11 AM
Labels:


 Description  « Hide
While the JIRA UI does not allow a user to vote for an issue if they have already voted, the user can double lick the 'vote' link. The second request will leave a uncommitted transaction and will leak a db connection. The connection will be left in a thread local however. The same occurs if a user double clicks the unvote link.

Databases usually time out unused connections, so the leaked connection will be closed by the database server and the following will appear in JIRA's log files.

For MySQL:
2006-01-27 13:19:25,174 WARN [core.entity.jdbc.SQLProcessor] [SQLProcessor.rollback]: SQL Exception while rolling back
insert. Error was:java.sql.SQLException: No operations allowed after connection closed.
2006-01-27 13:19:25,175 WARN [NoModule] org.ofbiz.core.entity.jdbc.SQLProcessor
java.sql.SQLException: No operations allowed after connection closed.
at com.mysql.jdbc.Connection.checkClosed(Connection.java:1842)
at com.mysql.jdbc.Connection.rollback(Connection.java:4724)
at org.apache.tomcat.dbcp.dbcp.DelegatingConnection.rollback(DelegatingConnection.java:265)
at org.apache.tomcat.dbcp.dbcp.PoolingDataSource$PoolGuardConnectionWrapper.rollback(PoolingDataSource.java:288)
at org.ofbiz.core.entity.jdbc.SQLProcessor.rollback(SQLProcessor.java:131)
at org.ofbiz.core.entity.jdbc.SQLProcessor.commit(SQLProcessor.java:114)
at org.ofbiz.core.entity.jdbc.SQLProcessor.close(SQLProcessor.java:153)
at org.ofbiz.core.entity.jdbc.SQLProcessor.finalize(SQLProcessor.java:702)
at java.lang.ref.Finalizer.invokeFinalizeMethod(Native Method)
at java.lang.ref.Finalizer.runFinalizer(Finalizer.java:83)
at java.lang.ref.Finalizer.access$100(Finalizer.java:14)
at java.lang.ref.Finalizer$FinalizerThread.run(Finalizer.java:160)

For PostgreSQL:
2006-02-02 17:47:35.486142500 org.ofbiz.core.entity.GenericDataSourceException: SQL Exception while executing the following:SELECT ID, issueid, AUTHOR, actiontype, actionlevel, actionbody, CREATED, actionnum FROM jiraaction WHERE issueid=? AND actiontype=? (can't create statement from closed connection.)



 All   Comments   Work Log   Change History      Sort Order: Ascending order - Click to sort in descending order
Anton Mazkovoi [Atlassian] added a comment - 13/Feb/06 03:10 AM
To fix this bug please install the attached file.

If you are using JIRA Standalone please do the following:

1. Download all attached file
2. Copy the files to <jira_install_dir>/atlassian-jira/WEB-INF/classes/com/atlassian/jira/issue/vote/DefaultVoteManager.class overwriting the file that is already there
3. Restart JIRA

If you are using the WAR distribution of JIRA:

1. Download all attached files
2. Copy the files to <jira_install_dir>/webapp/WEB-INF/classes/com/atlassian/jira/issue/vote/DefaultVoteManager.class
3. Run 'build.sh clean' on unix or 'build.bat clean' on windows
4. Run 'build.sh' on unix or 'build.bat' on windows
5. Redeploy the JIRA web app into your application server
6. Restart the application server