mikro-orm: v6: Incorrectly deep DTO population and related performance issue
Describe the bug
When using a datastructure with circular references, toPOJO results in a performance issue and a object with incorrect depth
Stack trace N/A
To Reproduce Steps to reproduce the behavior:
- Create a circular reference in your entities:
Author -> Books -> Author - Query for the root entity and populate the dependency
- Convert to POJO and examine the populated depth and note the execution time
Expected behavior
Only the loaded data will be populated in the DTO; the circular reference will stop with a a Reference instead of a populated DTO
Additional context Add any other context about the problem here.
Versions
| Dependency | Version |
|---|---|
| node | 16.14.2 |
| typescript | 4.9.5 |
| mikro-orm | 6.0.0-dev.64 |
About this issue
- Original URL
- State: closed
- Created a year ago
- Comments: 23 (23 by maintainers)
What do you mean? There are tons of tests that are using just
wrapwithout it, repro welcome, that sounds more like a bug.