Skip to content

Commit

Permalink
add DeadlockDetectedException to fix #145
Browse files Browse the repository at this point in the history
  • Loading branch information
maxdemarzi committed Feb 13, 2014
1 parent 17eb07e commit 9d2fee7
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions lib/neography/connection.rb
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,7 @@ def raise_errors(code, exception, message, stacktrace, request, index)
when /RelationshipNotFoundException/ ; RelationshipNotFoundException
when /NotFoundException/ ; NotFoundException
when /UniquePathNotUniqueException/ ; UniquePathNotUniqueException
when /DeadlockDetectedException/ ; DeadlockDetectedException
else
NeographyError
end
Expand Down
3 changes: 3 additions & 0 deletions lib/neography/errors.rb
Original file line number Diff line number Diff line change
Expand Up @@ -44,4 +44,7 @@ class NotFoundException < NeographyError; end
# Thrown when CREATE UNIQUE matches multiple paths.
class UniquePathNotUniqueException < NeographyError; end

# Signals that a deadlock between two or more transactions has been detected
class DeadlockDetectedException < NeographyError; end

end

0 comments on commit 9d2fee7

Please sign in to comment.