aardvark-platform / aardvark.base

Aardvark.Base is the foundation of the open-source Aardvark Platform for visual computing, real-time graphics, and visualization.
https://aardvarkians.com/
Apache License 2.0
154 stars 9 forks source link

Configurable Introspection Cache Directory #48

Closed luithefirst closed 3 years ago

luithefirst commented 3 years ago

For the deployment of Aardvark apps it would be clean to have all application-specific user data in one single directory and this would also include the introspection cache. At the moment this is hardcoded to Environment.SpecialFolder.ApplicationData + Aardvark\cache. I would therefore suggest making it configurable.

hyazinthh commented 3 years ago

https://github.com/aardvark-platform/aardvark.base/commit/65a6d1ab4e70b8ebd9a383266d39b8f9239d754f adds an option to configure the cache directory via CachingProperties.CustomCacheDirectory. This affects both introspection and plugins caches.

haraldsteinlechner commented 3 years ago

There was a question regarding special folders on different OS'es. I checked on Mac OS 11.2 newest version/dotnet 5:

> System.Environment.GetFolderPath(Environment.SpecialFolder.System);;
val it : string = "/System"

> System.Environment.GetFolderPath(Environment.SpecialFolder.CommonApplicationData);;
val it : string = "/usr/share"

> System.Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData);;      
val it : string = "/Users/hs/.config"

> System.Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData);;
val it : string = "/Users/hs/.local/share"

> System.Environment.GetFolderPath(Environment.SpecialFolder.UserProfile);;         
val it : string = "/Users/hs"

>