256 Commits

Author SHA1 Message Date
wendrul ecb0e9b961 Implement PushArgs from cloudevents+json (#3927)
* Implement PushArgs from cloudevents+json

* Remove incomplete batching, overwrite metadata

Overwrite metadata to make it available as a script parameter if
present.
2024-06-18 22:13:32 +02:00
Ruben Fiszel d518e2359d fix: fix workflow as code 2024-06-17 05:37:57 +02:00
HugoCasa e0ac22ba4a fix: job perms for agent mode (#3911) 2024-06-14 17:36:10 +02:00
HugoCasa 21b9accca1 feat: replace ephemeral tokens by jwt (#3908)
* feat: replace ephemeral tokens by jwt

* fix: migration + sqlx

* fix: tests, agent, ee ref

* fix: sqlx

* fix: tests

* fix: jwt prefix change + fix tests

* fix: nit

* fix: handle agent mode
2024-06-14 13:07:35 +02:00
Ruben Fiszel 1957ca03b3 feat(cli): add wmill flow generate-locks 2024-06-10 11:44:53 +02:00
Ruben Fiszel 5ae8592792 feat: track dependency map for bun + inline script of flows 2024-06-08 16:43:48 +02:00
Ruben Fiszel 181cb7dec9 fix: further restrict job api to logged in workspace users or anonymous jobs only" (#3860) 2024-06-03 15:13:15 +02:00
Ruben Fiszel 9308e2a63c fix compile issue 2024-05-31 12:30:58 +02:00
Ruben Fiszel 8b66636a89 fix: remove quotes around interpolated arg values of tags 2024-05-28 16:56:27 +02:00
Ruben Fiszel b58c6257a6 set last_ping to null when requeuing because of concurrency limits 2024-05-27 15:53:32 +02:00
Ruben Fiszel 3c74da4116 increase min re-scheduling 2024-05-26 05:20:11 +02:00
Ruben Fiszel e397a385e2 reschedule to at least 1secs in future 2024-05-26 05:04:42 +02:00
Ruben Fiszel 7a36f30fe3 fix: make all error strings more verbose 2024-05-25 22:15:15 +02:00
Ruben Fiszel 7a664b5cd4 nit improvements for concurrency jobs 2024-05-25 17:28:32 +02:00
Ruben Fiszel 545d982419 nit improvements for concurrency jobs 2024-05-25 17:26:08 +02:00
Ruben Fiszel f2d9c3c777 fix: improve concurrency re-scheduling at scale 2024-05-25 17:20:11 +02:00
Ruben Fiszel e187fa6263 fix: improve concurrency re-scheduling at scale 2024-05-25 15:56:56 +02:00
HugoCasa 47bb5d2492 fix: use hub script language as tag instead of 'hub' (#3816)
* fix: use hub script language as tag instead of 'hub'

* fix: remove hub tag
2024-05-25 10:38:03 +02:00
Ruben Fiszel 7e0be8914b feat: store failed_retries per module state and display failed retries in flow status viewer 2024-05-23 19:16:26 +02:00
HugoCasa 62f318077c feat: improve permissioned audit logs (#3799)
* fix: increase token label size in db

* Revert "Revert "feat:  improve premissioned audit logs (#3793)" (#3798)"

This reverts commit 43a24d997e.

* feat: add username to email function

* fix: nit

* fix: add docstring to global func
2024-05-23 17:23:50 +02:00
Ruben Fiszel 43a24d997e Revert "feat: improve premissioned audit logs (#3793)" (#3798)
This reverts commit 21a077ecfa.
2024-05-23 11:12:51 +02:00
HugoCasa 21a077ecfa feat: improve premissioned audit logs (#3793)
* feat:  improve premissioned audit logs

* chore: update ee ref

* fix: build

* fix: sqlx
2024-05-23 08:55:48 +02:00
Ruben Fiszel b56fbdf898 fix: improve concurrency key migration 2024-05-21 12:18:05 +02:00
Ruben Fiszel 7a1808e951 feat: reduce memory usage (#3768)
* all

* all

* optimize deserialize

* all

* all

* fix issue

* fix compile

* fix compile

* fix compile

* fix compile

* fix compile

* fix compile

* fix compile

* fix compile

* fix compile

* fix compile
2024-05-19 21:58:38 +02:00
Ruben Fiszel 2b06d9ae79 fix: fix args interpolation for tag and concurrency key for non string values 2024-05-17 00:27:38 +02:00
Ruben Fiszel 9e86177142 fix: improve support for non existing key in concurrency_key table 2024-05-16 23:43:30 +02:00
HugoCasa f3b8e01981 fix(backend): prevent immediate cancellation of the error handler when a job is forcibly cancelled (#3751) 2024-05-16 16:53:27 +02:00
wendrul d3942097df Add concurrency limits observability (#3586)
* Add concurrency_key table and field to payload

Add a new table custom_concurrency_key for storing concurrency keys on a
per job basis. Add the field to the job payload to populate the table on
creation of a new job.

* Rename to custom_concurrency_key

Be more explicit about the nature of the option variable by calling it
a more appropriate name.

* Delete concurrency_keys on delete_expire_items

* Propagate db errors up

* Add ref to EE changes

* update sqlx

* Add concurrency_key to tests

* Revert renaming of FlowValue field

FlowValue field concurrency_key must be named concurrency_key for
serialization purposes.

* Remove debug print statement

* Get concurrency_key from Job

Whether it is a Completed job or a queued one, add a ways to get the
associated concurrency key

* Add endpoint to get concurrency_key

* Add endpoint and button to get job concurrency_key

Add a line with a link on the FlowMetadata that goes to the
concurrency_groups page. add endpoint to get the concurrency_key of a
job

* Merge concurrency_key tables into one

migration + change all related querrys

* Add concurrency plot to the runs page

* Prepare sqlx

* Add concurrency Key filter on UI

* Prepare sqlx

* Prepare sqlx

* Fix filter and order query

The limit makes more sense if we cut the older rows, so order by
started_at

* Factor interpolation to reuse on concurrency key

Factor the arg interpolation logic into a function and finish the
processing of concurrency key before insertion

* Remove old concurrency key processing logic

* Second transaction with userdb

To send all concurrency intervals but revealing only uuids of accessible
jobs, make a second transaction with the userdb.

* Remove old second endpoint

the intervals endpoint now also gets the concurrencyt key information
for all jobs

* Show external jobs

* Put filters into a dropdown

Create a ToggleButtonMore and put elements into a dropdown

* Add toggle between two graphs

* Add filter functionality to concurrency graph

* Improve concurrency graph front

* Fix concurrency groups page

* Prepare sqlx

* Add ref to ee

* Change migration to create new table instead

Instead of renaming the custom_concurrency_key_ended atble, we create a
new table and we will delete custom_concurrency_key_ended in the future
when it is no longer linked to any jobs

* Do small UI improvements

* Fix range fusion by not filtering past jobs

Instead of filtering jobs in the backend on a startedAfter value, limit
the query to 1000 and query all possible towards the past to get a good
context for the graph in most sane situations

* Improve frontend UI
2024-05-15 20:15:14 +02:00
Ruben Fiszel 28cc563df8 fix: improve display result output limit 2024-05-15 05:59:31 +02:00
Ruben Fiszel 11b3ea3ac8 feat: local typescript codebase as bundle (#3694)
* codebases

* codebases

* foo

* foo

* foo

* foo

* fix(frontend): Disable the insert button when required fields are empty strings (#3659)

* fix(frontend): use normal password mask for the sensitive fields of the resource editor

* handle super admins in password arg input

* chore(main): release 1.323.2 (#3660)

* chore(main): release 1.323.2

* Apply automatic changes

---------

Co-authored-by: rubenfiszel <rubenfiszel@users.noreply.github.com>

* foo

* all

* s3_helpers move

* progress

* all

* progress

* progress

* progress

* progress

* codebase final

* update without ee

* sqlx

* all

* all

* all

* all

* all

* all

* all

* all

* all

* all

* all

* all

* all

* all

* all

* update

* all

* all

* all

---------

Co-authored-by: Faton Ramadani <faton.ramadani14@gmail.com>
Co-authored-by: rubenfiszel <rubenfiszel@users.noreply.github.com>
2024-05-09 18:35:50 +02:00
HugoCasa 010662d3d0 fix: can cancel only if can disable schedule + stop worker on force cancel + soft cancel job parent on job cancel (#3670)
* fix: can cancel only if can disable schedule + stop worker on force cancel + cancel job parents

* fix: sqlx build

* fix: flow reschedule check + soft cancel only direct parent

* fix: sqlx prepare

* fix: only soft cancel parent if force cancel and job is a flow step
2024-05-07 17:17:43 +02:00
HugoCasa 29b1e6f6a2 feat: critical error side channel (#3625)
* feat: critical error side channel

* feat: trigger workspace error handler or critical channel on schedule error handling failure

* fix: build

* feat: finish critical error side channel

* feat: channels instead of just emails + move to EE

* fix: remove superfluous func

* fix: nits + ee ref

* fix: open source build

* fix: nits

* chore: update ee ref
2024-05-02 20:21:23 +02:00
Ruben Fiszel 718fcca51a fix test lint issues 2024-05-02 11:23:39 +02:00
Ruben Fiszel 4015192a29 fix test lint issues 2024-05-02 10:54:51 +02:00
Ruben Fiszel eb8e80a146 box flowmodulestatus to reduce stack allocation of flowvalue 2024-05-02 10:28:04 +02:00
Ruben Fiszel b2d9f7d717 add cloud compile flag 2024-05-02 09:39:40 +02:00
Ruben Fiszel 882c28fbe2 refactor workspace error handler 2024-05-01 23:48:23 +02:00
Ruben Fiszel 96760b2964 fix: handle list of errors for schedule error handler 2024-05-01 23:17:34 +02:00
Ruben Fiszel e8e6a6c281 labels nits 2024-04-24 11:56:14 +02:00
Ruben Fiszel 534f877a7a fix: fix label from completed_job 2024-04-24 09:52:26 +02:00
Ruben Fiszel 48ba709627 fix: improve re-scheduled for estimation in concurrency limits 2024-04-21 12:41:30 +02:00
HugoCasa fdaa49a7e9 fix(backend): prevent push fail of schedule error handling from reverting job completion (#3568)
* fix: prevent push fail of schedule error handling from reverting job completion

* fix: sqlx
2024-04-17 12:35:31 +02:00
Ruben Fiszel a55aad3003 feat: flow concurrency limits support custom concurrency key 2024-04-09 22:03:39 +02:00
Ruben Fiszel ff26c8e42d feat: while loop as new flow primitive 2024-04-02 17:38:11 +02:00
Ruben Fiszel cc5d1b405e continue on error option for steps 2024-04-02 10:32:47 +02:00
Ruben Fiszel bdf7b14c69 increase max concurrent run demo workspace 2024-03-30 13:45:41 +01:00
Ruben Fiszel 44d812f95b exclude demo from per workspace restrictions 2024-03-29 13:38:36 +01:00
HugoCasa b4ffb500ba feat: add workspace free-tier usage (#3489)
* feat: separate workspace and user usage

* fix: sqlx build
2024-03-29 10:56:44 +01:00
HugoCasa e3a636ab17 fix: show start to finish time for flows instead of cumulative (#3486)
* fix: show start to finish time for flows instead of cumulative

* fix: build
2024-03-28 15:50:18 +01:00
Ruben Fiszel ef1ce83279 feat: add set_flow_user_states and get_flow_user_states api and sdk support 2024-03-26 17:31:17 +01:00