Conversation
|
Warning Rate limit exceeded
Your organization is not enrolled in usage-based pricing. Contact your admin to enable usage-based pricing to continue reviews beyond the rate limit, or try again in 10 minutes and 1 seconds. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (9)
📝 WalkthroughWalkthroughAdds OTLP HTTP/protobuf exporter support alongside gRPC, introduces Changes
Sequence Diagram(s)sequenceDiagram
participant Plugin as Plugin Startup
participant Config as Config Loader
participant Otel as OTLP Setup
participant Collector as Collector / Exporter Target
Plugin->>Config: loadConfig()
Config-->>Plugin: return { protocol, endpoint, ... }
Plugin->>Otel: setupOtel(endpoint, protocol, ...)
alt protocol == "grpc"
Otel->>Collector: initialize gRPC exporters using host:port endpoint
else protocol == "http/protobuf"
Otel->>Otel: buildHttpSignalUrl(endpoint, traces/metrics/logs)
Otel->>Collector: initialize HTTP/protobuf exporters using /v1/traces, /v1/metrics, /v1/logs
end
Otel-->>Plugin: return OtelProviders (tracer, meter, logger)
Estimated Code Review Effort🎯 3 (Moderate) | ⏱️ ~20 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 3 | ❌ 2❌ Failed checks (1 warning, 1 inconclusive)
✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
🧹 Nitpick comments (1)
src/otel.ts (1)
57-61: JSDoc is outdated—still mentions only OTLP/gRPC.The function now supports both protocols, but the docstring wasn't updated.
📝 Suggested fix
/** * Initialises the OTel SDK — creates a `MeterProvider`, `LoggerProvider`, and - * `BasicTracerProvider` backed by OTLP/gRPC exporters pointed at `endpoint`, and + * `BasicTracerProvider` backed by OTLP exporters (gRPC or HTTP/protobuf) pointed at `endpoint`, and * registers them as the global providers. */🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@src/otel.ts` around lines 57 - 61, Update the JSDoc block above the OTel SDK initializer in src/otel.ts (the comment that currently references creating a `MeterProvider`, `LoggerProvider`, and `BasicTracerProvider`) to reflect that the function supports both OTLP/gRPC and OTLP/HTTP exporters; explicitly mention both protocols and any payload formats (e.g., protobuf/JSON) and note that exporters are pointed at the configured `endpoint`, and that the providers are registered globally so readers know both protocols are supported.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Nitpick comments:
In `@src/otel.ts`:
- Around line 57-61: Update the JSDoc block above the OTel SDK initializer in
src/otel.ts (the comment that currently references creating a `MeterProvider`,
`LoggerProvider`, and `BasicTracerProvider`) to reflect that the function
supports both OTLP/gRPC and OTLP/HTTP exporters; explicitly mention both
protocols and any payload formats (e.g., protobuf/JSON) and note that exporters
are pointed at the configured `endpoint`, and that the providers are registered
globally so readers know both protocols are supported.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 61a7ca51-57d4-4d2f-9b75-6ffa1ecb4a56
⛔ Files ignored due to path filters (1)
bun.lockis excluded by!**/*.lock
📒 Files selected for processing (8)
CHANGELOG.mdREADME.mdpackage.jsonsrc/config.tssrc/index.tssrc/otel.tstests/config.test.tstests/probe.test.ts
|
Addressed in follow-up commit I updated the |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@tests/jsdoc-coverage.test.ts`:
- Around line 5-6: The test currently hardcodes an absolute cwd and an unguarded
"bun" executable in the Bun.spawn call; change the Bun.spawn invocation in
tests/jsdoc-coverage.test.ts to use a relative/derived working directory (e.g.,
path.resolve(__dirname, '..') or process.cwd()) instead of the hardcoded
"/Users/…", and replace the literal "bun" in the command array with a
configurable value (e.g., process.env.BUN_PATH || "bun") so CI can point to the
correct binary; update the Bun.spawn call and its argv array accordingly to use
these variables.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: d09a25cb-991f-4612-a1c5-5f411fb9586b
⛔ Files ignored due to path filters (1)
bun.lockis excluded by!**/*.lock
📒 Files selected for processing (10)
.coderabbit.yaml.github/PULL_REQUEST_TEMPLATE.md.github/workflows/ci.yml.pre-commit-config.yamlCONTRIBUTING.mdeslint.config.mjspackage.jsonscripts/check-jsdoc-coverage.mjstests/jsdoc-coverage.test.tstsconfig.json
✅ Files skipped from review due to trivial changes (5)
- .github/workflows/ci.yml
- tsconfig.json
- .github/PULL_REQUEST_TEMPLATE.md
- .coderabbit.yaml
- CONTRIBUTING.md
🚧 Files skipped from review as they are similar to previous changes (1)
- package.json
Summary
OPENCODE_OTLP_PROTOCOLwithgrpcandhttp/protobufsupport while preservinggrpcas the default/v1/traces,/v1/metrics, and/v1/logsCloses #21
Testing
Summary by CodeRabbit
New Features
Documentation
Chores
Tests