From ab53db3bdace96d8b482c3cd745a98d12d2a576d Mon Sep 17 00:00:00 2001 From: prajwal Date: Tue, 4 Aug 2026 12:17:36 +0530 Subject: [PATCH 1/3] prod-release notes updated --- release-notes/prod/release-1.0.0.md | 36 +++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 release-notes/prod/release-1.0.0.md diff --git a/release-notes/prod/release-1.0.0.md b/release-notes/prod/release-1.0.0.md new file mode 100644 index 0000000..022307a --- /dev/null +++ b/release-notes/prod/release-1.0.0.md @@ -0,0 +1,36 @@ +# 🚀 Commons-Backend [Release 1.0.0] + +## ✨ Features & Improvements + +- **Google Drive Integration for Decentralised Media Uploads** + Introduced a decentralised upload approach where organizations connect their own Google Drive via OAuth 2.0 (with PKCE) and import entire Drive folders as knowledge-base media, instead of uploading files manually one by one. + +- **Drive Folder Import with Validation & Safety Checks** + Folder imports validate the Google Drive URL, verify the folder is publicly shared ("Anyone with the link") and non-empty, and block duplicate imports of the same folder within an organization with a clear conflict message. + +- **Repository Tracking & Listing** + Every imported Drive folder is tracked as a Repository per organization with sync status, timestamps, error messages, and resource counts, and can be viewed via a new paginated, org-scoped repository listing API. + +--- + +## 🔄 Migration + +- **0083_repository** + Creates the new `repositories` table to store external repository details (name, provider type, root link, sync status/tracking fields, resource counts) mapped to an organization. + +- **0084_mediaorgmapping** + Creates the `MediaOrgMapping` table to map media entries to organizations (media ↔ org_id). + +- **0085_alter_mediaorgmapping_org_id** + Changes the `org_id` column on `MediaOrgMapping` from BigInteger to Text to support non-numeric org identifiers. + +- **0086_repository_org_root_link_unique** + Adds a unique constraint on `(org_id, root_link)` in the `repositories` table to prevent duplicate repository links per organization. + +- **0087_add_source_provider_to_media** + Adds a nullable `source_provider` field to the `Media` model to record where the media originated (Google Drive, OneDrive, or Local). + +--- + +👨‍💻 **Service:** Commons Backend +🏷️ **Version:** 1.0.0 \ No newline at end of file From b36a030ddc500ab5c345f2774453b6ebfc321f92 Mon Sep 17 00:00:00 2001 From: prajwal Date: Tue, 4 Aug 2026 13:52:42 +0530 Subject: [PATCH 2/3] updated prod release-notes --- release-notes/prod/release-1.0.0.md | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/release-notes/prod/release-1.0.0.md b/release-notes/prod/release-1.0.0.md index 022307a..b80b6c6 100644 --- a/release-notes/prod/release-1.0.0.md +++ b/release-notes/prod/release-1.0.0.md @@ -32,5 +32,19 @@ --- +## ⚙️ New Environment Variables + +The following environment variables were added to configure Redis and the Celery workers used by the asynchronous Google Drive import pipeline: + +| Variable | Default | Description | +|---|---|---| +| `REDIS_HOST` | `127.0.0.1` | Hostname of the Redis server used as the Celery broker and result backend. | +| `REDIS_PORT` | `6379` | Port of the Redis server. | +| `REDIS_USE_SSL` | `false` | Set to `true` to connect to Redis over SSL (`rediss://`). | +| `REDIS_CELERY_DB` | `2` | Redis database number used for the Celery broker and result backend. | +| `CELERY_TASK_DEFAULT_QUEUE` | `sg_commons_queue` | Default queue name that Celery tasks are published to and workers consume from. | + +--- + 👨‍💻 **Service:** Commons Backend 🏷️ **Version:** 1.0.0 \ No newline at end of file From b53b234be347d10ecdc80d8818c4a09a8161154d Mon Sep 17 00:00:00 2001 From: prajwal Date: Tue, 4 Aug 2026 14:09:57 +0530 Subject: [PATCH 3/3] updated prod release-notes --- release-notes/prod/release-1.0.0.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/release-notes/prod/release-1.0.0.md b/release-notes/prod/release-1.0.0.md index b80b6c6..4cb3949 100644 --- a/release-notes/prod/release-1.0.0.md +++ b/release-notes/prod/release-1.0.0.md @@ -34,7 +34,7 @@ ## ⚙️ New Environment Variables -The following environment variables were added to configure Redis and the Celery workers used by the asynchronous Google Drive import pipeline: +The following environment variables were added to configure the Google Drive OAuth integration, and Redis and the Celery workers used by the asynchronous import pipeline: | Variable | Default | Description | |---|---|---| @@ -43,7 +43,7 @@ The following environment variables were added to configure Redis and the Celery | `REDIS_USE_SSL` | `false` | Set to `true` to connect to Redis over SSL (`rediss://`). | | `REDIS_CELERY_DB` | `2` | Redis database number used for the Celery broker and result backend. | | `CELERY_TASK_DEFAULT_QUEUE` | `sg_commons_queue` | Default queue name that Celery tasks are published to and workers consume from. | - +| `GOOGLE_DRIVE_SCOPES` | `https://www.googleapis.com/auth/drive.readonly` | Google OAuth scopes requested when connecting a Google Drive account. Defaults to read-only Drive access. | --- 👨‍💻 **Service:** Commons Backend