Skip to content

Release a version including #611 (GC compaction segfault fix) #612

Description

@navidemad

Thanks a lot for merging #611 (74a2232). It fixes a production crash we have been hitting, and we would love to pick it up from RubyGems.

What we see

  • tiny_tds 3.4.0 (precompiled x86_64-linux-gnu), Ruby 4.0.7, Rails 8.1, Puma in cluster mode with preload_app!.
  • Our before_fork hook calls Process.warmup, which compacts the heap in the Puma master before the workers fork.
  • On some deploys, compaction moves TinyTds::Error. Every forked worker then inherits the stale cTinyTdsError pointer and crashes with SIGSEGV (SEGV_MAPERR) on its first connection to Azure SQL:
rb_class_new_instance_kw (object.c:2299)
rb_exc_new (error.c:1473)
rb_tinytds_raise_error
tinytds_msg_handler
_dblib_handle_info_message
tds_process_info
tds_process_login_tokens
tds_connect
tds_connect_and_login
tdsdbopen

Request

Could you publish a release (3.4.1?) that contains #611, including the precompiled native gems? Until then we will skip heap compaction before forking.

Thanks for maintaining tiny_tds!

Activity

  1. andyundso commented on Oct 8, 2026

    @andyundso
    Member
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions