@@ -203,7 +203,7 @@ static int tail_fs_event(struct flb_input_instance *ins,
203203
204204 /* A rotated file must be re-registered */
205205 flb_tail_file_rotated (file );
206- flb_tail_fs_remove (file );
206+ flb_tail_fs_remove (ctx , file );
207207 flb_tail_fs_add_rotated (file );
208208 }
209209
@@ -291,12 +291,14 @@ static int tail_fs_event(struct flb_input_instance *ins,
291291}
292292
293293/* File System events based on Inotify(2). Linux >= 2.6.32 is suggested */
294- int flb_tail_fs_init (struct flb_input_instance * in ,
294+ int flb_tail_fs_inotify_init (struct flb_input_instance * in ,
295295 struct flb_tail_config * ctx , struct flb_config * config )
296296{
297297 int fd ;
298298 int ret ;
299299
300+ flb_plg_debug (ctx -> ins , "flb_tail_fs_inotify_init() initializing inotify tail input" );
301+
300302 /* Create inotify instance */
301303 fd = inotify_init1 (IN_NONBLOCK | IN_CLOEXEC );
302304 if (fd == -1 ) {
@@ -318,17 +320,17 @@ int flb_tail_fs_init(struct flb_input_instance *in,
318320 return 0 ;
319321}
320322
321- void flb_tail_fs_pause (struct flb_tail_config * ctx )
323+ void flb_tail_fs_inotify_pause (struct flb_tail_config * ctx )
322324{
323325 flb_input_collector_pause (ctx -> coll_fd_fs1 , ctx -> ins );
324326}
325327
326- void flb_tail_fs_resume (struct flb_tail_config * ctx )
328+ void flb_tail_fs_inotify_resume (struct flb_tail_config * ctx )
327329{
328330 flb_input_collector_resume (ctx -> coll_fd_fs1 , ctx -> ins );
329331}
330332
331- int flb_tail_fs_add (struct flb_tail_file * file )
333+ int flb_tail_fs_inotify_add (struct flb_tail_file * file )
332334{
333335 int ret ;
334336 struct flb_tail_config * ctx = file -> config ;
@@ -343,7 +345,7 @@ int flb_tail_fs_add(struct flb_tail_file *file)
343345 return 0 ;
344346}
345347
346- int flb_tail_fs_remove (struct flb_tail_file * file )
348+ int flb_tail_fs_inotify_remove (struct flb_tail_file * file )
347349{
348350 struct flb_tail_config * ctx = file -> config ;
349351
@@ -359,7 +361,7 @@ int flb_tail_fs_remove(struct flb_tail_file *file)
359361 return 0 ;
360362}
361363
362- int flb_tail_fs_exit (struct flb_tail_config * ctx )
364+ int flb_tail_fs_inotify_exit (struct flb_tail_config * ctx )
363365{
364366 (void ) ctx ;
365367 return 0 ;
0 commit comments