Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lucene.Net.Store.Azure.AzureDirectory: Enable usage with a sasuri and existing containers #937

Open
1 task done
haavardeikeland opened this issue May 2, 2024 · 1 comment

Comments

@haavardeikeland
Copy link

Is there an existing issue for this?

  • I have searched the existing issues

Is your feature request related to a problem? Please describe the problem.

No response

Describe the solution you'd like

I'd like the Lucene.Net.Store.Azure.AzureDirectory to be enabled for usage with sasuri with existing containers instead of using the storage account connectionstring. Reason: to constrain access to containers for multiple usages on the same storage account.

Additional context

No response

@Shazwazza
Copy link
Contributor

Hi, Lucene.Net.Store.Azure.AzureDirectory is a 'dead' library and isn't maintained. Much of it has been forked in various repos and attempted to be updated to work. Most people don't fully understand what is actually does though:

What is doesn't do:

  • It does not allow you to share indexes between processes

What it does do:

  • It 'syncs' the lucene files from a central storage (i.e. Blob Storage) to local storage of the current process (i.e. %temp%) folder
  • It attempts to keep both the local storage and central storage in sync
  • When an Azure App Service using this library is moved to another worker, it will re-sync the main storage to local storage in an attempt to keep working as it was on the previous worker

The lib isn't maintained because this underlying process has several issues because depending on the index activity, writing this much to blob storage and local storage and keeping it in sync is difficult and can easily cause index corruption issues.

I have a similar implementation in the Examine library that is actively used by tons of Umbraco websites which is stable: https://github.com/Shazwazza/Examine/blob/release/3.0/src/Examine.Lucene/Directories/SyncedFileSystemDirectoryFactory.cs

This doesn't use Blob storage, but just the main file system in Azure App Service (which is a network drive) and syncs to the local %temp% file system.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants