Skip to content
This repository was archived by the owner on Nov 5, 2025. It is now read-only.
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added .DS_Store
Binary file not shown.
8 changes: 4 additions & 4 deletions fabfile/APPspecific.py
Original file line number Diff line number Diff line change
Expand Up @@ -164,9 +164,9 @@ def start_APP_and_check_status():
with cd('{0}'.format(APP_source_dir())):
virtualenv('python -m unittest discover test')
# run('mkdir -p /tmp/fuse')
# virtualenv('posix_space --cfg test_vo.ini > /tmp/space.log 2>&1')
# virtualenv('posix_space --cfg test_vo_posix.ini > /tmp/space.log 2>&1')
# time.sleep(2)
# virtualenv('posix_storage --cfg test_vo.ini > /tmp/storage.log 2>&1')
# virtualenv('posix_storage --cfg test_vo_posix.ini > /tmp/storage.log 2>&1')
# time.sleep(2)
# virtualenv('python -m pyvospace.client.fuse --host localhost --port 8080 --username test --password test --mountpoint /tmp/fuse/`` > /tmp/fusemnt.log 2>&1')
# time.sleep(2)
Expand All @@ -186,9 +186,9 @@ def sysinitstart_APP_and_check_status():
with cd('{0}'.format(APP_source_dir())):
# virtualenv('python -m unittest discover test')
# run('mkdir -p /tmp/fuse')
# virtualenv('posix_space --cfg test_vo.ini > /tmp/space.log 2>&1')
# virtualenv('posix_space --cfg test_vo_posix.ini > /tmp/space.log 2>&1')
# time.sleep(2)
# virtualenv('posix_storage --cfg test_vo.ini > /tmp/storage.log 2>&1')
# virtualenv('posix_storage --cfg test_vo_posix.ini > /tmp/storage.log 2>&1')
# time.sleep(2)
# virtualenv('python -m pyvospace.client.fuse --host localhost --port 8080 --username test --password test --mountpoint /tmp/fuse/`` > /tmp/fusemnt.log 2>&1')
# time.sleep(2)
Expand Down
62 changes: 62 additions & 0 deletions pyvospace/server/spaces/ngas/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
# pyvospace-ngas
NGAS plugin for PyVOSpace, implementation in Python3.

This plugin provides a PyVOSpace implementation that uses an NGAS server as the backing store. The plugin connects to both a PostgreSQL database and one or more federated instances of an NGAS server.

**Requirements**

- Python3.6 or greater.
- Docker support for running a PostgreSQL server.
- Access to a running NGAS server or servers. To setup an NGAS server please see the [online documentation](https://ngas.readthedocs.io/en/latest/).
- FUSE filesystem modules (including fusepy).

**Installation**

For installation, including setting up the docker database instance, please see the main ICRAR PyVOSpace [documentation page](https://github.com/ICRAR/pyvospace/blob/master/README.md).

**Basic configuration**

The file *test_vo_ngas.ini* contains a default configuration, as shown below.

```
[Space]
host = localhost
port = 8082
name = ngas
uri = icrar.org
dsn = postgres://vos_user:vos_user@localhost:5435/vospace
parameters = {}
secret_key = ZlmNyXdQgRhhrC2Wwy-gLZj7Wv6ZtoKH
domain =
use_ssl = 0

[Storage]
name = ngas
host = localhost
port = 8083
parameters = {"staging_dir": "/tmp/ngas/staging/"}
use_ssl = 0
ngas_servers=[{"hostname" : "localhost", "port" : 7777},
{"hostname" : "localhost", "port" : 7777}]
```

Note the *ngas_servers* line. Multiple NGAS servers may be specified here, and it is assumed that the NGAS servers are synchronised and can work with the same information. At runtime an NGAS server will be chosen at random for both the space and storage servers.

**Running the Space and Storage servers**

'ngas_space --cfg test_vo_ngas.ini'
'ngas_storage --cfg test_vo_ngas.ini'

**Unit tests**

Unit tests are located in test/test_ngas/\*.py and assume an NGAS server is running on localhost at port 7777.

**Common errors**

If you see an error such as,

```
raise aiohttp.web.HTTPServerError(reason=f"File {filename_ngas} not deleted properly from NGAS server"),
```

it means that the NGAS server is not configured with caching enabled and has refused to delete a file. In this instance check if you want the NGAS server to be able to delete files and then enable caching in the NGAS server configuration.
1 change: 1 addition & 0 deletions pyvospace/server/spaces/ngas/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
from pyvospace.server.spaces.ngas.space.ngas_space import *
Loading