Commit Graph

95 Commits

Author SHA1 Message Date
Chuck Driesler 86c113b29b feat(regions): move project automations (#3925)
* feat(regions): repo functions for copying project branches and commits

* chore(regions): wire up move to resolver

* chore(regions): successful basic test of project region change

* fix(regions): sabrina carpenter please please please

* fix(regions): repair multiregion test setup

* chore(regions): appease ts

* chore(multiregion): update test multiregion config

* chore(multiregion): fix test docker config and test

* chore(multiregion): use transaction

* chore(multiregion): maybe this will work

* fix(multiregion): drop subs synchronously

* chore(multiregion): desperate test logs

* chore(multiregion): somehow that worked?

* chore(multiregion): add load-bearing log statement

* chore(multiregion): move services

* fix(multiregion): test drop waits

* chore(regions): fix import

* chore(regions): make test a bit more thorough for good measure

* fix(regions): move project objects

* chore(regions): add tests for object move

* feat(regions): move project automations

* chore(regions): add tests for moving automations

* chore(regions): more tests for moving automate data

* fix(regions): speed up inserts

* fix(regions): simplify postgres usage

* chore(regions): repair build

* fix(regions): improve queries

* chore(regions): again
2025-02-18 15:48:00 +00:00
Chuck Driesler 3f51031a45 fix(sso): lowercase emails for sso (#4017) 2025-02-18 13:28:21 +00:00
Chuck Driesler a443dd5af4 fix(sso): check emails correctly (#4009) 2025-02-17 20:51:20 +00:00
Chuck Driesler d3b8cdba8f fix(sso): azure upn fallback (#3982)
* fix(sso): azure upn fallback

* fix(sso): more explicit types

* fix(sso): update redirects

* fix(sso): safer property check
2025-02-17 16:05:06 +00:00
Chuck Driesler 60e74b34e1 feat(regions): move project objects (#3924)
* feat(regions): repo functions for copying project branches and commits

* chore(regions): wire up move to resolver

* chore(regions): successful basic test of project region change

* fix(regions): sabrina carpenter please please please

* fix(regions): repair multiregion test setup

* chore(regions): appease ts

* chore(multiregion): update test multiregion config

* chore(multiregion): fix test docker config and test

* chore(multiregion): use transaction

* chore(multiregion): maybe this will work

* fix(multiregion): drop subs synchronously

* chore(multiregion): desperate test logs

* chore(multiregion): somehow that worked?

* chore(multiregion): add load-bearing log statement

* chore(multiregion): move services

* fix(multiregion): test drop waits

* chore(regions): fix import

* chore(regions): make test a bit more thorough for good measure

* fix(regions): move project objects

* chore(regions): add tests for object move

* fix(regions): speed up inserts

* fix(regions): simplify postgres usage

* chore(regions): 100 => 10
2025-02-17 10:51:12 +00:00
Gergő Jedlicska bf80347abf gergo/web 2664 workspace backend powered metrics (#3985)
* feat(workspaces): delete workspace emit event

* feat(workspaces): move workspace group metrics to the backend

* Removed FE mixpanel group update

* Remove fragment

* test(gatekeeper): add unittest to new gatekeeper service

---------

Co-authored-by: Mike Tasset <mike.tasset@gmail.com>
2025-02-17 09:50:16 +01:00
Chuck Driesler c382064585 feat(regions): move project branches and commits (#3843)
* feat(regions): repo functions for copying project branches and commits

* chore(regions): wire up move to resolver

* chore(regions): successful basic test of project region change

* fix(regions): sabrina carpenter please please please

* fix(regions): repair multiregion test setup

* chore(regions): appease ts

* chore(multiregion): update test multiregion config

* chore(multiregion): fix test docker config and test

* chore(multiregion): use transaction

* chore(multiregion): maybe this will work

* fix(multiregion): drop subs synchronously

* chore(multiregion): desperate test logs

* chore(multiregion): somehow that worked?

* chore(multiregion): add load-bearing log statement

* chore(multiregion): move services

* fix(multiregion): test drop waits

* chore(regions): fix import

* chore(regions): make test a bit more thorough for good measure

* fix(regions): speed up inserts

* fix(regions): ignore workspace conflict on move
2025-02-13 14:39:23 +00:00
Chuck Driesler 35b59ca4f2 chore(workspaces): drop defaultLogoIndex (#3898) 2025-01-28 08:56:13 +01:00
Gergő Jedlicska 188c333921 fix(workspaces): non region enabled workspace project creation (#3847)
* fix(workspaces): non region enabled workspace project creation

* fix(projects): remove duplicate getProject repo function

This was the cause of the default project region switch bug, we had two
almost identical implementations...
2025-01-27 17:45:55 +01:00
Mike 3b901de000 Fix: Change Mange Members link to link to settings (#3891) 2025-01-27 09:44:12 +01:00
Mike e798fc4e8a Feat: Request to join workspace (#3871) 2025-01-24 14:05:53 +01:00
Alessandro Magionami 17c8ada369 chore(workspaces): use logic function to check workspace is joinable 2025-01-22 12:08:36 +01:00
Alessandro Magionami abf0ccf835 chore(workspaces): check user email verified and add user to workspace 2025-01-22 09:57:38 +01:00
Alessandro Magionami adaad0d027 chore(workspaces): add user to workspace on approved request 2025-01-21 17:18:26 +01:00
Alessandro Magionami 9f74693259 chore(workspaces): remove double dot in email text 2025-01-16 16:59:53 +01:00
Alessandro Magionami 8cd060f869 chore(workspaces): use commandFactory in deny workspace join request 2025-01-16 16:55:22 +01:00
Alessandro Magionami 6d0f08b7b5 feat(workspaces): approve join request (#3833)
* feat(workspaces): approve join request

* chore(workspaces): add missing dep to resolver call

* chore(workspaces): use commandFactory
2025-01-16 16:46:59 +01:00
Alessandro Magionami 37ede3b1b2 Alessandro/web 2360 request to join workspace (#3799)
* feat(workspaces): request to join workspace mutation

* feat(workspaces): random email in test

* feat(workspaces): update email

* feat(workspaces): code review changes

* chore(workspaces): fix tests
2025-01-14 12:49:21 +01:00
Alessandro Magionami c9fe57fa74 Merge branch 'main' of github.com:specklesystems/speckle-server into alessandro/web-2359-dismiss-joinable-workspace 2025-01-13 19:09:48 +01:00
Gergő Jedlicska db8de114d3 feat(server): new projects are placed in a configurable region (#3801)
* feat(server): log subscription started messages with info

* feat(server): create projects in a default region

* feat(server): allow project default region config

* feat(server): load project region from multi region config
2025-01-13 18:38:44 +01:00
Kristaps Fabians Geikins aee14edc5b chore(server): getting rid of module-scoped event emitters - batch #1 (#3766)
* got rid of models emitter + added tests

* got rid of projects emitter + added tests

* replaced user event bus

* test migrate
2025-01-13 11:39:46 +02:00
Alessandro Magionami ee5797af28 feat(workspaces): fix dismiss and tests 2025-01-10 18:21:14 +01:00
Alessandro Magionami c32026b6d6 feat(workspaces): dismiss workspace mutation 2025-01-09 11:21:46 +01:00
Gergő Jedlicska 229a19c981 gergo/workspaceAdmin (#3677)
* feat(workspaces): add unified paginated items service

* feat(workspaces): admin update workspace plan
2024-12-11 18:54:24 +01:00
Kristaps Fabians Geikins 8d0cbad8b6 feat(server): multi region blob support (#3653)
Co-authored-by: Iain Sproat <68657+iainsproat@users.noreply.github.com>
2024-12-10 09:05:18 +00:00
Chuck Driesler b4aa0f7608 fix(sso): disable slug edit if sso enabled (#3621)
* fix(sso): disable slug edit if sso enabled

* fix(sso): guard on backend

* chore(sso): more test fixes
2024-12-03 18:05:04 +00:00
Chuck Driesler 101a0b2d54 fix(workspaces): no default discovery (#3622)
* fix(workspaces): do not enable discoverability by default

* chore(workspaces): fix test

* chore(workspaces): more tests fix
2024-12-03 16:01:05 +00:00
Chuck Driesler b41b08d688 fix(sso): oidc state parameter (#3598)
* feat(sso): use state parameter

* chore(sso): fix tests

* fix(sso): entraid moment

* chore(sso): use specific errors
2024-12-02 18:16:28 +00:00
Kristaps Fabians Geikins 51579b76ef fix(server): various fixes related to subs + further improved utils + way quicker tests (#3573)
* fixed test util throwing + added new tests

* more tests

* more tests

* various model tests

* version tests

* removed shitty old tests

* lint fix

* workspaceProjectsUpdated test

* workspace updated on invite

* workspace subs support team changes

* tests fix

* test fix hopefully?
2024-12-02 13:30:24 +02:00
Chuck Driesler 9ad3fb8d0e fix(sso): continue with sso from any verified email (#3577)
* fix(sso): continue with sso from any verified email

* chore(sso): fix/add tests
2024-11-29 06:33:00 +01:00
Kristaps Fabians Geikins 1800dbbdbd feat(server): improved subscription testing DX + tests for common subs + new subs (#3554)
* userProjectsUpdated.added test

* multi region support

* userStreamAdded

* commit subs tested

* fix for proj workspace assignment

* undo commitHelper main changes

* disable all ffs mode

* createTestWorkspace support when workspaces arent enabled

* project create fix

* workspace projects updated subscription

* WIP new workspace sub

* updated workspaceCreated

* updated workspaceUpdated

* BE for workspace updated sub

* workspace updated sub

* ts err fix
2024-11-27 15:41:04 +02:00
Gergő Jedlicska e30b8c83b9 gergo/workspacesMultiRegion (#3477)
* feat(webhook-service): learn to speak multi region

* feat(fileimport-service): talk multi region to me

* feat(fileuploads, blobs): multi region

* feat(workspaces): update delet workspace with billing and regions

* fix typo

* feat(workspaces): remove old billing resolvers

* test(workspaces): fix tests

* fix(workspaces): remove unused schema
2024-11-19 15:45:03 +01:00
Chuck Driesler 22167d215f feat(sso): delete sso (#3452)
* feat(sso): delete sso

* fix(sso): simplify delete
2024-11-12 09:17:48 +00:00
Gergő Jedlicska f210d9b749 gergo/web 2109 project region based db connection selector (#3434)
* feat(projects): add project regions, default to null

* feat(multiregion): add projectRegion Db client lookup logic

* feat(multiregion): add project region repositories and caching

* feat(multiRegion): db initialization and get project db client

* feat(docker-compose): add second db for regions testing

* feat(multiRegion): initialize region with pubs and subs working

* fix(multiRegion): get region client even if it was registered in another pod

* feat(workspaces): create workspace resolver split

* feat: update server region metadata

* feat(projects): rewrite project creation

* feat(multiRegion): getRegionDb

* fix(workspaces): get projects now can retur null

* feat(multiRegion): make local multi region DB-s work

* feat: set d efault workspace region

* CR changes

* tests

* feat(multiRegion): bind region properly

* fe update

* test fixes

* feat(multiRegion): automatically create aiven extras plugin

* ci(postgres): use published postgres with aiven extras

* fix(multiRegion): roll back the aiven extras migration, there is a better way

* tests fix

* fix(billing): we do not need to add a seat, if the workspace is on a plan, but has no sub

---------

Co-authored-by: Kristaps Fabians Geikins <fabis94@live.com>
2024-11-06 17:29:08 +01:00
Chuck Driesler b195df37d6 feat(sso): active user sso information (#3432)
* feat(workspaces): add workspace sso feature flag

* feat(workspaceSso): wip validate sso

* feat(workspaces): validate and add sso provider to the workspace with user sso sessions

* feat(workspaces): validate and add sso provider to the workspace with user sso sessions

* WIP

* fix(sso): restructure to handle all branches at end of flow

* fix(sso): add and validate emails used for sso

* fix(sso): park progress

* chore(workspaces): review sso login/valdate

* fix(sso): adjust validate url

* chore(sso): auth header puzzle

* fix(sso): happy-path config

* chore(gql): gqlgen

* fix(sso): almost almost

* fix(sso): auth endpoint

* a lil more terse

* fix(sso): light at the end of the tunnel

* fix(sso): improve catch block error messages

* fix(sso): session lifespan => validUntil

* fix(sso): I think we've got it

* feat(sso): limited workspace values for public sso login

* fix(sso): use factory functions

* fix(sso): til decrypt is single-use

* fix(sso): correct usage of access codes

* fix(sso): use finalize middleware in all routes

* chore(sso): cheeky tweak

* fix(sso): move some types around

* fix(sso): stencil final shape I'm sleepy

* fix(sso): more factories more factories

* fix(sso): on to final boss of factories

* fix(sso): needs a haircut but she works

* fix(sso): init rest w function, not side-effects

* fix(sso): /authn => /sso

* chore(sso): errors

* chore(sso): test test test

* chore(sso): test all the corners

* feat(sso): list workspace sso memberships

* chore(sso): tests, expose in rest

* fix(sso): sketch active user auth

* fix(sso): expose search via gql

* fix(sso): active user session information

* chore(sso): sso session test utils

* chore(sso): test sso session repo/services

* chore(sso): gqlgen

* fix(sso): simplify gql resolver structure

* chore(sso): gqlgen

---------

Co-authored-by: Gergő Jedlicska <gergo@jedlicska.com>
Co-authored-by: Mike Tasset <mike.tasset@gmail.com>
2024-11-05 12:27:46 +00:00
Chuck Driesler e6e65a2f7d feat(sso): list sso associations by user email (#3420)
* feat(workspaces): add workspace sso feature flag

* feat(workspaceSso): wip validate sso

* feat(workspaces): validate and add sso provider to the workspace with user sso sessions

* feat(workspaces): validate and add sso provider to the workspace with user sso sessions

* WIP

* fix(sso): restructure to handle all branches at end of flow

* fix(sso): add and validate emails used for sso

* fix(sso): park progress

* chore(workspaces): review sso login/valdate

* fix(sso): adjust validate url

* chore(sso): auth header puzzle

* fix(sso): happy-path config

* chore(gql): gqlgen

* fix(sso): almost almost

* fix(sso): auth endpoint

* a lil more terse

* fix(sso): light at the end of the tunnel

* fix(sso): improve catch block error messages

* fix(sso): session lifespan => validUntil

* fix(sso): I think we've got it

* feat(sso): limited workspace values for public sso login

* fix(sso): use factory functions

* fix(sso): til decrypt is single-use

* fix(sso): correct usage of access codes

* fix(sso): use finalize middleware in all routes

* chore(sso): cheeky tweak

* fix(sso): move some types around

* fix(sso): stencil final shape I'm sleepy

* fix(sso): more factories more factories

* fix(sso): on to final boss of factories

* fix(sso): needs a haircut but she works

* fix(sso): init rest w function, not side-effects

* fix(sso): /authn => /sso

* chore(sso): errors

* chore(sso): test test test

* chore(sso): test all the corners

* feat(sso): list workspace sso memberships

* chore(sso): tests, expose in rest

* fix(sso): expose search via gql

---------

Co-authored-by: Gergő Jedlicska <gergo@jedlicska.com>
Co-authored-by: Mike Tasset <mike.tasset@gmail.com>
2024-11-01 11:27:12 +01:00
Chuck Driesler 52bb1116ed SSO (#3376)
* feat(workspaces): add workspace sso feature flag

* feat(workspaceSso): wip validate sso

* feat(workspaces): validate and add sso provider to the workspace with user sso sessions

* feat(workspaces): validate and add sso provider to the workspace with user sso sessions

* WIP

* fix(sso): restructure to handle all branches at end of flow

* fix(sso): add and validate emails used for sso

* fix(sso): park progress

* chore(workspaces): review sso login/valdate

* fix(sso): adjust validate url

* chore(sso): auth header puzzle

* fix(sso): happy-path config

* chore(gql): gqlgen

* fix(sso): almost almost

* fix(sso): auth endpoint

* a lil more terse

* fix(sso): light at the end of the tunnel

* fix(sso): improve catch block error messages

* fix(sso): session lifespan => validUntil

* fix(sso): I think we've got it

* feat(sso): limited workspace values for public sso login

* fix(sso): use factory functions

* fix(sso): til decrypt is single-use

* fix(sso): correct usage of access codes

* fix(sso): use finalize middleware in all routes

* chore(sso): cheeky tweak

* fix(sso): move some types around

* fix(sso): stencil final shape I'm sleepy

* fix(sso): more factories more factories

* fix(sso): on to final boss of factories

* fix(sso): needs a haircut but she works

* fix(sso): init rest w function, not side-effects

* fix(sso): /authn => /sso

* chore(sso): errors

* chore(sso): test test test

* chore(sso): test all the corners

---------

Co-authored-by: Gergő Jedlicska <gergo@jedlicska.com>
Co-authored-by: Mike Tasset <mike.tasset@gmail.com>
2024-10-31 13:20:53 +01:00
Chuck Driesler dc9519f141 fix(workspaces): emit slug with discoverable workspaces (#3361)
* fix(workspaces): emit slug with discoverable workspaces

* chore(workspaces): gql lint
2024-10-23 09:50:08 +01:00
Kristaps Fabians Geikins 766a189465 chore(server): core IoC #62 - deleteUserFactory 2024-10-15 14:22:06 +03:00
Kristaps Fabians Geikins 1cb27e6fdd chore(server): core IoC #51 - getUser(s)Factory 2024-10-14 17:24:11 +03:00
Kristaps Fabians Geikins 212d05d222 chore(server): core IoC #46 - getUserStreamsPageFactory 2024-10-14 15:45:42 +03:00
Chuck Driesler 9bafc388aa fix(workspaces): prohibit workspace guests from being project owners (#3244)
* fix(workspaces): prohibit workspace guests from being project owners

* Small FE fix

---------

Co-authored-by: Mike Tasset <mike.tasset@gmail.com>
2024-10-14 10:02:17 +01:00
Kristaps Fabians Geikins cd45fa7cde chore(server): core IoC 37 - legacyGetStreamsFactory 2024-10-10 11:01:50 +03:00
Kristaps Fabians Geikins ad9cb3aafd chore(server): IoC 33 - deleteStreamAndNotifyFactory 2024-10-09 12:37:57 +03:00
Kristaps Fabians Geikins 5b5dd201e2 chore(server): IoC 29 - getStream(s)Factory 2024-10-09 10:39:00 +03:00
Kristaps Fabians Geikins 7d9bb3c4ea fix: single workspace admin cant accept own invite (#3197) 2024-10-08 12:44:17 +03:00
andrewwallacespeckle ebef771c3a refactor(fe2): Update queries to use workspaceBySlug (#3177)
* Use workspaceBySlug

* workspace invite support slug

* fix workspace invite email link

* added tests

* Update workspaceInvite query to use new option

* useSlug directly in query

---------

Co-authored-by: Fabis <fabis94@live.com>
2024-10-02 13:01:38 +01:00
Gergő Jedlicska 7fbda629b7 feat(sso): early sso testing
* feat(workspaces): add workspace sso feature flag

* feat(workspaceSso): wip validate sso

* feat(workspaces): validate and add sso provider to the workspace with user sso sessions

* feat(workspaces): validate and add sso provider to the workspace with user sso sessions
2024-10-01 17:15:25 +01:00
Iain Sproat f93d9093a0 fix(errors): all error should define an appropriate status code (#3112)
* fix(errors): all error should define a status code (default is 500)
- rename NoInviteFoundError to InviteNotFoundError to match xNotFoundError pattern

* remove unused errors
2024-09-25 13:08:13 +02:00
Gergő Jedlicska 00c01db923 feat(workspaces): add workspace slug support (#2982)
* feat(workspaces): add workspace slug support

* chore(workspaces): lint

* feat(workspaces): add slug validation and generation

* fix(workspaces): test lint miss
2024-09-18 13:29:36 +02:00