summermousa-vendia commented on code in PR #1635:
URL: https://github.com/apache/iceberg-python/pull/1635#discussion_r1954849491


##########
mkdocs/docs/configuration.md:
##########
@@ -287,6 +287,55 @@ class UUIDLocationProvider(LocationProvider):
         return f"{prefix}/{partition_key.to_path()}/{data_file_name}" if 
partition_key else f"{prefix}/{data_file_name}"
 ```
 
+### Loading a Custom FileIO Implementation
+
+The `PyIceberg` library allows you to use custom FileIO implementations, 
enabling flexible file handling tailored to your specific needs. This feature 
is particularly useful when working with different storage backends or file 
formats. To implement a custom FileIO, you can specify the `PY_IO_IMPL` 
property in your configuration. The property should point to the custom FileIO 
class you wish to use.
+
+An example, custom `FileIO` implementation is shown below.
+
+```py
+from pyiceberg.io import InputFile, OutputFile
+from pyiceberg.io.fsspec import FsspecFileIO
+from urllib.parse import urlparse
+import os
+
+class RelativeFileIO(FsspecFileIO):

Review Comment:
   I just wrote a python implementation of this jar plugin:
   https://github.com/lightmelodies/iceberg-relative-io
   
   I am using this implementation for my own project and it works as I would 
expect.
   
   What kind of example would you prefer me to include?  I was hoping to write 
something a little bit contrived just so that people could be familiar with how 
to implement their own fileIO plugins.
   
   How would you like me to change it?



-- 
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: issues-unsubscr...@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@iceberg.apache.org
For additional commands, e-mail: issues-h...@iceberg.apache.org

Reply via email to