cancel
Showing results for 
Search instead for 
Did you mean: 
Data Engineering
cancel
Showing results for 
Search instead for 
Did you mean: 

Autoloader directory listing not listing all files

FabriceDeseyn
Contributor

Hi community

I have an Autoloader pipeline running with following configuration. Unfortunately, it does not detect all files. (see below query definition).

image.pngimage.png 

The folder that needs to be read has 38.246 files that all have the same schema and structure.:

image.pngIf I look at the `cloud_files_state`, I see get 4999 files. Do I do something wrong? Is this an 'initial' count that will be increased if these files are ingested?

image.png

1 ACCEPTED SOLUTION

Accepted Solutions

Lakshay
Esteemed Contributor
Esteemed Contributor

Hi @Fabrice Deseyn​ , My understanding is that this could be because Autoloader returns a fixed no. of results per API call as explained here: https://docs.databricks.com/ingestion/auto-loader/directory-listing-mode.html#how-does-directory-lis...

View solution in original post

5 REPLIES 5

daniel_sahal
Honored Contributor III

@Fabrice Deseyn​ 

It looks like your storage is not prepared for incremental listing. Use normal Directory Listing to get all of the files.

https://docs.databricks.com/ingestion/auto-loader/directory-listing-mode.html#date-partitioned-files

@Daniel Sahal​ 

Thanks, apparently I looked over the useIncrementalListing setting... big mistake from my side...

Thanks for the second pair of eyes!

So, I changed the code (also tried with False) and have put a new checkpoint. This however still keeps giving me the same amount of files.

image.png 

Lakshay
Esteemed Contributor
Esteemed Contributor

Hi @Fabrice Deseyn​ , My understanding is that this could be because Autoloader returns a fixed no. of results per API call as explained here: https://docs.databricks.com/ingestion/auto-loader/directory-listing-mode.html#how-does-directory-lis...

Anonymous
Not applicable

Hi @Fabrice Deseyn​ 

Thank you for posting your question in our community! We are happy to assist you.

To help us provide you with the most accurate information, could you please take a moment to review the responses and select the one that best answers your question?

This will also help other community members who may have similar questions in the future. Thank you for your participation and let us know if you need any further assistance! 

Welcome to Databricks Community: Lets learn, network and celebrate together

Join our fast-growing data practitioner and expert community of 80K+ members, ready to discover, help and collaborate together while making meaningful connections. 

Click here to register and join today! 

Engage in exciting technical discussions, join a group with your peers and meet our Featured Members.