- π¦πΉAustria drunken monkey Vienna, Austria
Thanks for reporting this problem!
If Commerce really updates the entities when they are loaded, as it sounds like from the issue summary, then Iβd say this is a clear violation of the general contract for CRUD operations. Definitely, we do not want to change our whole code just for this. Especially since I donβt think that indexing orders is a common use case, even for Commerce users.
One solution to this would be to override the datasource plugin used for
entity:commerce_order
with a sub-class of\Drupal\search_api\Plugin\search_api\datasource\ContentEntity
that uses your proposed adaptions. Maybe the Commerce maintainers would even be prepared to add this as a general addition to thecommerce_order
module? Please try moving this issue to their issue queue and asking there.