Skip to content

enh/snowflake ids - #9186

Open
max-nextcloud wants to merge 2 commits into
refactor/introduce-icontextfrom
enh/snowflake-ids
Open

enh/snowflake ids#9186
max-nextcloud wants to merge 2 commits into
refactor/introduce-icontextfrom
enh/snowflake-ids

Conversation

@max-nextcloud

@max-nextcloud max-nextcloud commented Sep 7, 2026

Copy link
Copy Markdown
Collaborator

enh(document): use snowflake ids

Do not rely on autoincrement ids,
which require shuffling tables around in the migration
as some databases cannot change columns to autoincrement.

$document->id is now a string,
which conflicts with the definition in the Entity class.
Mute the psalm warning about this for now.

Proper solution will be to migrate to the new ORM.
https://carlschwan.eu/2026/08/18/modern-stable-apis-for-your-nextcloud-application/

Signed-off-by: Max <max@nextcloud.com>
@max-nextcloud
max-nextcloud force-pushed the enh/snowflake-ids branch 2 times, most recently from 1569518 to c83be29 Compare September 8, 2026 07:03
@max-nextcloud
max-nextcloud requested a review from blizzz September 8, 2026 07:03
@max-nextcloud
max-nextcloud force-pushed the enh/snowflake-ids branch 5 times, most recently from 0723ece to 666af57 Compare September 8, 2026 11:49
@max-nextcloud
max-nextcloud marked this pull request as ready for review September 8, 2026 12:26
Do not rely on autoincrement ids,
which require shuffling tables around in the migration
as some databases cannot change columns to autoincrement.

`$document->id` is now a string,
which conflicts with the definition in the Entity class.
Mute the psalm warning about this for now.

Proper solution will be to migrate to the new ORM.
https://carlschwan.eu/2026/08/18/modern-stable-apis-for-your-nextcloud-application/

Signed-off-by: Max <max@nextcloud.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant