Copilot commented on code in PR #50044: URL: https://github.com/apache/arrow/pull/50044#discussion_r3427283123
########## cpp/src/arrow/testing/examplefs.h: ########## @@ -0,0 +1,28 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. + +#pragma once + +namespace arrow::fs { + +class ExampleTypedOption { + public: + virtual ~ExampleTypedOption() = default; + virtual int value() const = 0; +}; + +} // namespace arrow::fs Review Comment: `ExampleTypedOption` is used as the stored type inside `std::any` that is intended to cross a shared-library boundary (test executable -> `arrow_filesystem_example` module). In Arrow, types in `arrow/testing` that may be referenced across DSOs are typically marked with `ARROW_TESTING_EXPORT` to ensure RTTI/typeinfo visibility is consistent; without this, `std::any_cast<std::shared_ptr<ExampleTypedOption>>` can be fragile on platforms/builds with hidden visibility (and on Windows DLL boundaries). ########## cpp/src/arrow/filesystem/filesystem.h: ########## @@ -547,10 +580,34 @@ ARROW_EXPORT Result<std::shared_ptr<FileSystem>> FileSystemFromUri(const std::string& uri, std::string* out_path = NULLPTR); +/// \brief Create a new FileSystem by URI with extended backend-specific filesystem +/// options +/// +/// Recognized schemes are "file", "mock", "hdfs", "viewfs", "s3", +/// "gs", "gcs", "abfs" and "abfss". Review Comment: The PR description says the `local`/`file` factories were migrated to the new options-aware (4-arg) signature, but in the current branch `LocalFileSystemFactory` is still registered with the legacy 3-arg signature (cpp/src/arrow/filesystem/localfs.cc:720-733). As a result, `FileSystemFromUriAndOptions("file://...", non_empty_options, ...)` will return `NotImplemented` for the local filesystem. Either update the description, or migrate the local/file factory to accept and (if appropriate) validate/consume options. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
