-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #15 from yacchin1205/feature/solr-r2
Switch backend from MongoDB to Solr
- Loading branch information
Showing
67 changed files
with
5,771 additions
and
10,857 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,7 +6,7 @@ cache: | |
- $HOME/.cache/bower | ||
- $HOME/.cache/pip | ||
python: | ||
- 3.7 | ||
- 3.9 | ||
|
||
env: | ||
global: | ||
|
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,4 +1,3 @@ | ||
pytest | ||
pytest-asyncio | ||
nose | ||
mock |
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,10 +1,8 @@ | ||
c.NBSearchApp.port = 9999 | ||
import os | ||
|
||
c.NBSearchDB.hostname = 'localhost' | ||
c.NBSearchDB.database = 'test_db' | ||
c.NBSearchDB.collection = 'test_notebooks' | ||
c.NBSearchDB.history = 'test_history' | ||
c.NBSearchDB.username = '' | ||
c.NBSearchDB.password = '' | ||
c.NBSearchDB.solr_base_url = 'http://localhost:8983' | ||
c.NBSearchDB.s3_endpoint_url = 'http://localhost:9000' | ||
c.NBSearchDB.s3_access_key = os.environ['MINIO_ACCESS_KEY'] | ||
c.NBSearchDB.s3_secret_key = os.environ['MINIO_SECRET_KEY'] | ||
|
||
c.LocalSource.base_dir = '/home/jovyan' |
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 |
---|---|---|
@@ -0,0 +1,27 @@ | ||
# Solr | ||
import tempfile | ||
|
||
def _run_solr_proxy(port): | ||
conf = tempfile.NamedTemporaryFile(mode='w', delete=False) | ||
conf.write(''' | ||
LogLevel Warning | ||
PidFile "/run/tinyproxy/tinyproxy.pid" | ||
Logfile "/tmp/tinyproxy-solr.log" | ||
MaxClients 5 | ||
MinSpareServers 5 | ||
MaxSpareServers 20 | ||
StartServers 10 | ||
Port {port} | ||
ReverseOnly Yes | ||
Upstream http localhost:8983 | ||
'''.format(port=port)) | ||
conf.close() | ||
return ['tinyproxy', '-d', '-c', conf.name] | ||
|
||
c.ServerProxy.servers = { | ||
'solr': { | ||
'command': _run_solr_proxy, | ||
'absolute_url': True, | ||
'timeout': 30, | ||
} | ||
} |
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
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
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 was deleted.
Oops, something went wrong.
Oops, something went wrong.