Skip to content

Conversation

pontomedon
Copy link
Contributor

@pontomedon pontomedon commented Feb 18, 2025

This is based on previous work by Cesar Ramirez and it is obviously depending on work done on the java sdk: GitLiveApp/firebase-java-sdk#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.

@pontomedon
Copy link
Contributor Author

fixes #689 and #533

@AbelVolpi
Copy link

AbelVolpi commented Jun 28, 2025

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

@pontomedon
Copy link
Contributor Author

You'll have to do the following:

  • check out Adding JVM support for Firebase Storage firebase-java-sdk#44
  • update gradle.properties and set the version 0.4.9-AbelVolpi-SNAPSHOT
  • deploy firebase-java-sdk to your maven local ./gradlew publishToMavenLocal
  • check out this branch
  • update libs.versions.toml and set gitlive-firebase-java-sdk = "0.4.9-AbelVolpi-SNAPSHOT"
  • update gradle.properties and set all firebase-*.version to 2.1.1-AbelVolpi-SNAPSHOT
  • deploy firebase-kotlin-sdk to your maven local ./gradlew publishToMavenLocal
  • in your project, make sure you have mavenLocal() in your repository list and depend on firebase-kotlin-sdk in version 2.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.

@Reedyuk
Copy link
Collaborator

Reedyuk commented Aug 18, 2025

@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.

@nbransby nbransby merged commit 7e4c1bb into GitLiveApp:master Aug 19, 2025
49 checks passed
@pontomedon pontomedon deleted the cramsan/storage_jvm branch September 14, 2025 17:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants