|
Rank: Newbie Groups: Member
Joined: 5/10/2023 Posts: 2
|
We set the cache path for the browser engine using the CachePath property: https://www.essentialobjects.com/doc/EO.WebEngine.EngineOptions.CachePath.htmlThe CachePath we set looks something like this: C:\Users\<username>\AppData\Roaming\<productname>\Browser In general, this works. However, sometimes the cache path appends a number to the folder name and (over time) we end up with folder names like this: Browser Browser_1 Browser_2 Browser_3 Can you please explain what conditions would cause these additional cache paths ("_1", "_2", "_3", etc) to be automatically created? Thank you!
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,217
|
Hi,
Each Engine instance must have its own cache path. So when you have multiple Engine instances running on the same machine but their CachePath are all set to the same path, you will see numbers being added to the cache path so that each Engine instance will have their own cache path.
The most common scenario when you have multiple Engine instances is when you run multiple instances of the same application. In this case each instance of the application would create a default Engine instance. You can also explicitly create additional Engine instance in your application. In that case one instance of your application will have multiple Engine instances.
Hope this clears up. Please feel free to let us know if you still have any more questions.
Thanks!
|
|
Rank: Newbie Groups: Member
Joined: 5/10/2023 Posts: 2
|
Thank you for the reply and what you are stating make sense. This is likely the scenario we are facing but we are uncertain how it is occurring. We suspect the previous engine instances are not shutting down properly when our application terminates, but we've been unable to confirm this.
Follow-up question: How does the browser engine determine if there are already other engine instances running on the same machine (and thus creates its own unique CachePath folder)?
FYI, if it matters, we use InitWorkerProcessExecutable to set the path of the worker process to something like this: C:\Users\<username>\AppData\Roaming\<productname>\Executable\<productname>.exe
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,217
|
Hi,
Each engine has its own process. That process would place a lock on the folder it uses so no other process (engine) will be able to access it. Once the owner engine process exits, the lock is released and the folder will then be accessible to another engine process.
Thanks!
|
|