Add boilerplate for the Fedora Badges
Signed-off-by: Akashdeep Dhar <akashdeep.dhar@gmail.com>
This commit is contained in:
parent
40fea8c307
commit
062b64273c
8 changed files with 250 additions and 117 deletions
39
docs/badges/current_implementation_databases_and_api.rst
Normal file
39
docs/badges/current_implementation_databases_and_api.rst
Normal file
|
@ -0,0 +1,39 @@
|
|||
.. _current_implementation_databases_and_api:
|
||||
|
||||
The database and the API
|
||||
====
|
||||
|
||||
The database for Fedora Badges stores the badge definitions. and what users
|
||||
have been granted these badges. These is also a Python API for interacting
|
||||
with the database.
|
||||
|
||||
* Source repository: `https://github.com/fedora-infra/tahrir-api <https://github.com/fedora-infra/tahrir-api>`_
|
||||
* Production location: db01.iad2.fedoraproject.org/tahrir
|
||||
|
||||
Technology used
|
||||
----
|
||||
|
||||
The database and API is written in Python 2 and uses SQLAlchemy for database
|
||||
management. In the production deployment, a Postgres database is used.
|
||||
|
||||
Basic table information
|
||||
----
|
||||
|
||||
The badges database appears to have been implemented with extra features for
|
||||
Open Badges (or Badgr) compatibility, but a lot of these tables are not really
|
||||
in use in the production deployment of Fedora Badges.
|
||||
|
||||
+----------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| DB Table | Information |
|
||||
+================+==========================================================================================================================================================================================================+
|
||||
| Person | A table for a user. Contains basic information about the user |
|
||||
| Badge | A table of all the badge definitions. Note that the badge image is not stored in the DB, it is just a link to an image on the backend server. Also, the criteria for a badge is only a URL to criteria. |
|
||||
| Assertion | A table that maps users to badges allowing them to arbitrarily grant them. |
|
||||
| Authorization | A table that maps users to badges allowing them to arbitrarily grant them. |
|
||||
| Issuer | A table of the issuers that issue badges. In Fedora badges, there is only one issuer -- Fedora, so not really used. |
|
||||
| Series | A table to do with having a series of badges -- can't find much documentation about it, but on production badges, it is empty, so not in use. |
|
||||
| Milestones | Another table to do with having a series of badges -- can't find much documentation about it, but on production badges, it is empty, so not in use. |
|
||||
| Team | Yet another table to do with having a series of badges -- can't find much documentation about it, but on production badges, it only has one entry "Infrastructure". |
|
||||
+----------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue