Open vvandermeij opened 2 years ago
Hey @vvandermeij, thanks for reaching out. It sounds like something that might be a bit tricky for me to reproduce, so might take some time to debug.
Would you be able to share some snippets of how you use the library in your code?
Do you instantiate the AzureBlobFileSystem
on startup, and then call DeltaTable(...)
every time someone interacts with the app?
Hi @jeppe742 Thank you for the quick response.
fs = AzureBlobFileSystem(
account_name=account_name,
credential=sas_key
)
Is initiated at least once every time a user uses the app. the function where we get the error the most often is the following:
def find_adres(eenheidnum, fs):
"""function that retrieves the adres of a eenheidnummer from the datalake.
Args:
eenheidnum: the eenheidnum that we want to know the adres from
fs: the file system that is used to log in to the datalake
Returns:
a pandas dataframe with the adres
"""
return (DeltaTable("20-silver/edh/woc_eenheden", file_system=fs)
.to_table(columns=['huisnummer',
'straatnaam',
'huisnummertoevoeging',
'huisnummerletter'],
filter=(ds.field('eenheidnummer') == eenheidnum))
.to_pandas())
Thank you for looking in to this!
Summary
I am trying to host an app online that has to read blobs with deltalake format from azure blobstorage. To do this I use: AzureBlobFileSystem from adlfs DeltaTable from deltalake. When hosting the website, (with azure App service) everything works well: When given input, the app reads the data from azure blob storage and returns the correct tables. The problem occurs when the app has been online and unused for several hours: When the app tries to read from the deltalake storage it fails and raises an HttpResponseError with a traceback that is not clear enough for me to understand what the actual issue is. When I restart the app, everything works fine again untill you wait for a few hours: The same bug keeps returning. I am not sure if the problem occurs in the adlfs package or the deltalake package. I hope that someone here can help to understand where it is failing and why and knows a solution to the problem! Thanks in advance
Traceback