Yii2 ActiveRecord identity map memory growth in long-running CLI batch jobs
Assumes Yii 2.x. Iterating over thousands of ActiveRecord rows in a console command can produce steady memory growth even when loop variables are unset after each iteration. The suspected cause is the framework's internal identity map, which retains one object instance per primary key for the duration of the process. The goal is to confirm whether this ident