jitsi / jitsi-meet-sdk-samples

Jitsi Meet mobile SDK examples (Android, iOS and React Native)
Apache License 2.0
270 stars 235 forks source link

Not able to implement SDK v7.0.0 & v7.0.1 in Android #163

Open NilabhB opened 1 year ago

NilabhB commented 1 year ago

Not able to implement to recent versions of jitsi SDK, use to get gradle sync error. currently stable usable SDK is v6.2.2,
In v6.2.2, youtube video streaming doesn't work, it's not related to bandwidth, there's some problem related to video playback. But in the jitsi-meet app it works perfectly fine (Not talking about the youtube live stream), not sure what's the issue with video playback.

saghul commented 1 year ago

What error do you get with SDK 7.x?

NilabhB commented 1 year ago

jitsi_v7 0 1_error

The gradle will build for around 6 mins & then get fail after that. Here's a screenshot I am attaching it. It's same for both v7.0.0 & v7.0.1

saghul commented 1 year ago

Did you add our maven repo?

NilabhB commented 1 year ago

Yes, I did. My app is already running well in v6.2.2. I just wanted to updated the Jitsi SDK.

maven {
            url "https://github.com/jitsi/jitsi-maven-repository/raw/master/releases"
        }

It's already added.

saghul commented 1 year ago

What Gradle version do you have?

NilabhB commented 1 year ago

gradle_version_screenshot

I am using the most updated version of Android Studio as of today(18/12/2022). The Gradle version is 7.4

NilabhB commented 1 year ago

Hi @saghul,

Any solutions on this?

Bresiu commented 1 year ago

It seems that https://github.com/jitsi/jitsi-maven-repository/raw/master/releases is not accessible anymore. I cannot sync dependencies. When I try to paste url in a browser in navigates me to https://github.com/jitsi/jitsi-maven-repository/tree/master/releases but changing raw to tree in gradle file do not work.

I think that raw is now url parameter: ?raw=true

NilabhB commented 1 year ago

Hi @saghul & @Bresiu,

I found a solution to these issues, the repos are actually good & still accessible, the problem is with the gradle versions or probably the new versions of Android Studios.

In recent versions of Android Studios, allprojects{} might not be found in build.gradle. In that case, the repository goes into the settings.gradle file in the root of your project (Modify the code in settings.gradle):

dependencyResolutionManagement {
    repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
    repositories {
        google()
        mavenCentral()
        maven {
            url "https://github.com/jitsi/jitsi-maven-repository/raw/master/releases"
        }
        maven {
            url "https://maven.google.com"
        }
    }
}

After this in module build.gradle use dependency

implementation ('org.jitsi.react:jitsi-meet-sdk:6.2.2') { transitive = true }

Your application will be good with jitsi SDK v6.2.2.

Note: Jitsi SDK v7.0.0 or v7.0.1 will not work simply this way! SDK versions 7.x seems to have an issue with gradle versions. To implement Jitsi SDK v7.x check your gradle version first & make sure it is set to gradle v7.4.2.

How to fix Gradle Version for this project?

Now sync the project with:

implementation ('org.jitsi.react:jitsi-meet-sdk:7.0.1') { transitive = true }

You are all set with the latest version of Jitsi SDK as of 22/12/2022.

Let me know if this solved your problem, we can close this issue, else I will provide a different approach.

Note: Even with the latest version of Jitsi SDK, the video-sharing feature will not work. I don't know what is the issue. In the original Jitsi Meet App it just works super fine.

You can check my latest Personal Project based on Jitsi SDK for Android: https://github.com/NilabhB/SkyMeet App Link: https://play.google.com/store/apps/details?id=com.skymeet.videoConference

Good Luck!

saghul commented 1 year ago

Thanks for the writeup!

We haven't really changed much from SDK 6 to 7, we bumped the major to indicate a backwards compatibility change.

This may have to do with the Gradle version, including the plugin version. We won't have time to look into this before the end of the year, sorry.

NilabhB commented 1 year ago

Hey,

Thank you so much for the response @saghul.

I have been helping people on stackoverflow & here as well regarding maven repo implementation. Therefore I made a pull request: https://github.com/jitsi/handbook/pull/404

This will solve the problem for all. Would you mind merging it, please?

saghul commented 1 year ago

Merged, thanks for the reminder!

NilabhB commented 1 year ago

Oh, I am so glad. This was my first pull request probably. Thanks to you. Looking forward to contribute more.

saghul commented 1 year ago

Very happy to hear this!

MacBook1234567890 commented 9 months ago

pluginManagement { repositories { google() mavenCentral()

gradlePluginPortal()

(url) } } dependencyResolutionManagement { repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS) repositories { google() mavenCentral() maven { url "https://github.com/jitsi/jitsi-maven-repository/raw/master/releases" // i got error on this line } maven { url "https://maven.google.com" // i got error on this line }

}

}

rootProject.name = "first" include(":app")