You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, while debugging my own code, stumbled over this in saml_message.rb:
Dir.chdir(File.expand_path(File.join(File.dirname(__FILE__), '..', '..', 'schemas'))) do
@schema = Nokogiri::XML::Schema(IO.read('saml-schema-protocol-2.0.xsd'))
@xml = Nokogiri::XML(document.to_s)
end
In a single threaded environment this is not an issue, but when there are more parallel threads running, there is a time window when the current working directory is changed for all threads. That could lead to random production failures on Rails using Puma for example ...
The text was updated successfully, but these errors were encountered:
This at least eliminates chdir at run-time - it only does chdir once when .rb files are required. Should also improve performance since it eliminates disk IO at validation time.
Hi, while debugging my own code, stumbled over this in saml_message.rb:
In a single threaded environment this is not an issue, but when there are more parallel threads running, there is a time window when the current working directory is changed for all threads. That could lead to random production failures on Rails using Puma for example ...
The text was updated successfully, but these errors were encountered: