-
-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use InsertManyAsync() on import to reduce connections to mongo. (#1054)
- Loading branch information
1 parent
b4c4416
commit 2926273
Showing
6 changed files
with
81 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,27 @@ | ||
using System.Threading.Tasks; | ||
using System.Collections.Generic; | ||
using System.Threading.Tasks; | ||
using BackendFramework.Models; | ||
using SIL.Lift.Parsing; | ||
|
||
namespace BackendFramework.Interfaces | ||
{ | ||
public interface ILiftService | ||
{ | ||
ILexiconMerger<LiftObject, LiftEntry, LiftSense, LiftExample> GetLiftImporterExporter( | ||
ILiftMerger GetLiftImporterExporter( | ||
string projectId, IProjectService projectService, IWordRepository wordRepo); | ||
void LdmlImport(string filePath, string langTag, IProjectService projectService, Project project); | ||
Task<string> LiftExport(string projectId, IWordRepository wordRepo, IProjectService projectService); | ||
|
||
// Methods to store, retrieve, and delete an export string in a common dictionary | ||
// Methods to store, retrieve, and delete an export string in a common dictionary. | ||
void StoreExport(string key, string filePath); | ||
string? RetrieveExport(string key); | ||
bool DeleteExport(string key); | ||
void SetExportInProgress(string key, bool isInProgress); | ||
bool IsExportInProgress(string key); | ||
} | ||
|
||
public interface ILiftMerger : ILexiconMerger<LiftObject, LiftEntry, LiftSense, LiftExample> | ||
{ | ||
Task<List<Word>> SaveImportEntries(); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters