почему rails3 так глупо создает огромные пути загрузки?

#ruby-on-rails-3

#ruby-on-rails-3

Вопрос:

Я был разочарован временем запуска среды rails ~ 30 секунд в рабочей среде, поэтому немного отслеживал это, и, похоже, огромная часть этого — безумие с путями загрузки.

Вот журнал, включающий 3 файла — по какой-то причине они загружаются по-разному в каждом случае. Почему верхние проверяют каждый подкаталог сначала перед конечным каталогом? Есть предложения по оптимизации, чтобы улучшить это?

 lstat64("/data", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
lstat64("/data/u", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
lstat64("/data/u/apps", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
lstat64("/data/u/apps/newap", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
lstat64("/data/u/apps/newap/shared", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
lstat64("/data/u/apps/newap/shared/bundle", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
lstat64("/data/u/apps/newap/shared/bundle/ruby", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
lstat64("/data/u/apps/newap/shared/bundle/ruby/1.9.1", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
lstat64("/data/u/apps/newap/shared/bundle/ruby/1.9.1/gems", {st_mode=S_IFDIR|0755, st_size=12288, ...}) = 0
lstat64("/data/u/apps/newap/shared/bundle/ruby/1.9.1/gems/mail-2.3.0", {st_mode=S_IFDIR|0775, st_size=4096, ...}) = 0
lstat64("/data/u/apps/newap/shared/bundle/ruby/1.9.1/gems/mail-2.3.0/lib", {st_mode=S_IFDIR|0775, st_size=4096, ...}) = 0
lstat64("/data/u/apps/newap/shared/bundle/ruby/1.9.1/gems/mail-2.3.0/lib/mail", {st_mode=S_IFDIR|0775, st_size=4096, ...}) = 0
lstat64("/data/u/apps/newap/shared/bundle/ruby/1.9.1/gems/mail-2.3.0/lib/mail/parsers", {st_mode=S_IFDIR|0775, st_size=4096, ...}) = 0
lstat64("/data/u/apps/newap/shared/bundle/ruby/1.9.1/gems/mail-2.3.0/lib/mail/parsers/content_disposition.rb", {st_mode=S_IFREG|0644, st_size=12151, ...}) = 0


lstat64("/usr", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
lstat64("/usr/local", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
lstat64("/usr/local/rvm", {st_mode=S_IFDIR|S_ISGID|0775, st_size=4096, ...}) = 0
lstat64("/usr/local/rvm/rubies", {st_mode=S_IFDIR|S_ISGID|0775, st_size=4096, ...}) = 0
lstat64("/usr/local/rvm/rubies/ruby-1.9.2-p180", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
lstat64("/usr/local/rvm/rubies/ruby-1.9.2-p180/lib", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
lstat64("/usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
lstat64("/usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
lstat64("/usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/i686-linux", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
lstat64("/usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/i686-linux/enc", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
lstat64("/usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/i686-linux/enc/trans", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
lstat64("/usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/i686-linux/enc/trans/utf_16_32.so", {st_mode=S_IFREG|0755, st_size=17588, ...}) = 0
open("/usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/i686-linux/enc/trans/utf_16_32.so", O_RDONLY) = 10
read(10, "177ELF1113312604004"..., 512) = 512
fstat64(10, {st_mode=S_IFREG|0755, st_size=17588, ...}) = 0
mmap2(NULL, 10692, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 10, 0) = 0x589000
mmap2(0x58b000, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 10, 0x1) = 0x58b000
close(10)                               = 0
open("/data/u/apps/newap/releases/20111108044231/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/data/u/apps/newap/releases/20111108044231/vendor/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/data/u/apps/newap/releases/20111108044231/app/assets/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/data/u/apps/newap/releases/20111108044231/app/controllers/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/data/u/apps/newap/releases/20111108044231/app/helpers/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/data/u/apps/newap/releases/20111108044231/app/models/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/data/u/apps/newap/releases/20111108044231/vendor/plugins/country_select/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/newrelic_rpm-3.2.0/vendor/gems/metric_parser-0.1.0.pre1/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/yui-compressor-0.9.6/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/will_paginate-3.0.2/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/utility_belt-1.1.0/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/unicorn-3.7.0/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory);
...
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/coffee-rails-3.1.1/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/railties-3.1.1/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/thor-0.14.6/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/rack-ssl-1.3.2/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/coffee-script-2.2.0/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/execjs-1.2.9/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/coffee-script-source-1.1.2/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/cocaine-0.2.0/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/big_sitemap-1.0.0/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/rdoc-3.11/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/usr/local/rvm/gems/ruby-1.9.2-p180@newap/gems/bundler-1.0.17/gems/bundler-1.0.17/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/aws-s3-0.6.2/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/xml-simple-1.1.1/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/awesome_print-0.4.0/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/addressable-2.2.6/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/bundler/gems/acts_as_taggable_redux-19a19d2d5775/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
...
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/open4-1.2.0/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/Platform-0.4.0/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/rake-0.9.2.2/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/usr/local/rvm/gems/ruby-1.9.2-p180@newap/gems/bundler-1.0.17/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/site_ruby/1.9.1/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/site_ruby/1.9.1/i686-linux/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/site_ruby/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/vendor_ruby/1.9.1/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/vendor_ruby/1.9.1/i686-linux/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/vendor_ruby/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/i686-linux/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/action_controller/vendor/html-scanner/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/newrelic_rpm-3.2.0/vendor/gems/dependency_detection-0.0.1.build/lib/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/rack-mount-0.8.3/lib/rack/mount/vendor/regin/enc/trans/single_byte.rb", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/data/u/apps/newap/releases/20111108044231/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/data/u/apps/newap/releases/20111108044231/vendor/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/data/u/apps/newap/releases/20111108044231/app/assets/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/data/u/apps/newap/releases/20111108044231/app/controllers/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/data/u/apps/newap/releases/20111108044231/app/helpers/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/data/u/apps/newap/releases/20111108044231/app/models/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/data/u/apps/newap/releases/20111108044231/vendor/plugins/country_select/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/newrelic_rpm-3.2.0/vendor/gems/metric_parser-0.1.0.pre1/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/yui-compressor-0.9.6/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/will_paginate-3.0.2/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/utility_belt-1.1.0/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/unicorn-3.7.0/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/uglifier-1.0.4/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/sunspot_rails-1.3.0.rc4/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/sunspot-1.3.0.rc4/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/slim-1.0.3/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/temple-0.3.4/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/sass-rails-3.1.4/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/sass-3.1.10/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/sanitize-2.0.3/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/ruby-prof-0.10.8/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/rsolr-1.0.2/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/bundler/gems/rails-dev-boost-dd82d6caf24e/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/rails-3.1.1/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/pr_geohash-1.0.0/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/payment-1.0.1/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/parallel_tests-0.6.7/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/parallel-0.5.9/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/paperclip-2.4.5/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/oink-0.9.3/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/nokogiri-1.5.0/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/newrelic_rpm-3.2.0/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/mysql2-0.3.7/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/mysql2-0.3.7/ext/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/koala-1.2.1/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/kgio-2.6.0/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/irb_hacks-0.2.2/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/hodel_3000_compliant_logger-0.1.0/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/hirb-0.5.0/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/haml-3.1.3/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/flyrb-1.0.0.c/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/wirble-0.1.3/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/faraday-0.7.5/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/multipart-post-1.1.3/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/ezcrypto-0.7.2/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/escape-0.0.4/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/delayed_job-2.1.4/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/dalli-1.1.3/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/daemons-1.1.4/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/crewait-0.1.7/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/creditcard-1.0/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/cranky-0.3.1/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/coffee-rails-3.1.1/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/railties-3.1.1/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/thor-0.14.6/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/rack-ssl-1.3.2/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/coffee-script-2.2.0/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/execjs-1.2.9/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/coffee-script-source-1.1.2/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/cocaine-0.2.0/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/big_sitemap-1.0.0/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/rdoc-3.11/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/usr/local/rvm/gems/ruby-1.9.2-p180@newap/gems/bundler-1.0.17/gems/bundler-1.0.17/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/aws-s3-0.6.2/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/xml-simple-1.1.1/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/awesome_print-0.4.0/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/addressable-2.2.6/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/bundler/gems/acts_as_taggable_redux-19a19d2d5775/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/activeresource-3.1.1/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/activerecord-3.1.1/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/tzinfo-0.3.30/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/arel-2.2.1/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/activemerchant-1.18.1/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/money-3.7.1/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/json-1.6.1/ext/json/ext/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/json-1.6.1/ext/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/json-1.6.1/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/braintree-2.12.0/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/active_utils-1.0.1/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/actionmailer-3.1.1/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/mail-2.3.0/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/treetop-1.4.10/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/polyglot-0.3.2/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/mime-types-1.17.2/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/sprockets-2.0.3/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/tilt-1.3.3/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/hike-1.2.1/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/rack-test-0.6.1/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/rack-mount-0.8.3/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/rack-cache-1.1/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/rack-1.3.5/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/erubis-2.7.0/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/activemodel-3.1.1/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/i18n-0.6.0/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/builder-3.0.0/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/activesupport-3.1.1/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/multi_json-1.0.3/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/POpen4-0.1.4/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/open4-1.2.0/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/Platform-0.4.0/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/u/apps/newap/shared/bundle/ruby/1.9.1/gems/rake-0.9.2.2/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/usr/local/rvm/gems/ruby-1.9.2-p180@newap/gems/bundler-1.0.17/lib/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/site_ruby/1.9.1/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/site_ruby/1.9.1/i686-linux/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/site_ruby/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/vendor_ruby/1.9.1/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/vendor_ruby/1.9.1/i686-linux/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/vendor_ruby/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/i686-linux/enc/trans/single_byte.so", O_RDONLY|O_LARGEFILE) = 10
  

Комментарии:

1. просто в ответ на дополнительную работу, которую я проделал над этим, похоже, что вместо того, чтобы просто умно угадывать каталог для каждого загруженного модуля, он добавляет его в путь загрузки. Например, treetop нуждается в /u/apps/newap/shared /bundle/ruby /1.9.1 /gems / treetop-1.4.10/lib/ treetop.rb — поэтому, чтобы «потребовать» его, этот каталог необходимо добавить в путь загрузки. Но должна быть возможность взломать попытку запросить файл «guess» на основе этого модуля и избежать добавления его в путь загрузки, если его можно найти в ожидаемом расположении …/ lib/ module_name.rb, что ускоряет процесс.

Ответ №1:

Rails 3.2 немного улучшает это. Реальный ответ заключается в том, чтобы игнорировать такие вещи с низкой производительностью, как это, и быть терпеливым 🙂

Комментарии:

1. Это на самом деле не объясняет, ПОЧЕМУ разработчики rails изначально сочли это хорошей идеей, что, я думаю, является вопросом OP.