更新时间:2023-02-16 17:53:26
我相信您已经创建了一个递归函数.您运行一个查询,该查询调用记录器,该查询运行一个调用该记录器的查询,该查询运行一个调用该记录器的查询(等等).您可能需要直接使用数据库驱动程序,以免干扰 TypeORM 查询周期,并将日志查询与常规查询分开.
I believe you've created a recursive function. You run a query, that calls the logger, that runs a query that calls the logger that runs a query that calls the logger (etc.). You'd need to probably use a database driver directly to not interfere with the TypeORM query cycle and to keep the logging queries separate from the regular queries.