Closed qnm closed 5 years ago
@qnm thanks for the report! I'll take a look and see if I can reproduce and fix this issue. I think you're correct in that you should be able to mount racks apps in the standard way and have the beeline support this
@qnm I've managed to reproduce this! Looking into a fix now
@martin308 Only way I could think of was to supress the exception, which is a pretty blunt mechanism :(
@qnm I've found a fix! Just trying to write a test to reproduce it and I'll push it up
@qnm I've pushed up a fix for this here. I wasn't able to reproduce it in a test though. I tried it with a basic twirp handler which reproduced the issue and this fix resolved it. Let me know what you think
Thanks @martin308 I hope to be able to test it today.
I use https://github.com/twitchtv/twirp-ruby as part of a Rails app to provide Twirp RPC support.
I mount the Twirp app inside
config/routes.rb
as a rack app using mount e.g.mount connections, :at => connections.full_name
where connections is a Twirp handler.The issue I face is that the Rails instrumentation is applied during Twirp/rack requests, and the call to
request.param
in https://github.com/honeycombio/beeline-ruby/blob/master/lib/honeycomb/integrations/rails.rb#L16 returns the errorActionDispatch::Http::Parameters::ParseError
.One option may be to mount the Twirp app inside
config.ru
however mounting rack apps in Rails is a supported operation https://apidock.com/rails/ActionDispatch/Routing/Mapper/Base/mountThanks in advance for your help.