1
0
mirror of https://github.com/Unleash/unleash.git synced 2024-11-01 19:07:38 +01:00
Commit Graph

9370 Commits

Author SHA1 Message Date
Simon Hornby
2b210a85fd
docs: update compatibility matrix with strategy variants (#4626) 2023-09-08 10:34:04 +02:00
Jaanus Sellin
bc0c6fcb62
fix: fix failing group service test (#4642) 2023-09-08 11:32:21 +03:00
Jaanus Sellin
c59b83b07b
feat: integration urls, ux (#4640) 2023-09-08 10:21:11 +03:00
Gastón Fournier
feab6db76e
Revert "fix: api token schema" (#4638)
Reverts Unleash/unleash#4633 because of
https://github.com/Unleash/unleash/pull/4633#issuecomment-1710122769
2023-09-07 15:25:49 +02:00
Jaanus Sellin
cd2eac23ef
feat: official sdks (#4637) 2023-09-07 16:19:52 +03:00
Tymoteusz Czech
e97859af91
Integrations form (#4622)
## About the changes
Redesigned/refactored integrations form.


![image](https://github.com/Unleash/unleash/assets/2625371/9f3ad019-e367-4f89-932d-539d7a370f88)

Closes
[1-1298/resesign-of-integrations-form](https://linear.app/unleash/issue/1-1298/resesign-of-integrations-form)
2023-09-07 10:27:46 +00:00
Gastón Fournier
fe51b501e6
fix: api token schema (#4633)
## About the changes
Create api token schema can either provide the field `project` or its
plural: `projects` so the joi validation makes them optional:
2be77fb55e/src/lib/schema/api-token-schema.ts (L20-L24)

This means that when returning the token, the response will either
contain `project` or `projects` depending on what was provided as input.
Therefore we need to make both fields optional in the response
2023-09-07 12:23:53 +02:00
Tymoteusz Czech
2be77fb55e
feat: integration sections (#4631)
Co-authored-by: sjaanus <sellinjaanus@gmail.com>
2023-09-07 09:20:12 +00:00
Jaanus Sellin
1d414db982
feat: jira plugin page (#4627)
![image](https://github.com/Unleash/unleash/assets/964450/b58d3d27-4939-42b0-bf0d-51a31aa93dde)


![image](https://github.com/Unleash/unleash/assets/964450/acceedc4-9d53-461a-910f-b60dae0d6b6a)
2023-09-07 11:51:50 +03:00
Thomas Heartman
3b754ec7ed
1-1342: show flag naming pattern info when you copy toggles (#4629)
Because you need to match the pattern when copying toggles, it's
important that we show the required information to the user.

This change adds information about the pattern to the page. This isn't
its final design, but it's more important that the information is
there (to avoid user frustration) than that it is pretty.
2023-09-07 10:22:13 +02:00
Nuno Góis
cfbf47d6bd
refactor: clean up no longer used PAT methods (#4621)
This cleans up some PAT-related methods that are no longer used.
2023-09-07 09:48:55 +02:00
Thomas Heartman
90395b974b
1-1315: revalidate feature name whenever the project changes (#4628)
This change makes it so that the flag name is revalidated against the
new
project pattern whenever you change the target project for a flag.

The validation is not run if the name is empty, if there is no
pattern, or if there is no validation method.

This solves the case where you input a name, then change the project,
and where the name isn't valid for the new project. Previously, it
wouldn't revalidate, but now it does.
2023-09-07 09:15:59 +02:00
Mateusz Kwasniewski
15015f78f3
feat: Plausible search (#4625) 2023-09-07 08:21:37 +02:00
Thomas Heartman
31ed96d8f3
1-1320: allow you to update example with no pattern + update state better (#4623)
While having a pattern when you have no example doesn't make a lot of
sense, it's a problem that you can't delete the example after deleting
the pattern: you previously had to remove the example before the
pattern.

This PR fixes that by always allowing you to update the example, even if
there is no pattern. Our server doesn't currently accept submitting an
example with no pattern, but we could allow that if we want to (and
probably just discard it on the back-end).

This PR also updates the validation of the example and the regex. There
were more unhandled edge cases previously where the validation would
disappear or be wrong. This should be fixed now. The new logic is that,
whenever you update the either the pattern or the example, we check:
- if you have an error in your pattern, no pattern, or no example, then
delete the example error if it exists
- have a well-formed pattern and an example then check if the example
matches the pattern and add/delete an error accordingly

This does have some consequences: editing the pattern can render your
example invalid. You'll also get immediate feedback instead of when you
switch focus. I think this is often a bad pattern (giving the user too
much negative feedback), but in terms of working with regexes, I think
it might be a good thing. We also give immediate feedback today, so I
don't think this is a regression.

Any thoughts are welcome.
2023-09-07 08:18:18 +02:00
Mateusz Kwasniewski
a0fbad26bf
feat: persistent search queries (#4624) 2023-09-06 15:46:10 +02:00
Nuno Góis
af9756e1e1
fix: prevent 404 on auth settings hook (#4619)
Since `auth/{auth_type}/settings` is an Enterprise route, this prevents
404s when we try to use the hook to fetch auth settings in
non-Enterprise instances by using the conditional `useEnterpriseSWR`
hook.
2023-09-06 13:35:02 +01:00
Thomas Heartman
34d595b5a6
refactor: use conditionally render instead of && (#4620)
For consistency and readability.
2023-09-06 11:51:04 +00:00
Mateusz Kwasniewski
caff040a88
feat: Clickable search filter options (#4618) 2023-09-06 12:50:42 +02:00
Thomas Heartman
f55c67fe2e
1-1334: show short error message when validation fails (#4617)
The error message only tells the user that the name doesn't match the
pattern. Because we already show the pattern above the input, we don't
need to repeat it in the error message. This makes for a shorter and
more concise message and better UX.

At the same time, for API users, we can keep the more detailed message
that includes info about the pattern, the example, and the description.


![image](https://github.com/Unleash/unleash/assets/17786332/0492f2ad-810d-435e-bfe6-785afee96892)
2023-09-06 10:20:10 +00:00
Thomas Heartman
1ffa0b86d9
1-1307: Show info about flag naming patterns before making mistakes (#4616)
This PR adds info about a project's flag naming pattern to the flag
creation form. This way, it's displayed before the user tries to create
a flag, so that they have all the necessary information before making
mistakes.


![image](https://github.com/Unleash/unleash/assets/17786332/7a3fb036-5315-4c2b-934d-004da6b364a3)
2023-09-06 12:14:17 +02:00
Thomas Heartman
0b8b772ff1
1-1333: fix type problems (#4615)
This change makes it so that you can save flag naming data on project
creation.

There was a mismatch between flattened and nested data in the creation
endpoint. Likely because we went back and forth a bit when we created
the feature originally.
2023-09-06 12:13:48 +02:00
Mateusz Kwasniewski
2b85eed5b5
feat: Search UI improvements (#4613) 2023-09-06 10:50:20 +02:00
Thomas Heartman
73b7cc0b5a
1-1319: add feature naming pattern descriptions (#4612)
This PR adds a feature naming pattern description to the project form.
It's rendered as a multi-line input field. The description is also
stored in the db.

This adapts most of @andreas-unleash's PR #4599 with some minor changes
(using description instead of prompt). Actually displaying this data to
the users will come in a later PR.


![image](https://github.com/Unleash/unleash/assets/17786332/b96d2dbb-2b90-4adf-bc83-cdc534c507ea)
2023-09-06 08:13:28 +00:00
dependabot[bot]
31df85a3f5
chore(deps): bump @adobe/css-tools from 4.0.2 to 4.3.1 in /frontend (#4584)
Bumps [@adobe/css-tools](https://github.com/adobe/css-tools) from 4.0.2
to 4.3.1.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/adobe/css-tools/blob/main/History.md"><code>@​adobe/css-tools</code>'s
changelog</a>.</em></p>
<blockquote>
<h1>4.3.1 / 2023-03-14</h1>
<ul>
<li>Fix redos vulnerability with specific crafted css string -
CVE-2023-26364</li>
</ul>
<h1>4.3.0 / 2023-03-07</h1>
<ul>
<li>Update build tools</li>
<li>Update exports path and files</li>
</ul>
<h1>4.2.0 / 2023-02-21</h1>
<ul>
<li>Add <a
href="https://github.com/container"><code>@​container</code></a>
support</li>
<li>Add <a href="https://github.com/layer"><code>@​layer</code></a>
support</li>
</ul>
<h1>4.1.0 / 2023-01-25</h1>
<ul>
<li>Support ESM Modules</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/adobe/css-tools/commits">compare view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=@adobe/css-tools&package-manager=npm_and_yarn&previous-version=4.0.2&new-version=4.3.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)
You can disable automated security fix PRs for this repo from the
[Security Alerts
page](https://github.com/Unleash/unleash/network/alerts).

</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-09-05 21:47:44 +02:00
Nuno Góis
c3216ac941
fix: group roles assumption, refactor group types (#4576)
Does what it says on the tin, should help with cleaning up
https://github.com/Unleash/unleash/pull/4512 and respective schema
changes.

---------

Co-authored-by: Gastón Fournier <gaston@getunleash.io>
2023-09-05 20:30:20 +01:00
Nuno Góis
1ae700a027
feat: add request logger env variable (#4614)
Adds a new env variable for request logger.

---------

Co-authored-by: Gastón Fournier <gaston@getunleash.io>
2023-09-05 15:32:20 +01:00
Mateusz Kwasniewski
41858a4952
feat: Search suggestion selectable (#4610) 2023-09-05 15:31:31 +02:00
Tymoteusz Czech
47a59224bb
Integration card component (#4557)
![image](https://github.com/Unleash/unleash/assets/2625371/42364fdb-1ff1-48c4-9756-a145a39e45b9)


## About the changes
<!-- Describe the changes introduced. What are they and why are they
being introduced? Feel free to also add screenshots or steps to view the
changes if they're visual. -->

<!-- Does it close an issue? Multiple? -->
Closes #

<!-- (For internal contributors): Does it relate to an issue on public
roadmap? -->
<!--
Relates to [roadmap](https://github.com/orgs/Unleash/projects/10) item:
#
-->

### Important files
<!-- PRs can contain a lot of changes, but not all changes are equally
important. Where should a reviewer start looking to get an overview of
the changes? Are any files particularly important? -->


## Discussion points
<!-- Anything about the PR you'd like to discuss before it gets merged?
Got any questions or doubts? -->
2023-09-05 12:14:03 +00:00
Thomas Heartman
a1e98056ec
feature naming patterns: allow empty values in examples and patterns (#4611)
Allow empty patterns and examples for feature naming. 

This fixes an issue where the form would break, not allowing you to
create new projects at all.
2023-09-05 11:40:03 +00:00
Tymoteusz Czech
c19bd615b9
fix: reset selected toggle after archive or revive (#4606)
<!-- Thanks for creating a PR! To make it easier for reviewers and
everyone else to understand what your changes relate to, please add some
relevant content to the headings below. Feel free to ignore or delete
sections that you don't think are relevant. Thank you! ❤️ -->

## About the changes
When archiving or reviving feature toggles, when toggles disappear from
table, actions bar should also disappear.

<!-- Does it close an issue? Multiple? -->
Closes
https://linear.app/unleash/issue/1-1293/bulk-revive-modal-doesnt-go-away
2023-09-05 11:44:28 +02:00
Thomas Heartman
d5edcc33e6
add descriptions in form (#4608)
This PR adds descriptions of the various feature flag naming input
fields in the project settings form. It also wraps the feature naming
fields in a fieldset to group them semantically.


![image](https://github.com/Unleash/unleash/assets/17786332/a8d5c2c6-3381-4b76-89a1-18316c2e5193)
2023-09-05 09:22:52 +00:00
Thomas Heartman
8a8a7b0899
1-1329: return 400 when pattern is empty but example is not (#4609)
Adding an example when there is no pattern doesn't make any sense, so it
should be an error.

Tests in https://github.com/ivarconr/unleash-enterprise/pull/721
2023-09-05 09:09:55 +00:00
Mateusz Kwasniewski
848b35a7a6
feat: search event log by tags (#4604) 2023-09-04 17:37:23 +02:00
Gastón Fournier
19ec66a9d1
chore: token api simplification (#4600)
## About the changes
We found a problem generating the Go SDK client for the tokens API that
makes use of `oneOf`, combined with `allOf`. The generator doesn't know
how to map this type and leaves it as an object. This PR simplifies the spec and therefore the code generated after it
2023-09-04 16:02:24 +02:00
Jaanus Sellin
53f90d37c5
feat: feature naming patterns (#4591)
Adds a first iteration of feature flag naming patterns. Currently behind a flag.

Signed-off-by: andreas-unleash <andreas@getunleash.ai>
Co-authored-by: Thomas Heartman <thomas@getunleash.io>
Co-authored-by: andreas-unleash <andreas@getunleash.ai>
Co-authored-by: Thomas Heartman <thomas@getunleash.ai>
2023-09-04 11:53:33 +00:00
Mateusz Kwasniewski
45e089f27f
chore: strategy variant flag removed (#4603) 2023-09-04 13:15:54 +02:00
Tymoteusz Czech
8aace7f93f
refactor: instance health cleanup (#4602)
## About the changes
Cleanup after hackathon. Discovered project on:
https://linear.app/unleash/project/active-users-and-instance-dashboard-67352abadf49
2023-09-04 13:10:23 +02:00
Mateusz Kwasniewski
5ae86ef196
chore: Change request flags removed (#4601) 2023-09-04 10:57:13 +02:00
Tymoteusz Czech
ad9d9d9745
Add "remove" option inside "configure integration" page (#4562)
<!-- Thanks for creating a PR! To make it easier for reviewers and
everyone else to understand what your changes relate to, please add some
relevant content to the headings below. Feel free to ignore or delete
sections that you don't think are relevant. Thank you! ❤️ -->

## About the changes

https://linear.app/unleash/issue/1-1268/add-remove-option-inside-configure-integration-page


![image](https://github.com/Unleash/unleash/assets/2625371/eb192f1e-65df-4208-90b4-f2757bc27868)
2023-09-04 09:32:54 +02:00
Gastón Fournier
adec9138ea
fix: Add feature environment variants updated event (#4598)
## About the changes
Add additional event that can be configured inside Slack App Addon
2023-09-01 16:54:09 +02:00
Nuno Góis
b4ef343d22
refactor: clean up some unused imports (#4597)
Should help cleaning up some of these:


![image](https://github.com/Unleash/unleash/assets/14320932/f0bcee80-1ec8-4935-b167-dc8e8b92cda2)
2023-09-01 15:32:15 +01:00
Gastón Fournier
ea00ea9d56
docs: troubleshooting guides (#4592)
## About the changes
Adds troubleshooting guides for some common problems under the how-to
area (following the [diataxis framework](https://diataxis.fr/)).

This is part of Unleash 2023 offsite challenge

---------

Co-authored-by: Drew Gorton <drew.gorton@getunleash.io>
Co-authored-by: Diego Susa <diego@getunleash.io>
Co-authored-by: Michael Vittiglio <michael.vittiglio@getunleash.io>
Co-authored-by: Thomas Heartman <thomas@getunleash.ai>
2023-09-01 15:39:23 +02:00
Thomas Heartman
1799086deb
openapi: sort tags file (#4595)
This change sorts the tags in the tags file and tests that the list is
sorted alphabetically. This makes it easier to
find tags in the file. 

#4580 already introduced a test to check that we have no duplicate
tags, so this isn't as necessary anymore, but it's still nice to have.

It also removes the previous auto-sorting before exporting. This is to
ensure that entries are sorted in the source list. This might seem like
a regression, but it makes it easier to spot near-duplicate tags:

> Despite having the test that validates there are no duplicates, you
can always have Notifications and Notification API by mistake (tags that
mean the same but are different). Keeping the list alphabetically sorted
might help to prevent this before pushing the change to prod. In this
case, we will eventually find out and fix it, so this could be a good
reason to have the list sorted.
2023-09-01 10:15:12 +00:00
Tymoteusz Czech
063a4f7875
fix: config snapshot (#4593) 2023-08-30 15:07:08 +02:00
Tymoteusz Czech
0d5f33f8ba
Feat/instance health (#4586)
Hackathon

---------

Co-authored-by: chriswk <chriswk@getunleash.io>
2023-08-30 12:51:46 +00:00
Fredrik Strand Oseberg
3b2d6a4cbf
feat: DORA metrics lead time to production (#4589)
* Adds initial support for estimating dora metric lead time for changes
per feature toggle
2023-08-30 14:39:43 +02:00
David Leek
ff346adb94
chore: return 404 when projectid not found (#4581)
## About the changes
Returns Not Found on create and get project api tokens when given a
project id that doesn't exist

## Discussion points
- This is an extra lookup per execution of the endpoint
2023-08-30 10:24:20 +02:00
Gastón Fournier
ae18c3d6c1
chore: Remove duplicated tags (#4580)
## About the changes
At https://github.com/Unleash/unleash/pull/4432 we've introduced the
same tags twice which causes issues when generating the api clients.

Closes #2-1350-fix-openapi-duplicated-tags
2023-08-28 14:03:58 +02:00
David Leek
95be24996e
Fixes hangs when sending incorrect parameters to deleteProjectApiToken endpoint (#4579)
## About the changes
Returns either 400 or 404 when token isn't found or doesn't match single
project must be provided projectId criteria

<!-- Does it close an issue? Multiple? -->
Closes #
Linear 2-1003

## Discussion points
<!-- Anything about the PR you'd like to discuss before it gets merged?
Got any questions or doubts? -->
Is projects.length > 1 a 400?
2023-08-28 13:53:32 +02:00
Jaanus Sellin
873c00a566
feat: update breakpoint from 1260 to 1280 (#4575) 2023-08-27 20:36:02 +03:00