Repository navigation
Conversation
- Synchronized with master - Bug fixes
|
This is an automated comment for commit 9f5f27c with description of existing statuses. It's updated for the latest CI running
|
|
Example |
| } | ||
| } | ||
|
|
||
| String permissionsToString(fs::perms perms) |
There was a problem hiding this comment.
We shouldn't use "mini-languages" instead of structured data.
It should be represented by individual columns, e.g.
Bool user_can_read, user_can_write, user_can_execute, group_can_read, ...
There was a problem hiding this comment.
I didn't change this part yet from the initial PR. Makes sense
| {"symlink", DataTypeFactory::instance().get("Bool")}, | ||
| {"path", std::make_shared<DataTypeString>()}, | ||
| {"size", std::make_shared<DataTypeNullable>(std::make_shared<DataTypeUInt32>())}, | ||
| {"last_write_time", std::make_shared<DataTypeNullable>(std::make_shared<DataTypeDateTime>())}, |
There was a problem hiding this comment.
Maybe better to name it "modification_time".
| LOG_TEST(&Poco::Logger::get("StorageFilesystem"), "No data read from queue, stop processing"); | ||
| break; | ||
| } | ||
| current_block_size++; |
There was a problem hiding this comment.
Postincrement -> preincrement.
| LOG_DEBUG(&Poco::Logger::get("StorageFilesystem"), "Path {} is not inside user_files {}", | ||
| file_path.string(),path_info->user_files_absolute_path_string); | ||
| } | ||
| if (!path_info->queue.push(child)) |
There was a problem hiding this comment.
Why don't block? I expect it should work with an arbitrary number of files (several billion files as on GitHub).
There was a problem hiding this comment.
We can't block at least for max_threads=1.
I do not like this either, but current implementation will stuck on any number of threads if you have many directories with more directories in them. Something more creative is needed. Or just set 1bln as a limit...
There was a problem hiding this comment.
Hm, we can always use at least one thread reading the results from the queue and forming the result blocks, while other threads will fill the queue. It's ok to use max_threads + 1 threads, because max_threads is just a hint :) Moreover, only max_threads of them will be IO-heavy, and one extra thread will just fetch the results, so this is ok.
There was a problem hiding this comment.
I think it will be an elegant solution, let's try it.
| {"others_exec", DataTypeFactory::instance().get("Bool")}, | ||
| {"set_gid", DataTypeFactory::instance().get("Bool")}, | ||
| {"set_uid", DataTypeFactory::instance().get("Bool")}, | ||
| {"sticky_bit", DataTypeFactory::instance().get("Bool")} |
There was a problem hiding this comment.
It should also contain a column content with full file content as a String, but this column should be filled only when requested.
…ion-filesystem Merge table function filesystem. Originally ClickHouse#42039. Originally ClickHouse#50208.
Changelog category (leave one):
Changelog entry (a user-readable short description of the changes that goes to CHANGELOG.md):
Added table function
filesystemthat traverses filesystem and query file metadata. Forclickhouse-serveronlyuser_filesdirectory is accessible and files/directories linked to this directory.clickhouse-localhas no path limitations.Documentation entry for user-facing changes
Originally #42039 by @perst20