|
| 1 | +========================== |
| 2 | +OpenSPP Aggregation Engine |
| 3 | +========================== |
| 4 | + |
| 5 | +.. |
| 6 | + !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! |
| 7 | + !! This file is generated by oca-gen-addon-readme !! |
| 8 | + !! changes will be overwritten. !! |
| 9 | + !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! |
| 10 | + !! source digest: sha256:9951d094574dd68b1d86ae2167e53c5ccea5240188acf11a2b7f619ede6c5b54 |
| 11 | + !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! |
| 12 | +
|
| 13 | +.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png |
| 14 | + :target: https://odoo-community.org/page/development-status |
| 15 | + :alt: Beta |
| 16 | +.. |badge2| image:: https://img.shields.io/badge/license-LGPL--3-blue.png |
| 17 | + :target: http://www.gnu.org/licenses/lgpl-3.0-standalone.html |
| 18 | + :alt: License: LGPL-3 |
| 19 | +.. |badge3| image:: https://img.shields.io/badge/github-OpenSPP%2FOpenSPP2-lightgray.png?logo=github |
| 20 | + :target: https://github.com/OpenSPP/OpenSPP2/tree/19.0/spp_aggregation |
| 21 | + :alt: OpenSPP/OpenSPP2 |
| 22 | + |
| 23 | +|badge1| |badge2| |badge3| |
| 24 | + |
| 25 | +Unified aggregation engine for computing statistics, breakdowns, and |
| 26 | +fairness metrics over scoped registrant populations. Supports multiple |
| 27 | +scope types (CEL expressions, areas, spatial queries, explicit IDs) with |
| 28 | +access control, caching, and privacy enforcement. |
| 29 | + |
| 30 | +Key Capabilities |
| 31 | +~~~~~~~~~~~~~~~~ |
| 32 | + |
| 33 | +- Define reusable aggregation scopes: CEL expression, area, area tag, |
| 34 | + spatial polygon/buffer, or explicit registrant IDs |
| 35 | +- Resolve scopes to registrant sets with union and intersection |
| 36 | + operations |
| 37 | +- Compute statistics (count, Gini) with extensible statistic registry |
| 38 | + supporting CEL variables |
| 39 | +- Role-based access control with per-user scope type restrictions, |
| 40 | + dimension limits, and area constraints |
| 41 | +- Result caching with configurable TTL per scope type and automatic |
| 42 | + cleanup |
| 43 | +- Privacy enforcement via k-anonymity suppression on computed results |
| 44 | +- Convenience methods for area-based, expression-based, fairness, and |
| 45 | + distribution queries |
| 46 | + |
| 47 | +Key Models |
| 48 | +~~~~~~~~~~ |
| 49 | + |
| 50 | ++----------------------------+----------+----------------------------+ |
| 51 | +| Model | Type | Description | |
| 52 | ++============================+==========+============================+ |
| 53 | +| ``spp.aggregation.scope`` | Concrete | Configurable aggregation | |
| 54 | +| | | scope definitions | |
| 55 | ++----------------------------+----------+----------------------------+ |
| 56 | +| ``spp | Concrete | Per-user/group access | |
| 57 | +| .aggregation.access.rule`` | | control rules | |
| 58 | ++----------------------------+----------+----------------------------+ |
| 59 | +| ``spp | Concrete | Persistent cache entries | |
| 60 | +| .aggregation.cache.entry`` | | with TTL | |
| 61 | ++----------------------------+----------+----------------------------+ |
| 62 | +| ``spp.ag | Abstract | Strategy-based scope | |
| 63 | +| gregation.scope.resolver`` | | resolution service | |
| 64 | ++----------------------------+----------+----------------------------+ |
| 65 | +| ``spp.aggregation.cache`` | Abstract | Cache service with TTL and | |
| 66 | +| | | cleanup | |
| 67 | ++----------------------------+----------+----------------------------+ |
| 68 | +| ``spp.aggreg | Abstract | Statistic computation | |
| 69 | +| ation.statistic.registry`` | | registry (builtins + CEL) | |
| 70 | ++----------------------------+----------+----------------------------+ |
| 71 | +| ` | Abstract | Main aggregation entry | |
| 72 | +| `spp.aggregation.service`` | | point | |
| 73 | ++----------------------------+----------+----------------------------+ |
| 74 | + |
| 75 | +Configuration |
| 76 | +~~~~~~~~~~~~~ |
| 77 | + |
| 78 | +- Aggregation scopes: **Settings > Aggregation > Aggregation Scopes** |
| 79 | +- Access rules: **Settings > Aggregation > Access Rules** |
| 80 | +- Cache cleanup runs daily via scheduled action |
| 81 | + |
| 82 | +Security |
| 83 | +~~~~~~~~ |
| 84 | + |
| 85 | ++----------------------------------+----------------------------------+ |
| 86 | +| Group | Access | |
| 87 | ++==================================+==================================+ |
| 88 | +| ``spp_aggr | Read-only access to scopes and | |
| 89 | +| egation.group_aggregation_read`` | cache | |
| 90 | ++----------------------------------+----------------------------------+ |
| 91 | +| ``spp_aggre | Read/write scopes and access | |
| 92 | +| gation.group_aggregation_write`` | rules | |
| 93 | ++----------------------------------+----------------------------------+ |
| 94 | +| ``spp_aggreg | Implied by write group | |
| 95 | +| ation.group_aggregation_viewer`` | | |
| 96 | ++----------------------------------+----------------------------------+ |
| 97 | +| ``spp_aggrega | Implied by viewer group | |
| 98 | +| tion.group_aggregation_officer`` | | |
| 99 | ++----------------------------------+----------------------------------+ |
| 100 | +| ``spp_aggrega | Full access, implied by admin | |
| 101 | +| tion.group_aggregation_manager`` | | |
| 102 | ++----------------------------------+----------------------------------+ |
| 103 | + |
| 104 | +Dependencies |
| 105 | +~~~~~~~~~~~~ |
| 106 | + |
| 107 | +``base``, ``spp_cel_domain``, ``spp_area``, ``spp_registry``, |
| 108 | +``spp_security``, ``spp_metrics_services`` |
| 109 | + |
| 110 | +**Table of contents** |
| 111 | + |
| 112 | +.. contents:: |
| 113 | + :local: |
| 114 | + |
| 115 | +Bug Tracker |
| 116 | +=========== |
| 117 | + |
| 118 | +Bugs are tracked on `GitHub Issues <https://github.com/OpenSPP/OpenSPP2/issues>`_. |
| 119 | +In case of trouble, please check there if your issue has already been reported. |
| 120 | +If you spotted it first, help us to smash it by providing a detailed and welcomed |
| 121 | +`feedback <https://github.com/OpenSPP/OpenSPP2/issues/new?body=module:%20spp_aggregation%0Aversion:%2019.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_. |
| 122 | + |
| 123 | +Do not contact contributors directly about support or help with technical issues. |
| 124 | + |
| 125 | +Credits |
| 126 | +======= |
| 127 | + |
| 128 | +Authors |
| 129 | +------- |
| 130 | + |
| 131 | +* OpenSPP.org |
| 132 | + |
| 133 | +Maintainers |
| 134 | +----------- |
| 135 | + |
| 136 | +.. |maintainer-jeremi| image:: https://github.com/jeremi.png?size=40px |
| 137 | + :target: https://github.com/jeremi |
| 138 | + :alt: jeremi |
| 139 | + |
| 140 | +Current maintainer: |
| 141 | + |
| 142 | +|maintainer-jeremi| |
| 143 | + |
| 144 | +This module is part of the `OpenSPP/OpenSPP2 <https://github.com/OpenSPP/OpenSPP2/tree/19.0/spp_aggregation>`_ project on GitHub. |
| 145 | + |
| 146 | +You are welcome to contribute. |
0 commit comments