Since Application is known for its global-variable usage. I was thinking maybe it's good to load Firebase remote config in onCreate() method in Application class and all variable will be stored as "public static" and with an initial value.
Just want to know if it is a good idea because I've tried to store remote-configs as private objects with classic getter/setter and that causes null-exceptions frequently.
Don't use Application. If you have (or ever will have) a multi-process app, some Firebase features may have problems with that.
There is no guarantee that putting a call to fetch() early on in your app will make the values available as soon as they're needed. You should build your app taking into account that it may take some time to load Remote Config parameters. If you absolutely require them at launch, make a load screen and start the fetch there, progressing only when they're finished loading.
There are different strategies for using Remote Config, and they're outlined in this blog.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With