Exception: OpenReceive::Server::HostPersistenceError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/openreceive/server/errors.rb

Overview

503 — infrastructure failed to persist the payment attempt (database down, host hook bug). Mirrors the JS handler's commit(): a retryable INTERNAL, never a payer-blaming conflict; the invoice is still withheld.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(message = "The host could not persist this payment attempt; " \ "payer instructions were withheld. Please retry.") ⇒ HostPersistenceError

Returns a new instance of HostPersistenceError.



100
101
102
103
104
105
106
# File 'lib/openreceive/server/errors.rb', line 100

def initialize(message = "The host could not persist this payment attempt; " \
                         "payer instructions were withheld. Please retry.")
  super(message)
  @status = 503
  @code = "INTERNAL"
  @retryable = true
end

Instance Attribute Details

#codeObject (readonly)

Returns the value of attribute code.



98
99
100
# File 'lib/openreceive/server/errors.rb', line 98

def code
  @code
end

#retryableObject (readonly)

Returns the value of attribute retryable.



98
99
100
# File 'lib/openreceive/server/errors.rb', line 98

def retryable
  @retryable
end

#statusObject (readonly)

Returns the value of attribute status.



98
99
100
# File 'lib/openreceive/server/errors.rb', line 98

def status
  @status
end