telefonicaid / iotagent-node-lib

Module to enable IoT Agent developers to build custom agents for their devices that can easily connect to NGSI Context Brokers
https://iotagent-node-lib.rtfd.io/
GNU Affero General Public License v3.0
58 stars 84 forks source link

Remove dependency on deprecated domain module #1585

Open AlvaroVega opened 4 months ago

AlvaroVega commented 4 months ago

Component

Techdeb

Is your feature request related to a problem? Please describe

https://nodejs.org/docs/latest-v18.x/api/domain.html#domain

Stability: 0 - Deprecated

Source Code: lib/domain.js

This module is pending deprecation. Once a replacement API has been finalized, this module will be fully deprecated. Most developers should not have cause to use this module. Users who absolutely must have the functionality that domains provide may rely on it for the time being but should expect to have to migrate to a different solution in the future.

Domains provide a way to handle multiple different IO operations as a single group. If any of the event emitters or callbacks registered to a domain emit an 'error' event, or throw an error, then the domain object will be notified, rather than losing the context of the error in the process.on('uncaughtException') handler, or causing the program to

Describe the solution you'd like

There are some approaches to use, but basically is include logger into current request.

Describe alternatives you've considered

https://github.com/telefonicaid/fiware-pep-steelskin/pull/528 https://github.com/telefonicaid/iotagent-manager/pull/327

The systemd version you checked that didn't have the feature you are asking for

No response

fgalan commented 3 months ago

Current status: