Commit Graph
100 Commits
Author SHA1 Message Date
forehalo f38b8fef4d feat(server): handle account deleting properly (#12399)
<!-- This is an auto-generated comment: release notes by coderabbit.ai -->
## Summary by CodeRabbit

- **New Features**
  - Users are now prevented from deleting their account if they own one or more team workspaces. A clear error message instructs users to transfer ownership or delete those workspaces first.
  - Disabled (banned) users are explicitly prevented from signing in or re-registering.
  - Added new error messages and translations to improve clarity around account deletion restrictions.

- **Bug Fixes**
  - Disabled users are now explicitly handled to prevent sign-in attempts.

- **Tests**
  - Introduced comprehensive end-to-end tests covering account deletion, banning, and re-registration scenarios.

- **Chores**
  - Improved event handling for user deletion and subscription cancellation.
  - Updated localization resources with new error messages.
  - Renamed payment event handler class for clarity.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-05-23 03:57:29 +00:00
forehalo 42d527251a fix(server): avoid job fail if mail is not configured (#12306)
<!-- This is an auto-generated comment: release notes by coderabbit.ai -->
## Summary by CodeRabbit

- **New Features**
  - Improved email notification handling to prevent errors from interrupting other processes when sending emails is not possible.
- **Refactor**
  - Updated internal email sending logic across notifications and workspace features for more robust operation.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-05-20 02:49:49 +00:00
forehalo a2354f69a3 chore(core): switch position of collection and tag section in sidebar (#12327)
close AF-2551

<!-- This is an auto-generated comment: release notes by coderabbit.ai -->

## Summary by CodeRabbit

- **Style**
  - Updated the sidebar layout by reordering the Collections and Tags panels for improved navigation experience.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-05-19 09:45:37 +00:00
forehalo fa5110e76f fix(server): seat not allocated when new user invited to licensed workspace (#12322)
<!-- This is an auto-generated comment: release notes by coderabbit.ai -->
## Summary by CodeRabbit

- **Bug Fixes**
  - Improved the accuracy of workspace member overcapacity calculation.
  - Corrected seat allocation handling for one-time license variants, ensuring proper event emission and bypassing unnecessary updates.

- **Refactor**
  - Streamlined internal logic by removing an obsolete method related to seat count checks.

- **Tests**
  - Removed a workspace member list pagination test to streamline end-to-end testing.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-05-19 09:30:38 +00:00
forehalo d5e2fee317 chore(server): switch to prometheus (#12352)
<!-- This is an auto-generated comment: release notes by coderabbit.ai -->

## Summary by CodeRabbit

- **New Features**
  - Added platform-specific monitoring integration for Google Cloud Platform (GCP) in multiple services, enabling automated pod monitoring for deployments on GCP.

- **Chores**
  - Removed an unused dependency related to Google Cloud monitoring from the backend server package.

- **Refactor**
  - Updated internal monitoring implementation by removing a previously used metric reader method for GCP integration.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-05-19 05:06:42 +00:00
forehalo 93e01b4442 feat(server): support installable license (#12181)
<!-- This is an auto-generated comment: release notes by coderabbit.ai -->
## Summary by CodeRabbit

- **New Features**
  - Added support for installing self-hosted team licenses via encrypted license files.
  - Introduced a new "Onetime" license variant for self-hosted environments.
  - Added a GraphQL mutation to upload and install license files.
  - License details now display the license variant.

- **Bug Fixes**
  - Improved error messages for license activation and expiration, including dynamic reasons.

- **Localization**
  - Updated and improved license-related error messages for better clarity.

- **Tests**
  - Added comprehensive end-to-end tests for license installation scenarios.

- **Chores**
  - Enhanced environment variable handling and public key management for license verification.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-05-09 04:16:05 +00:00
forehalo 0ffa6fbe89 chore(server): hoist deps (#12145)
<!-- This is an auto-generated comment: release notes by coderabbit.ai -->
## Summary by CodeRabbit

- **Chores**
  - Updated workflow to move the node_modules directory during the build process.
  - Adjusted Prisma client output directory for improved file organization.
  - Removed unused properties from backend server package configuration.

- **Refactor**
  - Simplified type annotations for improved code clarity in test utilities.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-05-06 11:36:31 +00:00
forehalo 3feea3dc6c feat(server): docs pagination (#12086)
<!-- This is an auto-generated comment: release notes by coderabbit.ai -->
## Summary by CodeRabbit

- **New Features**
  - Added paginated document listing for workspaces, allowing users to browse documents with pagination controls.
  - Enhanced document details to display creation and update timestamps, as well as information about the creator and last updater.
- **Bug Fixes**
  - Updated deprecation notice for workspace document metadata fields to guide users to the latest recommended field.
- **Tests**
  - Added new tests to verify document info retrieval and pagination functionality.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-04-30 10:39:00 +00:00
forehalo f1605e246b feat(server): support query overcapacity member count of workspace (#12050)
<!-- This is an auto-generated comment: release notes by coderabbit.ai -->
## Summary by CodeRabbit

- **New Features**
  - Workspace quota information now includes a new metric: the count of members exceeding seat capacity ("overcapacityMemberCount"), available in both numeric and human-readable formats.
  - The workspace quota display and related queries have been updated to show this new overcapacity member count alongside existing quota metrics.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-04-30 09:47:50 +00:00
liuyi 2e1bed061e feat(server): delay subscription after invitation accepted or approved (#11992) 2025-04-30 14:27:47 +08:00
liuyi 0665d20d67 fix(nbstore): wrong order of socketio transports (#12077) 2025-04-30 03:05:40 +00:00
forehalo 4662ee8da7 chore: add crossorigin to resource tags (#12031)
<!-- This is an auto-generated comment: release notes by coderabbit.ai -->
## Summary by CodeRabbit

- **New Features**
  - Added the crossorigin attribute to all CSS and JavaScript tags in generated HTML, improving compatibility for cross-origin resource loading.

- **Tests**
  - Updated tests to verify the presence of the crossorigin attribute in script tags.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-04-28 12:25:13 +00:00
liuyi de01692414 test(server): do not use specific date time in tests (#12004) 2025-04-26 15:08:38 +00:00
forehalo 0abe65653b chore(server): sort data migrations (#11979)
<!-- This is an auto-generated comment: release notes by coderabbit.ai -->

## Summary by CodeRabbit

- **Bug Fixes**
  - Improved reliability of migration processing by ensuring migrations are now executed in a defined sequence based on numeric order extracted from their names. Errors will be shown if migration names do not include a valid numeric order suffix.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-04-25 03:51:18 +00:00
forehalo f0e2361e81 feat(server): support importing users with password (#11978)
<!-- This is an auto-generated comment: release notes by coderabbit.ai -->
## Summary by CodeRabbit

- **New Features**
  - Added support for an optional password field when creating a new user via the user creation form or API.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-04-25 03:38:34 +00:00
forehalo f4ffdb9995 build: allow node package depends on workspace packages (#11963)
<!-- This is an auto-generated comment: release notes by coderabbit.ai -->
## Summary by CodeRabbit

- **New Features**
  - Added a unified CLI entry point for server operations and introduced a new CLI executable alias.
  - Centralized and simplified server startup, allowing selection between CLI and server modes.
  - Added static migration module aggregation for easier migration management.

- **Bug Fixes**
  - Improved platform-specific native module loading for better compatibility and reliability.

- **Refactor**
  - Streamlined server build, startup, and artifact management processes.
  - Reorganized and simplified workflow and configuration files for backend services.
  - Transitioned export styles and import mechanisms for native modules to enhance maintainability.

- **Chores**
  - Removed unused dependencies and configuration files.
  - Updated test cases to reflect refined server flavor logic.
  - Adjusted package and build configurations for consistency and clarity.

- **Revert**
  - Removed legacy scripts and loaders no longer needed after refactor.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-04-24 10:36:52 +00:00
forehalo 4ffa37d1c3 chore: proxy image preview in frontend (#11957)
<!-- This is an auto-generated comment: release notes by coderabbit.ai -->
## Summary by CodeRabbit

- **New Features**
	- Images and icons in bookmark cards are now loaded through an image proxy for improved reliability and consistency.
	- Embed blocks for GitHub, Loom, and YouTube now display banner and creator images via an image proxy service for enhanced image loading.

- **Refactor**
	- Simplified backend URL handling and proxy logic for images, resulting in more efficient processing and reduced complexity.
	- Consolidated image proxy middleware and services into a shared adapter module for streamlined imports and improved maintainability.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-04-24 10:23:25 +00:00
forehalo 45df4568a4 feat(admin): bump react-router and adapt new routes package (#11887)
<!-- This is an auto-generated comment: release notes by coderabbit.ai -->
## Summary by CodeRabbit

- **New Features**
  - Added new admin routes: "auth", "setup", and "notFound" for improved navigation and access within the admin interface.
  - Introduced a utility for simplified and flexible lazy loading of React components with fallback support.

- **Improvements**
  - Updated routing structure in the admin frontend for clearer route management and enhanced Sentry integration.
  - Centralized route definitions for easier maintenance and consistency.
  - Upgraded dependencies to support the latest React Router and React versions.
  - Enhanced asynchronous handling in setup form navigation.

- **Chores**
  - Updated project references and workspace dependencies for better package management.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-04-24 09:17:59 +00:00
forehalo c831a2ab2f chore(server): ignore unknown config module (#11926) 2025-04-23 15:07:47 +00:00
liuyi 5d9a3aac5b Revert "build: allow node package depends on workspace packages (#11892)"
This reverts commit c00671dd84.
2025-04-23 19:24:51 +08:00
forehalo c00671dd84 build: allow node package depends on workspace packages (#11892) 2025-04-23 10:04:59 +00:00
forehalo 64997d4a0e feat(infra): route package (#10353) 2025-04-23 09:49:11 +00:00
forehalo f918573ba8 fix(server): config defaults (#11879) 2025-04-22 04:26:28 +00:00
forehalo 8a013af12f build: update default container name to avoid conflict (#11782) 2025-04-18 01:37:42 +00:00
forehalo 5e0d1fae98 chore(server): allow preflight workspace blob url (#11783) 2025-04-18 01:23:14 +00:00
liuyi bfecd1856b chore(core): wrong worker url prefix (#11769) 2025-04-17 18:52:55 +08:00
forehalo 18fae0f1aa fix: host app with subpath (#11739)
closes #11719
2025-04-17 01:29:48 +00:00
forehalo bfb94acc42 fix(server): subscription delete race condition (#11729) 2025-04-16 08:18:29 +00:00
forehalo 681c61a300 chore(admin): allow config avatar public path (#11689)
close #11677
2025-04-15 12:54:55 +00:00
forehalo 7257f1b55b chore(server): remove enable flag in mail config (#11680)
close #11625
2025-04-15 09:18:10 +00:00
forehalo e73d68cac4 chore(server): fix spotify link preview (#11638)
close AF-2499
2025-04-11 09:36:20 +00:00
forehalo 2f5647ac77 fix(editor): use img tag for link preview icon and banner (#11637)
close AF-2377
2025-04-11 08:48:04 +00:00
liuyi f0fb1447a4 chore(core): update license price link (#11616) 2025-04-10 19:54:48 +08:00
liuyiandrenovate e79e4c9e9b refactor(core): add version in worker url (#11614)
Co-authored-by: renovate <29139614+renovate@users.noreply.github.com>
2025-04-10 11:12:49 +00:00
liuyi b8e93ed714 chore(server): change default deployment type in dev mode (#11593) 2025-04-10 08:47:36 +00:00
liuyi d1bd809608 chore(core): add pricing link in license panel (#11598) 2025-04-10 08:18:26 +00:00
liuyi bde9abf664 chore: fix github codesapce init (#11590) 2025-04-10 07:33:02 +00:00
forehalo 8e1cbc4c5b test(server): do not consume job in test (#11592) 2025-04-10 07:02:07 +00:00
liuyi e376aa57c5 chore: bring treeshake back (#11577) 2025-04-10 14:12:36 +08:00
forehalo cdbcb8a42a chore: adjust webpack output (#11573)
- automatically split i18n resources into i18n-langs.{lang} naming
- force worker resources to be bundled in one file
2025-04-10 01:48:28 +00:00
forehalo 4e56a8447b fix(core): missing i18n and button margin (#11568)
close AF-2486
2025-04-09 13:40:01 +00:00
liuyi 1b858e1e6c chore: wrong $shcmea field in config example (#11526) 2025-04-08 17:46:35 +08:00
liuyi ebdeaf3783 chore(core): reorg polyfill (#11528) 2025-04-08 14:59:54 +08:00
liuyi 646182ea2a fix(server): duplicate registered otel providers (#11513) 2025-04-08 10:25:36 +08:00
forehalo 40f218c898 chore: set base version to 0.21 2025-04-07 16:10:32 +08:00
liuyi e376992ccf chore(server): default DEPLOYMENT_TYPE should be selfhosted (#11484) 2025-04-07 10:05:14 +08:00
forehalo 2533a92873 chore(server): avoid config object been modified (#11452) 2025-04-03 12:57:29 +00:00
forehalo 6939e80827 chore(server): never reuse cls id for job handler (#11449) 2025-04-03 12:26:02 +00:00
forehalo c8d22d97d5 refactor: webpack config (#11421) 2025-04-03 11:55:56 +00:00
forehalo 1386a66579 chore(server): hide not configurable module (#11406) 2025-04-02 12:44:20 +00:00
forehalo 35bea20b80 chore(server): adjust job config (#11405) 2025-04-02 09:48:46 +00:00
forehalo 85d176ce6f chore(server): customize config merge logic (#11400) 2025-04-02 09:48:45 +00:00
forehalo b21a0b4520 chore: release with config.schema.json (#11391) 2025-04-02 09:48:45 +00:00
forehalo 6833c2a2dd chore: missing env 2025-04-02 11:03:10 +08:00
forehalo 5a955d9f70 chore: fix beta deployment 2025-04-02 10:47:01 +08:00
forehalo dad858014f feat(admin): adapt new config system (#11360)
feat(server): add test mail api

feat(admin): adapt new config system
2025-04-01 15:00:10 +00:00
forehalo eb219b2c48 chore(server): watch storages config updates (#11367) 2025-04-01 12:52:45 +00:00
forehalo 6276732efc chore(server): reschedule doc merging jobs (#11318) 2025-04-01 10:57:54 +00:00
forehalo 94d5a42355 chore(core): allow quick export (#11295) 2025-03-31 06:58:17 +00:00
forehalo 57ec22ec2e fix(core): do not pass flavor in space id (#11285) 2025-03-31 04:47:00 +00:00
forehalo 1b93d3d8d2 chore(server): bump nestjs and express (#11259) 2025-03-28 14:00:19 +00:00
forehalo 64c7fb1d66 chore(server): validate function not actually used (#11263) 2025-03-28 12:51:19 +00:00
forehalo 8c582122a8 chore: fix copilot cron test (#11262) 2025-03-28 08:42:22 +00:00
liuyi ca301f0dab chore(server): patch config system (#11260) 2025-03-28 08:19:04 +00:00
liuyi e22f66f1cc fix(server): auto import config.json (#11255) 2025-03-28 06:12:56 +00:00
forehalo 504a74d512 chore(server): add import config script (#11242) 2025-03-27 12:32:29 +00:00
forehalo 0ea38680fa refactor(server): config system (#11081) 2025-03-27 12:32:28 +00:00
forehalo 766383cb3a chore: disable http proxy middleware log in ci (#11238) 2025-03-27 09:11:54 +00:00
forehalo ae552c97cf fix(server): raw user query (#11151) 2025-03-26 00:58:38 +00:00
forehalo 15173db62c fix(server): add missing disabled query field (#11123) 2025-03-24 08:04:48 +00:00
forehalo 03364f9d03 chore(server): allow adjust selfhost team quantity (#11022)
close CLOUD-165
2025-03-20 08:04:10 +00:00
forehalo f889886b31 refactor(server): e2e utilities (#11000) 2025-03-19 17:00:20 +00:00
forehalo 21c4a29f55 refactor(server): mail service (#10934) 2025-03-19 17:00:19 +00:00
forehalo b3a245f47a chore(server): better internal error stack (#11009) 2025-03-19 16:41:56 +00:00
forehalo dd31ef95db chore: bump otel packages in a group (#11001) 2025-03-19 14:17:02 +00:00
forehalo 33d57b455a chore(server): revert access control in sync module (#11011) 2025-03-19 12:58:56 +00:00
forehalo 8b67496951 refactor(server): saving past_due subscription in db (#10908)
close CLOUD-122
2025-03-17 10:17:14 +00:00
forehalo 9b5d12dc71 test(server): new test facilities (#10870)
close CLOUD-142
2025-03-17 10:02:12 +00:00
liuyi aa70759f44 build(server): no build seed script (#10923) 2025-03-17 17:08:55 +08:00
liuyi 0f83566504 chore(server): data mocking and seeding (#10864) 2025-03-17 14:15:34 +08:00
forehalo d936553047 chore: auto assign feature reqeusts (#10819) 2025-03-14 02:20:14 +00:00
forehalo 7100d87efe chore(core): doc role telemetry (#10822) 2025-03-13 08:15:46 +00:00
forehalo 3db3db0bbc chore(server): revert doc write restriction (#10807) 2025-03-13 05:51:19 +00:00
forehalo c1c750d782 fix(server): failed to resolve user importing result (#10804) 2025-03-13 05:02:58 +00:00
forehalo d8ebf7b3c5 fix(core): wrong top margin of local workspace hint in setting panel (#10782)
close AF-2243
2025-03-12 10:16:47 +00:00
forehalo 0df8e31698 chore(server): update gql schema (#10775) 2025-03-12 04:43:56 +00:00
forehalo 1b62b4b625 feat(server): support making doc private in workspace (#10744) 2025-03-12 03:18:24 +00:00
forehalo 5f14c4248f feat(server): allow check available version to upgrade (#10767)
close CLOUD-159
2025-03-12 02:52:19 +00:00
forehalo 50da76d4af feat(server): import users (#10762)
close CLOUD-167
2025-03-12 02:52:19 +00:00
forehalo ea72599bde feat(server): ban account (#10761)
close CLOUD-158
2025-03-12 02:52:18 +00:00
forehalo 3a3cb8112c chore: update issue templates (#10688) 2025-03-08 06:12:01 +00:00
forehalo e02fb4fa94 refactor(core): standardize frontend error handling (#10667) 2025-03-06 13:10:18 +00:00
forehalo 56b842f2e1 fix(core): runtime control of telemetry (#10663) 2025-03-06 09:56:13 +00:00
liuyi 7e61a0b2fc refactor(graphql): codegen (#10626) 2025-03-06 12:06:19 +08:00
liuyi 61162c59fc refactor(server): permission (#10449) 2025-03-05 15:57:00 +08:00
liuyi 889625cdaa fix(server): reschedule busy doc merging (#10583) 2025-03-03 18:51:09 +08:00
liuyi abad289783 fix(server): limit max batch pulled doc updates (#10578) 2025-03-03 09:19:17 +00:00
forehalo d50860eee2 fix(server): use updowncounter by default (#10482) 2025-02-27 10:15:13 +00:00
liuyi b3821ad619 fix(server): avoid global rejection when event handler errors (#10467) 2025-02-27 06:25:46 +00:00
liuyi e5e5c0a8ba perf(core): only full sync before exporting (#10408) 2025-02-25 04:41:56 +00:00