Uploading speed is getting slow continiously in firebase angular
- Ngôn ngữ chính
- TypeScript
- Star
- 7.8k
- Fork
- 2.2k
- Merge trung bình
- 22 giờ 28 phút
- Pull request đã merge (30 ngày)
- 6
Mô tả
Think you found a bug?
=======================
Hi Team,
We have made web application where we are uploading multiple images in batches using angular and firebase. but, when we start to upload image more than 5000 -6000.intially uploading speed is good till approx 1000, after that uploading speed is going decrease continiously.it is so frustrating for us. Please help on that.it is very critical for us
I am adding reference code which we are using.
CODE:--
const path = `users/${this.user.uid}/${this.projectName}/${this.file.name}`;
// const path = `${this.projectName}/${this.file.name}`; // path to upload demoproject
this.fileName = this.file.name;
// Reference to storage bucket
const ref = this.storage.ref(path);
// the main task
const current = new Date();
const timestamp =performance.now();
// console.log("start Time"+ timestamp)
let endstamp;
// var counts=0;
this.startUpload
this.task = ref.put(this.file, {
customMetadata: { projectName: this.projectName, contentType: 'image/jpeg' }
});
this.task.catch((err: any) => {
console.warn('upload error==>', err.code);
this.uiService.showSnackbar(`${err.code}: error occurred`, null, 3000);
this.uploadFailed = true;
});
let flag = false;
this.snapshot = this.task.snapshotChanges().pipe(
finalize(async () => {
this.downloadURL = await ref.getDownloadURL().toPromise();......................
..................................................................................................................
....................................................................................................................
### Version info
**Angular:**--Angular CLI: 9.1.13
**Firebase:**:11.2.0
**AngularFire:**:5.4.2
Node: 16.15.1
OS: win32 x64
### How to reproduce these conditions
**Failing test unit, Stackblitz demonstrating the problem**
### Expected behavior
Uploading speed for all image should be same irrespective of internet speed.
### Actual behavior
when you upload multiple image in batches more than 5000 images. then initially uploading speed is same but when upload start from more than 1000..then uploading speed is going decrease continiously.
Hướng dẫn đóng góp
Hướng nghiên cứu
Bắt đầu với mã tải lên Angular được cung cấp cùng thông tin phiên bản Angular 9.1.13, Firebase 11.2.0 và AngularFire 5.4.2. Tái hiện việc tải lên theo các lô vượt quá 5.000 hình ảnh, so sánh thông lượng trước và sau khoảng 1.000 lần tải lên, đồng thời xác định liệu tình trạng chậm liên tục được báo cáo có thể tái hiện hay không.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- angular, firebase, typescript
- Lĩnh vực
- cloud, frontend, performance
- Loại issue
- Lỗi
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức độ hoạt động
- Đình trệ
- Độ rõ ràng
- Cần làm rõ
- Mức phù hợp với người mới
- 25/100