Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
ruby mongo ドライバーを使用して、特定の GridFS ディレクトリ内のすべてのファイルを一覧表示することは可能ですか? ドキュメントを検索しましたが、満足のいくものは見つかりませんでした。さらに、メタデータでファイルを検索する方法も見つかりません。Java ドライバーのドキュメントを確認しましたが、これらの機能はどちらも GridFS クラスを使用してすぐに利用できます。
よろしくお願いします、
ミハウ
grid = Mongo::Grid.new(Mongoid.database) files = grid.instance_variable_get :@files files.find("filename" => "uploads/143-normal_regular2.jpg").as_json # files.remove - deletes alle files
チャンクでも同じように機能します