Open pquerner opened 8 years ago
thats an interesting case, actually I dont remember to have seen code which orders single entries by such dependent parts. I wish we already had some tests for this module, will be evil to debug this :/
I think I could give you my WIP code, so you may follow me from there? Or help me get into the right direction? Currenctly theres not much free time for me, so I guess I could only start to follow it some more on this years hackathon.
I got this far: index the depended indexes first, but when it comes to the actual index process, it wants to index the events for given index but fails.
So could be that our custom indexer does not write into magentos "event" table (I really dont know how that works btw, if you got a slide or blog posts which explains that, I'd be happy to read it), or somewhere in the cache/session it somehow thinks its a whole new index and does not have any events available.
I stopped working right on that point, so I couldnt say which problem to follow next.
We have a custom indexer which manages the product prices for us, but it must run before "catalog_product_price" so it may be reindexed correctly for magentos index tables.
Here comes the tricky part: it does not work with this module as it does with the default indexer. In the default magento indexer you could add a xml depend node to your module, so your indexer may run before another indexer:
This will work if you reindex via default shell "indexer.php" but does not work with AsyncIndex.
I tried to patch it but failed as I am unsure about how the dependend indexes get their info about the events / productids (or whatever) to index.