That looks like a bad design. There is no synchronization, so multiple threads can create invoices with the same number.

I would recommend creating a Jira issue.

-Adrian

On 5/19/2010 3:30 PM, James McGill wrote:
  This happened again, this time with an InvoiceId.

What could possibly cause an Invoice to be written with an InvoiceId
(received via, InvoiceServices.xml#getNextInvoiceId)
without getNextInvoiceId writing the incremented value to
PartyAcctgPreference ?

In my log I can see the last time an InvoiceId was created.
getNextInvoiceId logs its context, and the method succeeds (We are using
INVSQ_ENF_SEQ etc.).  The invoice is created and everything seems fine.

Then the next and subsequent invoices fail because the PartyAcctgPreference
wasn't updated.  I can't understand from the code how that is even possible.

Could<store-value value-field="partyAcctgPreference"/>
possibly not be writing, but also not throwing an error?

Reply via email to