Skip to content

Commit 0c07cab

Browse files
committed
Appwrite 1.5 support
1 parent ae73f63 commit 0c07cab

File tree

4 files changed

+23
-3
lines changed

4 files changed

+23
-3
lines changed

CHANGELOG.md

+8
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
## 11.0.0
2+
3+
* Added enum support
4+
* Added SSR support
5+
* Added messaging service support
6+
* Added contains query support
7+
* Added or query support
8+
19
## 10.1.0
210

311
* Add new queue health endpoints
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
import 'package:dart_appwrite/dart_appwrite.dart';
2+
3+
Client client = Client()
4+
.setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5+
.setProject('5df5acd0d48c2') // Your project ID
6+
.setKey('919c2d18fb5d4...a2ae413da83346ad2'); // Your secret API key
7+
8+
Health health = Health(client);
9+
10+
HealthQueue result = await health.getQueueUsageDump(
11+
threshold: 0, // (optional)
12+
);

lib/services/health.dart

+1-1
Original file line numberDiff line numberDiff line change
@@ -432,7 +432,7 @@ class Health extends Service {
432432
///
433433
/// Get the number of projects containing metrics that are waiting to be
434434
/// processed in the Appwrite internal queue server.
435-
Future<models.HealthQueue> getQueueUsage({int? threshold}) async {
435+
Future<models.HealthQueue> getQueueUsageDump({int? threshold}) async {
436436
final String apiPath = '/health/queue/usage-dump';
437437

438438
final Map<String, dynamic> apiParams = {

test/services/health_test.dart

+2-2
Original file line numberDiff line numberDiff line change
@@ -359,7 +359,7 @@ void main() {
359359

360360
});
361361

362-
test('test method getQueueUsage()', () async {
362+
test('test method getQueueUsageDump()', () async {
363363
final Map<String, dynamic> data = {
364364
'size': 8,};
365365

@@ -369,7 +369,7 @@ void main() {
369369
)).thenAnswer((_) async => Response(data: data));
370370

371371

372-
final response = await health.getQueueUsage(
372+
final response = await health.getQueueUsageDump(
373373
);
374374
expect(response, isA<models.HealthQueue>());
375375

0 commit comments

Comments
 (0)