Skip to content

Commit

Permalink
Removed HTTP client implementation
Browse files Browse the repository at this point in the history
  • Loading branch information
ricardoboss committed Mar 20, 2024
1 parent 9f33365 commit f1c668d
Show file tree
Hide file tree
Showing 6 changed files with 0 additions and 210 deletions.
10 changes: 0 additions & 10 deletions example/docker-compose.yml

This file was deleted.

21 changes: 0 additions & 21 deletions example/main.dart

This file was deleted.

1 change: 0 additions & 1 deletion lib/dart_seq.dart
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ export 'src/seq_client.dart';
export 'src/seq_client_exception.dart';
export 'src/seq_context.dart';
export 'src/seq_event.dart';
export 'src/seq_http_client.dart';
export 'src/seq_in_memory_cache.dart';
export 'src/seq_log_level.dart';
export 'src/seq_logger.dart';
Expand Down
137 changes: 0 additions & 137 deletions lib/src/seq_http_client.dart

This file was deleted.

38 changes: 0 additions & 38 deletions lib/src/seq_logger.dart
Original file line number Diff line number Diff line change
Expand Up @@ -12,44 +12,6 @@ class SeqLogger {
this.autoFlush = true,
}) : assert(backlogLimit >= 0, 'backlogLimit must be >= 0');

/// Creates a new instance of [SeqLogger] that logs to a Seq server over HTTP.
///
/// This method is a factory for creating a new instance of [SeqLogger] that
/// logs to a Seq server over HTTP using the [SeqHttpClient].
///
/// By default, a new instance of [SeqInMemoryCache] is used for caching the
/// events. If you want to use a different cache, you can pass it as the
/// [cache] parameter.
factory SeqLogger.http({
required String host,
String? apiKey,
int maxRetries = 5,
SeqCache? cache,
int backlogLimit = 50,
SeqContext? globalContext,
String? minimumLogLevel,
bool autoFlush = true,
Duration Function(int tries)? httpBackoff,
}) {
final httpClient = SeqHttpClient(
host: host,
apiKey: apiKey,
maxRetries: maxRetries,
backoff: httpBackoff,
);

final actualCache = cache ?? SeqInMemoryCache();

return SeqLogger(
client: httpClient,
cache: actualCache,
backlogLimit: backlogLimit,
globalContext: globalContext,
minimumLogLevel: minimumLogLevel,
autoFlush: autoFlush,
);
}

/// Compares two log levels.
static int compareLevels(String? a, String? b) {
if (a == null && b == null) {
Expand Down
3 changes: 0 additions & 3 deletions pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,6 @@ screenshots:
environment:
sdk: '^3.0.0'

dependencies:
http: '>=0.13.3 <2.0.0'

dev_dependencies:
build_runner: ^2.4.8
mockito: ^5.4.4
Expand Down

0 comments on commit f1c668d

Please sign in to comment.