Search code examples
mdriven

How to see "non - eco" inserted objects


We are still using ECO5 with VS 2008. A "non eco" application uses the same database as our eco-application does and inserts data. The inserted data (objects) cannot be seen in our eco - application, unless we restart this application. It is not necessary to restart the persistence server, and I assume we inserted data correctly (respecting inserts into ECOModelRoot and incrementing ECO_ID), since the eco-application shows them correctly after restart.

We tried to set the ecospace.active to false and then to true again, and ecospace.persistence.refresh(true). The inserted data still were not displayed, although also the regarding query was closed before and opened afterwards.

How can we make our eco-application see the "non - eco" inserted objects?


Solution

  • When you've inserted your data correctly, your scenario is identical to a scenario where two independant ECO applications are writing to the same database.

    So, in able to answer your question we need to know more about your applications architecture because normally it would be sufficient to shut down the ecospace by setting active to false. Some type of chaching is still happening.

    • Do you use an EcoSpace with database persistence or do you use a persistence server? In this case the server would need a restart.
    • Did you try to insert the data with a seperate eco-Application? Did you experiance the same behaviour?
    • You could try to instanciate a new EcoSpace object instead of setting your EcoSpace to not active.
    • You could switch SQL logging to true so that you can see which SQLs are fired against the database.

    There are also ways in invalidate the cache of an EcoSpace for specific objects or classes but you first have to find out, where your prolem is located.