public function deleteLock(Source $invoiceSource)
    {
        $entry = $this->getByInvoiceSource($invoiceSource, false);
        if ($entry === null) {
            // - The process that had the lock may have failed sending the
            //   invoice to Acumulus and has removed the lock (e.g. a connection
            //   timeout, with the timeout being longer than our lock expiry).
            // - Yet another process already cleared the lock.
            return AcumulusEntry::Lock_NoLongerExists;
        }
        if ($entry->isSendLock()) {
            // The lock is still there: remove it.
            $this->delete($entry);
            return AcumulusEntry::Lock_Deleted;
        }
        // The AcumulusEntry became a real entry: apparently the process that
        // had the lock, successfully finished sending the invoice after all.
        return AcumulusEntry::Lock_BecameRealEntry;
    }