firebase-kotlin-sdk
firebase-kotlin-sdk copied to clipboard
Adding JVM support for Firebase Storage
This is based on previous work by Cesar Ramirez and it is obviously depending on work done on the java sdk: https://github.com/GitLiveApp/firebase-java-sdk/pull/44
I know the checks are failing, I'll need some input on how I can publish a snapshot of firebase-java-sdk to make them succeed. It all works locally when deploying to maven local.
I needed to make sure we never call the firebase storage API with null metadata - when doing this on a desktop target, the CONTENT_LENGTH = 0 header gets removed somehow, causing the firebase backend to respond with a HTTP 411. Passing defaults causes a few bytes to be serialized in the first requrest before the upload, which circumvents the problem.
The root cause for this must be in the http driver somewhere, as it doesn't happen when running the same code on Android.
fixes #689 and #533
Is it possible to implement these changes directly in my personal project?
I tried to clone the repo and checkout to this branch (to import the library locally), but I can't even sync the project, I'm facing an issue in all modules. It happens in all podspec sync tasks like: :firebase-storage:podspec
-----------
* What went wrong:
Execution failed for task ':firebase-config:generateDummyFramework'.
> Failed to calculate the value of task ':firebase-config:generateDummyFramework' property 'outputFramework'.
> Failed to query the value of task ':firebase-config:generateDummyFramework' property 'frameworkName'.
> Collection is empty.
Could anyone help me please? I would really appreciate it. This usage of storage is blocking my project
You'll have to do the following:
- check out https://github.com/GitLiveApp/firebase-java-sdk/pull/44
- update
gradle.propertiesand set the version0.4.9-AbelVolpi-SNAPSHOT - deploy
firebase-java-sdkto your maven local./gradlew publishToMavenLocal - check out this branch
- update
libs.versions.tomland setgitlive-firebase-java-sdk = "0.4.9-AbelVolpi-SNAPSHOT" - update
gradle.propertiesand set allfirebase-*.versionto2.1.1-AbelVolpi-SNAPSHOT - deploy
firebase-kotlin-sdkto your maven local./gradlew publishToMavenLocal - in your project, make sure you have
mavenLocal()in your repository list and depend onfirebase-kotlin-sdkin version2.1.1-AbelVolpi-SNAPSHOT
alternatively: you can open ~/.m2/repository and copy the whole dev/gitlive folder into your repository, under a subfolder .localMaven, and add this directory as a local maven to your repositories: maven { url = URI("file://${rootProject.projectDir}/.localMaven") }, that way it will work on CI as well.
@pontomedon - You need to run
./gradlew apiDump
https://github.com/pontomedon/firebase-kotlin-sdk/actions/runs/17046144917/job/48322367413
Then fix the errors, commit this and we will be able to merge in.