Warning: Can't synchronize with repository "(default)" (/home/git/ome.git does not appear to be a Git repository.). Look in the Trac log for more information.
Notice: In order to edit this ticket you need to be either: a Product Owner, The owner or the reporter of the ticket, or, in case of a Task not yet assigned, a team_member"

Task #2508 (closed)

Opened 14 years ago

Closed 14 years ago

ome_nextval hangs on trigger

Reported by: jamoore Owned by: jamoore
Priority: major Milestone: OMERO-Beta4.2
Component: ORM Version: n.a.
Keywords: n.a. Cc: cxallan, jburel
Resources: n.a. Referenced By: n.a.
References: n.a. Remaining Time: n.a.
Sprint: 2010-06-10 (11)

Description

In #1176, we moved to using our own sequence generator (ome_nextval) in order to more cleanly work with the Hibernate table-based id generator strategy. Postgres doesn't directly provide a way to grab a sequence of ids.

While working on a database trigger which inserted new rows (and therefore needed new ids), ome_nextval deadlocked. This may also be the explanation of some of the periodic database hangs.

As a result, we need to go back to using Postgres's native nextval function, since it is the only method that will permit working outside of the current transactional scope. ome_nextval will still be used to provide functionality on top of nextval.

Change History (2)

comment:1 Changed 14 years ago by jmoore

(In [7323]) Adding new sequences and triggers to 4.2 DB. (See #1390, #2508)

comment:2 Changed 14 years ago by jmoore

  • Resolution set to fixed
  • Status changed from new to closed

r7323 should close this. The ome_nextval logic is fairly complex, but is functional for the given triggers. If any hangs are seen, feel free to re-open.

Note: See TracTickets for help on using tickets. You may also have a look at Agilo extensions to the ticket.

1.3.13-PRO © 2008-2011 Agilo Software all rights reserved (this page was served in: 0.68549 sec.)

We're Hiring!