diff options
author | Albert Chang <albert.chang@hitachivantara.com> | 2020-11-05 13:30:22 -0500 |
---|---|---|
committer | Albert Chang <albert.chang@hitachivantara.com> | 2020-11-05 13:30:22 -0500 |
commit | e2fba3ab0b1ae27fbaf607343be155527c1e8e49 (patch) | |
tree | 04e267bda8ebd8a56c72e9783ad4884aa9528b2e | |
parent | d1773f5b877f775191b87b8c5d044a16140e615b (diff) | |
download | fio-e2fba3ab0b1ae27fbaf607343be155527c1e8e49.tar.gz fio-e2fba3ab0b1ae27fbaf607343be155527c1e8e49.tar.bz2 |
engines/hdfs: swap fio_hdfsio_init and fio_hdfsio_io_u_init
Commit 08dc3bd50 initialized the io engine before the io_u buffers. The
unintended consequence for the libhdfs io engine was that the HDFS
connection was not established before attempting to open HDFS file
handles. This caused a NPE in the java layer on start-up preventing the
libhdfs io engine from being able to be used.
Signed-off-by: Albert Chang <albert.chang@hitachivantara.com>
-rw-r--r-- | engines/libhdfs.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/engines/libhdfs.c b/engines/libhdfs.c index 9ca82f78..eb55c3c5 100644 --- a/engines/libhdfs.c +++ b/engines/libhdfs.c @@ -240,7 +240,7 @@ int fio_hdfsio_close_file(struct thread_data *td, struct fio_file *f) return 0; } -static int fio_hdfsio_init(struct thread_data *td) +static int fio_hdfsio_io_u_init(struct thread_data *td, struct io_u *io_u) { struct hdfsio_options *options = td->eo; struct hdfsio_data *hd = td->io_ops_data; @@ -349,7 +349,7 @@ static int fio_hdfsio_setup(struct thread_data *td) return 0; } -static int fio_hdfsio_io_u_init(struct thread_data *td, struct io_u *io_u) +static int fio_hdfsio_init(struct thread_data *td) { struct hdfsio_data *hd = td->io_ops_data; struct hdfsio_options *options = td->eo; |