

Ruby gem 2.7: Improvements and bug fixes
source link: https://blog.appsignal.com/2018/08/13/ruby-gem-2-7
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.


We just released AppSignal for Ruby gem version 2.7.0 which allows for longer tag values to be sent, supports more precise values for custom metrics and adds the working_directory_path
option to replace working_dir_path
.
Longer tags
Previously the tag limit was set to 100 characters. This proved too short for some cases. Values were dropped if they had a length longer than 100 characters to keep samples from becoming too large.
Now, tags for AppSignal transactions (web requests, background jobs, etc.) have a new 256 maximum value limit. Tags aren't dropped if they exceed the value limit, but they're truncated to 265 characters if needed.
Appsignal.tag_request(:tag => "value")
Appsignal.tag_job(:tag => "value")
Doubles for custom metrics
Custom metrics always supported integers as values for the count
metric. This allowed you to increment the counter with whole numbers, but not fractions. In Ruby gem 2.7 you can increment the counter by 0.10
, 0.20
, 0.30
, etc. Add that extra bit of precision to your counters!
Appsignal.increment_counter("metric_name", 3.14)
New working_directory_path
option
In this release we've reworked the option that configures where the AppSignal working directory is located. (Read about what the working directory is used for in our docs.)
There already was the working_dir_path
option, but it's behavior wasn't completely self explanatory. For one, it appended /appsignal
to the path.
# config/appsignal.yml
production:
working_dir_path: "/tmp/my_app/"
# would become
working_dir_path: "/tmp/my_app/appsignal"
Instead working_directory_path
will not append the path to the user specified path. It will create the specified path if it does not exist yet.
You can switch to the working_directory_path
option without any additional configuration. Do note the /appsignal
sub directory will no longer be created.
In this release we've also immediatly deprecated the working_dir_path
option. Please use working_directory_path
instead.
It's also possible configure the working_directory_path
option with an environment variable.
Other improvements
- Detect Kubernetes machines as containers for
running_in_container
config option. No more need to configure this manually for Kubernetes machines 🎉
Please see the changelog for more details about these improvements, deprecations and other changes. And as always: get in touch if you encounter problems after upgrading. We're happy to help!
Recommend
-
14
How Not to Develop a Ruby Gem Over the last couple of days I've been working on LazyMigrate, a gem which provides a little UI for handling migrations in rails. Because it's...
-
9
Converting a Ruby Class Library to a Gem Aug 12, 2020 This blog post talks about my experiences converting a handful of Ruby c...
-
11
Inspecting the Contents of a Ruby Gem 16 Dec 2020 From time to time you’ll need to inspect the contents of a locally installed Ruby gem. For instance - I needed to check the contents of my Jekyll th...
-
7
We just released Ruby Gem 2.11. We are always making things easier to use for you, so more things work out of the box and more instrumentation and dashboarding is built without you doing any heavy lifting. This release has a big overhaul of A...
-
11
In case you missed it, we released Ruby gem 2.10. It focusses mostly on diagnose and configuration. Though a bit late, here’s a round-up of what’s in the release. The Idea Behind 2.10 Improvements We support many setups and c...
-
13
“I absolutely love AppSignal.” Discover AppSignal We just released AppSignal for Ruby gem version 2.7.0 whic...
-
7
“I absolutely love AppSignal.” Discover AppSignal We just released AppSignal for Ruby gem version 2.6.0 2.6....
-
12
New in Sketch: Improvements and bug fixes Version 73 of the Mac app is out now. With this update, we’ve focused on bug fixes and quality-of-life improvements to make the whole Sketch experience even better....
-
9
Apple releases macOS Ventura 13.2.1
-
6
Ruby 3.3 fixes duplicate keyword argument warning bug Dec 18, 2023 •
About Joyk
Aggregate valuable and interesting links.
Joyk means Joy of geeK