You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When trying to call blob_lseek in a UDF fxn an exception is thrown and the UDF exits without crashing the server. When stepping through the code I noticed that only stream type blobs are allowed to use this function which explains why the exception is caught and thrown. However it would be very useful to be able to seek through the byte buffer in a blob instead of having to read all the way to the point where you want to start copying data.
I am not sure why this functionality is blocked but maybe a special condition can be put into the fun.cpp call when a UDF library is loaded. For example if a method that uses blobs is called the blob structure that is passed to the UDF function is given an address to a different callback fxn for blob_lseek or a flag can be added to the blob that allows a seek to occur correctly within the current blob_lseek callback fxn.
Any thoughts or suggestions?
The text was updated successfully, but these errors were encountered:
AFAIU, this issue has nothing to do with UDFs. The "seek" functionality is available in the public API as well and it has been always (read: by design) limited to stream blobs. If you want to read/write in the middle of the blob, just create stream blobs instead of segmented ones. They exist exactly for that purpose.
Submitted by: Steven Rosenberg (rosenbsn)
When trying to call blob_lseek in a UDF fxn an exception is thrown and the UDF exits without crashing the server. When stepping through the code I noticed that only stream type blobs are allowed to use this function which explains why the exception is caught and thrown. However it would be very useful to be able to seek through the byte buffer in a blob instead of having to read all the way to the point where you want to start copying data.
I am not sure why this functionality is blocked but maybe a special condition can be put into the fun.cpp call when a UDF library is loaded. For example if a method that uses blobs is called the blob structure that is passed to the UDF function is given an address to a different callback fxn for blob_lseek or a flag can be added to the blob that allows a seek to occur correctly within the current blob_lseek callback fxn.
Any thoughts or suggestions?
The text was updated successfully, but these errors were encountered: