java.lang.NoClassDefFoundError: Failed resolution of: Lorg/apache/commons/logging/LogFactory

Add this below line in manifest file.

<uses-library android:name ="org.apache.http.legacy" android:required ="false"/>

This is an AWS SDK bug that appears to be solved in version 2.6.30 of the SDK:

Fixed a bug where getting a logger using Apache Commons Logging would crash starting Android 9.0 (Pie / API Level 28). See pull #521. Now, Apache Commons Logging would be used if it's being added as a dependency, otherwise android.util.Log will be used.


to fix this issue I had the dependency implementation "commons-logging:commons-logging-api:1.1" in gradle file.