Conversation
There was a problem hiding this comment.
Code Review
This pull request migrates the logging infrastructure to use package:google_cloud. Key changes include replacing the internal LogSeverity and LogEntry definitions with those from the external package, updating the Logger class to extend CloudLogger, and integrating TraceContextData for trace propagation. Additionally, standard print statements have been replaced with structured logger.warning calls, and error logging has been simplified by passing StackTrace objects directly to the logger. A high-severity issue was identified in the log method where LogSeverity is incorrectly accessed via a non-existent value property instead of index for severity comparison.
5272ce2 to
cdc730c
Compare
|
/gemini review |
There was a problem hiding this comment.
Code Review
This pull request migrates the project to package:google_cloud for logging and HTTP serving, updating the Logger to extend CloudLogger and refactoring the server startup logic. Feedback points out a compilation error in the fireUp function and a regression in trace propagation that needs to be fixed by manually populating the Zone with trace data.
Integrates `package:google_cloud` for structured logging, trace context, and standard environment variables. Details: - Update `Logger` to extend `CloudLogger` from `package:google_cloud`. - Replace custom trace context parsing and zone keys with `TraceContextData` and standard constants. - Update `fireUp` server startup to use `TraceContextData.tryParse`. - Remove custom `removeCircular` logic and related tests (offloaded to `google_cloud`). - Upgrade `google_cloud_storage` to `^0.6.0` and add `google_cloud` dependency. - Modernize logging calls throughout (`logger.warning` with `stackTrace` etc). - Remove obsolete `server_test.dart` for custom trace parsing. - Use standard constants for environment variables (e.g., `serviceEnvironmentVariable`, `projectIdEnvironmentVariableOptions`).
|
/gemini review |
|
Warning You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again! |
|
/gemini review |
|
Warning You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again! |
Integrates
package:google_cloudfor structured logging, trace context, and standard environment variables.Details:
Loggerto extendCloudLoggerfrompackage:google_cloud.TraceContextDataand standard constants.fireUpserver startup to useTraceContextData.tryParse.removeCircularlogic and related tests (offloaded togoogle_cloud).google_cloud_storageto^0.6.0and addgoogle_clouddependency.logger.warningwithstackTraceetc).server_test.dartfor custom trace parsing.serviceEnvironmentVariable,projectIdEnvironmentVariableOptions).