-
Notifications
You must be signed in to change notification settings - Fork 4
/
README.txt
87 lines (57 loc) · 2.06 KB
/
README.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
===========
afspy
===========
afspy are (as the name suggests) python bindings to AFS, here
in the implementation of openAFS.
It provides a high-level interface to AFS.
Also, database-cacheing of information is supported.
Asynchronous and detached access to AFS is planned so that
an application using afspy remains responsive at all times.
Layout
======
The different parts of this package are :
* afs/ : The actual module
* afs/lla/ : low-level internal interface
* afs/service/ : high-level interface
* afs/model/ : object declarations
* afs/orm/ : object-relational-mapping functionality used fo DB-Cache
* afs/util/ : helper functions
* tests/ : unit-tests, requires some configuration to run in your cell
Usage
=====
You can start an interactive python shell
Interactively:
PYTHONSTARTUP=<PATH/TO/AFS-Module>/etc/pythonstartup python
in scripts:
see examples
Configuration
=============
Config options are read as :
1. read system wide configuration file:
Path is hard-coded in module
2. read user's personal $HOME/.config/afspy
3. read config file given on command line
4. use options given on command line
Later definitions override earlier ones.
This configuration is stored in a AfsConfig-object.
and passed to any service called by default.
Contents of the AfsConfig
========================
* Credential to use
* default AFS Cellname
* default Keberos REALM
* DB-implementation to use.
* Logging. There are two types of Loglevels,
* the global one for all modules :
e.g. globalLogLevel="[debug|info|warn|critical]"
* a class local one to override the global one for certain classes.
CSV list of Classname=Loglevel pairs:
e.g. classLogLevels="CellService=warn,UbikPeerDAO=warn,FileServerDAO=debug"
beside the normal classes, also "util" and "sqlalchemy" are available.
DB-Cacheing
===========
If the option DB_CACHE is set to True.
A connection to the configured DB is set up
and stored in the AfsConfig-Object.
Every service creates its own session, so that any created Object is attached
to the DB-Cache as long as the service is alive.