Function error logged

Maybe wrap this line up in a try-catch block and log it when there is an error.

Somebody on this list once suggested to make the import dead simple: accept the input string and write it to a UD table. The table has a status field that is set to something like “imported”. Next, process the record (either in the same function or get fancy and treat it like a queue and have another async task process it separately). After a successful import, update the status field to “processed”. They suggested that now you have some observability where you can easily find records that did not import, orders imported per day, etc. Heck, you could really get fancy and check with your web portal and verify that the two are identical and change the status to “verified”.

2 Likes