Skip to content

Commit 79f3d1a

Browse files
authored
Merge pull request #20 from BNLNPPS/maxim-refactor
Updated documentation
2 parents dec3f5e + 51f03bc commit 79f3d1a

File tree

3 files changed

+50
-3
lines changed

3 files changed

+50
-3
lines changed

README.md

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ Common libraries and utilities for the swf-testbed ePIC streaming workflow testb
44

55
## Overview
66

7-
This library provides shared functionality for SWF agents, including logging utilities and REST API integration for the swf-monitor service.
8-
Also included are utility classes wrapping MQ and Rucio communications.
7+
This library provides shared functionality for SWF agents, including logging utilities and REST API
8+
integration for the swf-monitor service. Also included are utility classes wrapping MQ and Rucio communications.
99

1010
## Installation
1111

@@ -85,4 +85,10 @@ When the monitor service is available, logs are sent to the database via REST AP
8585

8686
### Logging Utils (`swf_common_lib.logging_utils`)
8787

88-
Traditional logging utilities for PostgreSQL database integration.
88+
Traditional logging utilities for PostgreSQL database integration.
89+
90+
## MQ and Rucio Utility packages
91+
92+
The *mq_comms* and *rucio_comms* packages provide convenient encapsulation of interactions
93+
with the ActiveMQ and Rucio systems, respectively. Each folder contains it's own README file
94+
with more details.

mq_comms/README.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,3 +34,8 @@ a set defined as follows:
3434
'stf_gen', 'data_ready'
3535
}
3636
```
37+
38+
## Subscription
39+
40+
For the _Receiver_ class, it's important to create a unique subscription for
41+
reliable delivery of messages. This is done via the argument *client_id*.

rucio_comms/README.md

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
# Rucio comms
2+
3+
The rucio_comms package is a Python library that provides a high-level interface for interacting with Rucio. Here are its key components and features:
4+
5+
1. Core Classes:
6+
- `FileManager`: Manages Rucio file operations
7+
- Registers file replicas with existing PFNs
8+
- Associates files with datasets
9+
- Handles batch operations for multiple files
10+
- Tracks registered files
11+
12+
- `DatasetManager`: Handles Rucio dataset operations
13+
- Creates and manages datasets
14+
- Sets metadata, lifetime, and status
15+
- Follows PanDA-style dataset management patterns
16+
17+
- `FileInfo`: Represents a file with its metadata
18+
- Handles logical/physical file names (LFN/PFN)
19+
- Manages checksums, size, and GUIDs
20+
- Validates file attributes
21+
22+
2. Utility Modules:
23+
- `RucioUtils`: Helper functions for Rucio operations
24+
- Scope extraction from dataset names
25+
- GUID and VUID generation
26+
- PFN parsing and formatting
27+
28+
- `ValidationUtils`: Input validation
29+
- Validates dataset names, scopes, LFNs, PFNs
30+
- Checks checksums and file sizes
31+
- Enforces format rules
32+
33+
- `MetadataUtils`: Metadata handling
34+
- Creates standardized file metadata
35+
- Manages dataset metadata
36+
- Follows PanDA/Rucio metadata conventions

0 commit comments

Comments
 (0)