angular / angular/angularfire

[Android] Firestore snapshot listeners is slow to retrieve data.

Abierto
#3,513 0 comentarios 0 reacciones 0 asignados Ver en GitHub
Lenguaje dominante
TypeScript
Estrellas
7.8k
Forks
2.2k
Merge medio
22 h 28 min
PR fusionados (30 d)
6

Descripción

### Version info

**Angular:** 17.3.3

**Firebase:** 10.10.0

**AngularFire:** 17.0.1

**Other (e.g. Ionic/Cordova, Node, browser, operating system):**
Ionic:

Ionic CLI : 7.2.0 (/Users/user/.nvm/versions/node/v18.17.0/lib/node_modules/@ionic/cli)
Ionic Framework : @ionic/angular 7.8.2
@angular-devkit/build-angular : 17.3.2
@angular-devkit/schematics : 17.3.2
@angular/cli : 17.3.2
@ionic/angular-toolkit : 11.0.1

Capacitor:

Capacitor CLI : 5.7.4
@capacitor/android : 5.7.4
@capacitor/core : 5.7.4
@capacitor/ios : 5.7.4

Utility:

cordova-res : not installed globally
native-run : 2.0.1

System:

NodeJS : v18.17.0 (/Users/user/.nvm/versions/node/v18.17.0/bin/node)
npm : 10.5.0
OS : macOS Unknown

### How to reproduce these conditions

**Failing test unit, Stackblitz demonstrating the problem**

**Steps to set up and reproduce**

We have developed an Ionic Hybrid app for iOS, Android, and Web platforms, which has been functioning smoothly for the past two years. However, after multiple library updates, we have encountered an issue specific to Android devices. Retrieving the first fresh snapshot listener takes an exceptionally long time on Android, whereas iOS and web platforms retrieve the same snapshot listener in just 1 second on the same device. Android hybrid apps may take up to 60 seconds for this process.

Interestingly, restarting the app after the initial retrieval significantly improves the speed.

I am currently using the compat SDK instead of the Web modular SDK. I wonder if this choice affects the result.

**Sample data and security rules**

### Debug output

** Errors in the JavaScript console **

** Output from `firebase.database().enableLogging(true);` **

** Screenshots **

### Expected behavior

### Actual behavior

Guía de contribución

Abrir la guía de contribución

Línea de trabajo

Comienza reproduciendo el primer listener de snapshots de Firestore en Android usando las versiones indicadas de Angular, Firebase, AngularFire, Ionic y Capacitor, y compáralo con iOS y web. Comprueba si el compat SDK afecta al retraso y al momento de captura o a la salida de depuración; se considera terminado cuando la ralentización específica de Android está explicada y se ha documentado una solución verificada o una transferencia clara a upstream.

Escrito por el modelo de indexación a partir del texto del issue.

Evaluación

Stack tecnológico
android, angular, firebase, typescript
Área
databases, mobile-dev
Tipo de issue
Error
Dificultad
4/5
Tiempo estimado
3-5 días
Estado de actividad
Estancado
Claridad
Necesita aclaración
Aptitud para principiantes
18/100

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.