LLNL / UnifyFS

UnifyFS: A file system for burst buffers
Other
106 stars 31 forks source link

Error code ignored #670

Closed roblatham00 closed 3 years ago

roblatham00 commented 3 years ago

System information

Type Version/Name
Operating System Linux
OS Version Ubuntu-20.04.02
Architecture x86
UnifyFS Version dev

Describe the problem you're observing

unifyfs_dispatch_io returns UNIFYFS_SUCCESS when it should not

Describe how to reproduce the problem

Well, clearly I have done something wrong in my UNIFY driver for ROMIO, but If I try to read a non-existent file, unifyfs_dispatch_io returns UNIFYFS_SUCCESS, even though unify internal implementation determined the file did not exist and set ENOENT at some point

Include any warning or errors or releveant debugging data

Look at https://github.com/LLNL/UnifyFS/blob/dev/client/src/client_read.c#L582

2021-08-17T10:38:28 tid=1619117 @ invoke_client_mread_rpc() [margo_client.c:829] invoking the mread rpc function in client
2021-08-17T10:38:28 tid=1619117 @ invoke_client_mread_rpc() [margo_client.c:842] Got response ret=2

ok, something went wrong... but before process_gfid_reads returns, on its way out it obliterates the return code: https://github.com/LLNL/UnifyFS/blob/dev/client/src/client_read.c#L739

client_remove_mread_reqeust() succeeds, rc is set to UNIFYFS_SUCESS and ROMIO thinks dispatch-io returned successfully. :crying_cat_face:

roblatham00 commented 3 years ago

NOTABUG: i should not look at unifyfs_dispatch_io return code -- the library did indeed dispatch i/o -- but should instead be looking at result.error field of the unifyfs_io_request