1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-01-20 00:08:02 +01:00
unleash.unleash/src/lib/services
Fredrik Strand Oseberg f34d187cd9
Refactor/separate client and admin store (#5006)
This PR is the first step in separating the client and admin stores.
Currently our feature toggle services uses the client store to serve
multiple purposes. 

Admin API uses the feature toggle service to serve both the feature
toggle list and playground features, while the client API uses the
feature toggle service to serve client features. The admin API can
change often and have very different requirements than the client API,
which changes infrequently and generally keeps the same stable structure
for long periods of time. This architecture is error prone, because when
you need to make changes to the admin API, you can very easily affect
the client API.

I aim to put up a stone wall between the two APIs. Complete separation
between the two APIs, at the cost of some duplication.

In this PR I have created a feature oriented architecture for client
features and disconnected the client API from the feature toggle
service. It now goes through it's own service to it's own store. For
feature toggle service I have duplicated and replaced the functionality
that serves /api/admin/features, I have kept a lot of the ugliness in
the code and haven't removed anything in order to avoid breaking
changes.

Next steps: 
* Move playground to admin API
* Remove client-feature-toggle-store from feature-toggle-service
2023-10-12 13:58:23 +02:00
..
client-metrics Refactor/move features to feature oriented architecture (#4994) 2023-10-11 09:38:57 +02:00
access-service.test.ts refactor: prefer eventService.storeEvent methods (#4830) 2023-09-27 14:23:05 +01:00
access-service.ts feat: biome lint (#4853) 2023-09-29 14:18:21 +02:00
account-service.ts refactor: prefer eventService.storeEvent methods (#4830) 2023-09-27 14:23:05 +01:00
addon-schema.ts feat: support filtering on project and environment fields for events (#1801) 2022-07-12 12:13:25 +00:00
addon-service-test-simple-addon.ts feat: add OpenAPI validation to a few endpoints (#1409) 2022-04-25 14:17:59 +02:00
addon-service.test.ts feat: add more events in integrations (#4815) 2023-09-29 16:11:59 +01:00
addon-service.ts Refactor/move features to feature oriented architecture (#4994) 2023-10-11 09:38:57 +02:00
api-token-service.test.ts feat: biome lint (#4853) 2023-09-29 14:18:21 +02:00
api-token-service.ts feat: biome lint (#4853) 2023-09-29 14:18:21 +02:00
client-spec-service.test.ts refactor: avoid inlining segments for supported clients (#1640) 2022-06-02 14:07:46 +02:00
client-spec-service.ts refactor: avoid inlining segments for supported clients (#1640) 2022-06-02 14:07:46 +02:00
context-schema.ts feat: add context value descriptions (#1496) 2022-04-19 08:40:07 +02:00
context-service.ts feat: add more events in integrations (#4815) 2023-09-29 16:11:59 +01:00
edge-service.ts docs: Added docs for edge endpoints (#3501) 2023-04-14 15:39:39 +02:00
email-service.test.ts Hyperlink Injection in People Invitation Emails (#2307) 2022-11-01 10:38:33 +02:00
email-service.ts feat: biome lint (#4853) 2023-09-29 14:18:21 +02:00
environment-service.ts feat: biome lint (#4853) 2023-09-29 14:18:21 +02:00
event-announcer-service.ts 1-1049 Emit events after db transaction is complete (#4174) 2023-07-10 08:43:22 +02:00
event-service.ts feat: biome lint (#4853) 2023-09-29 14:18:21 +02:00
favorites-service.ts refactor: prefer eventService.storeEvent methods (#4830) 2023-09-27 14:23:05 +01:00
feature-service-potentially-stale.test.ts Refactor/move features to feature oriented architecture (#4994) 2023-10-11 09:38:57 +02:00
feature-tag-service.ts feat: add more events in integrations (#4815) 2023-09-29 16:11:59 +01:00
feature-type-service.ts feat(#4205): implement configurable lifetimes (#4263) 2023-07-18 09:26:32 +00:00
group-service.ts feat: add more events in integrations (#4815) 2023-09-29 16:11:59 +01:00
health-service.ts
index.ts Refactor/separate client and admin store (#5006) 2023-10-12 13:58:23 +02:00
maintenance-service.test.ts feat: disable scheduler for tests (#4496) 2023-08-15 15:58:36 +02:00
maintenance-service.ts feat: disable scheduler for tests (#4496) 2023-08-15 15:58:36 +02:00
openapi-service.ts feat: biome lint (#4853) 2023-09-29 14:18:21 +02:00
pat-service.ts refactor: prefer eventService.storeEvent methods (#4830) 2023-09-27 14:23:05 +01:00
project-health-service.ts Refactor/move features to feature oriented architecture (#4994) 2023-10-11 09:38:57 +02:00
project-schema.ts Feat/project private mode (#4743) 2023-09-15 11:01:25 +03:00
project-service.ts Refactor/move features to feature oriented architecture (#4994) 2023-10-11 09:38:57 +02:00
proxy-service.ts feat: biome lint (#4853) 2023-09-29 14:18:21 +02:00
public-signup-token-service.ts refactor: prefer eventService.storeEvent methods (#4830) 2023-09-27 14:23:05 +01:00
reset-token-service.ts feat: changing password will expire reset password tokens (#3451) 2023-04-05 12:39:52 +03:00
scheduler-service.test.ts feat: add ids to scheduled jobs (#4764) 2023-09-18 16:31:42 +02:00
scheduler-service.ts feat: add ids to scheduled jobs (#4764) 2023-09-18 16:31:42 +02:00
segment-schema.ts feat: add segments (#1426) 2022-03-29 14:59:14 +02:00
segment-service.ts Refactor/move features to feature oriented architecture (#4994) 2023-10-11 09:38:57 +02:00
session-service.ts
setting-service.ts refactor: prefer eventService.storeEvent methods (#4830) 2023-09-27 14:23:05 +01:00
state-schema.ts feat: Add variants per env (#2471) 2022-11-21 10:37:16 +01:00
state-service-export-v1.json
state-service.test.ts refactor: prefer eventService.storeEvent methods (#4830) 2023-09-27 14:23:05 +01:00
state-service.ts Refactor/move features to feature oriented architecture (#4994) 2023-10-11 09:38:57 +02:00
state-util.ts feat: biome lint (#4853) 2023-09-29 14:18:21 +02:00
strategy-schema.ts Feat/enable disable strategies (#3566) 2023-04-21 12:09:07 +03:00
strategy-service.ts refactor: prefer eventService.storeEvent methods (#4830) 2023-09-27 14:23:05 +01:00
tag-schema.test.ts
tag-schema.ts chore: Improve openapi documentation for tags (#3496) 2023-04-12 09:34:32 +00:00
tag-service.ts refactor: prefer eventService.storeEvent methods (#4830) 2023-09-27 14:23:05 +01:00
tag-type-schema.test.ts
tag-type-schema.ts
tag-type-service.ts feat: biome lint (#4853) 2023-09-29 14:18:21 +02:00
user-feedback-service.ts
user-service.test.ts feat: allow defining initial admin user as env variable (#4927) 2023-10-06 09:07:06 +02:00
user-service.ts feat: allow defining initial admin user as env variable (#4927) 2023-10-06 09:07:06 +02:00
user-splash-service.ts refactor: add schemas to user admin controller (#1692) 2022-06-22 14:55:43 +02:00
version-service.test.ts feat: feature changes counted in new table (#4958) 2023-10-10 12:32:23 +02:00
version-service.ts feat: feature changes counted in new table (#4958) 2023-10-10 12:32:23 +02:00