firebase / firebase/firebase-android-sdk
Functions: Allow setting OkHttpClient instance
- Dominant language
- Java
- Stars
- 2.6k
- Forks
- 710
- Avg merge
- 2d 9h
- Merged PRs (30d)
- 31
Description
## What feature would you like to see?
I would like to be able to set or change the `OkHttpClient` instance of `FirebaseFunctions`.
Currently this is not possible because the private field is initialized in the [constructor](https://github.com/firebase/firebase-android-sdk/blob/a135c514ee4d6a48cfc6680d7a35e97e6a666736/firebase-functions/src/main/java/com/google/firebase/functions/FirebaseFunctions.java#L100).
This would enable using a shared and preconfigured `OkHttpClient` instance which could lead to improved I/O performance.
## How would you use it?
As of now I only want to configure a custom `User-Agent` string so that we can distinguish between different clients that execute callable functions in the backend.
Contributor guide
Assessment
This issue has not been assessed yet.