3rd dlt-trigger in TransactionResolver, but as TODO-comment

This commit is contained in:
Claus-Peter Huebner 2023-07-20 23:22:25 +02:00
parent 4c075766cf
commit d91150c08c

View File

@ -150,6 +150,22 @@ export const executeTransaction = async (
transactionReceive,
transactionReceive.amount,
)
/* TODO not the right place, because its inside semaphore locks
// send transaction via dlt-connector
// notice: must be called after transactions are saved to db to contain also the id
// we use catch instead of await to prevent slow down of backend
// because iota pow calculation which can be use up several seconds
const dltConnector = DltConnectorClient.getInstance()
if (dltConnector) {
dltConnector.transmitTransaction(transactionSend).catch(() => {
logger.error('error on transmit send transaction')
})
dltConnector.transmitTransaction(transactionReceive).catch(() => {
logger.error('error on transmit receive transaction')
})
}
*/
} catch (e) {
await queryRunner.rollbackTransaction()
throw new LogError('Transaction was not successful', e)