-
Notifications
You must be signed in to change notification settings - Fork 49
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: http protobuf otel ingestion (#2305)
* feat: add descriptor generation * feat: implement full otel protobuf ingestion * docs: remove http_protobuf limitation * chore: version bump * chore: fix tests that have renamed headers * fix: failing tests due to no match * chore: revert commented out lines * chore: formatting * chore: fix failing tests * chore: formatting
- Loading branch information
Showing
18 changed files
with
220 additions
and
93 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -76,4 +76,7 @@ gcloud_prod.json | |
# google keys | ||
.*.gcloud.json | ||
|
||
supabase | ||
supabase | ||
|
||
examples/**/.dev.vars | ||
examples/**/node_modules |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
1.10.9 | ||
1.10.10 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
defmodule Logflare.Utils.Map do | ||
@doc """ | ||
Retrieves a key, regardless of whether it is a string map or an atom map | ||
iex> #{__MODULE__}.get(%{test: 123}, :test) | ||
123 | ||
iex> #{__MODULE__}.get(%{"test"=> 123}, :test) | ||
123 | ||
""" | ||
@spec get(map :: map(), key :: atom()) :: term() | nil | ||
def get(map, key) when is_atom(key) do | ||
Map.get(map, key) || Map.get(map, Atom.to_string(key)) | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,7 @@ | ||
defmodule LogflareGrpc.Endpoint do | ||
use GRPC.Endpoint | ||
|
||
intercept(GRPC.Server.Interceptors.Logger, level: :debug) | ||
intercept LogflareGrpc.HttpProtobufInterceptor | ||
run(LogflareGrpc.Trace.Server) | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
defmodule LogflareGrpc.HttpProtobufInterceptor do | ||
@moduledoc false | ||
|
||
@behaviour GRPC.Server.Interceptor | ||
|
||
def init(opts) do | ||
opts | ||
end | ||
|
||
def call(rpc_req, stream, next, opts) do | ||
dbg({rpc_req, stream, next, opts}) | ||
{:ok, stream} | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.