Commit graph

53 commits

Author SHA1 Message Date
Sipke Schoorstra c8d87cd763
Simplify Proto.Actor bookmarks and triggers (#3917)
* Refactor HTTP route table population

* Update workflow definition EF store to use abstract IWorkflowInstanceStore

This decoupling is necessary, because the application might not be using EF Core, but e.g. Elasticsearch

* Move workflow state persistence to the default workflow runtime feature

* Update JS handler to provide access to variables during trigger indexing

* Configure Proto.Actor runtime with different workflow pipeline

* Add sample using Proto.Actor runtime

* Replace BookmarkGrain with DB based persistence
2023-04-17 15:23:05 +02:00
Sipke Schoorstra cebf6f12e3 Add integration test for reading composite activity output 2023-03-24 22:25:48 +01:00
gurkanguran e4789cf85b
Reference variable with Id instead of Name to prevent issues with updating name (#3814)
* Implemented Id property for variable for memory reference

* Removed debugger

* Fixed the issue with memory block reference of variable

* Fixed infinite recursive calling issue

* Handle variables with ID already containing

* Update JS variable getters based on declared variables

* Prevent Export from including composite roots

* Update JS evaluator with support for reading and writing variables in scope

* Fix polymorphic converter with support for arrays

---------

Co-authored-by: Sipke Schoorstra <sipkeschoorstra@outlook.com>
2023-03-22 22:50:26 +01:00
Sipke Schoorstra fad27d0fb0
Refactor composite activity input and scoped memory (#3815)
* Incremental work

* Enable control over when to include full compositie root

* Cleanup

* Update WorkflowDefinitionActivity

* Implement input as variables

* Delete unused class

* Remove less common types

* Rename ExpandoObject to JSON

* Implement variable scoping

* Remove parent/child relationship from MemoryRegister

* Add support for sending input to "trigger event" endpoint

* Add support for configuring input storage driver

* Remove unused namespace imports

* Auto-register activity types when running a workflow

* Fix missing variables from containers
2023-03-20 19:55:11 +01:00
herblinernexxbizz 95ca326133
Features/v3 add short and full guid (#3800)
* add full guid and shortguid as javascript/jint functions with intellisense

* add guid as string and rename other method
2023-03-15 12:29:07 +01:00
Sipke Schoorstra c81e328c8d Fix early exit on workflow definition activity input evaluation 2023-03-14 08:17:04 +01:00
Sipke Schoorstra 6fcf23dffa Add XML comments & small cleanup 2023-03-14 08:14:14 +01:00
Sipke Schoorstra d8b95db04e Add support for providing workflow input via dispatch endpoint 2023-03-13 12:31:23 +01:00
Sipke Schoorstra 1a713b4619
Rename "services" to "contracts" and "implementations" to "services" (#3758) 2023-03-03 22:47:23 +01:00
Sipke Schoorstra 00bd3228f6 Restructure contracts vs services namespace 2023-03-03 14:48:05 +01:00
Sipke Schoorstra 1e407a9f70
Fix cyclic input argument evaluation (#3755)
* Prevent stack overflow when evaluating input arguments

* Shuffle test folders
2023-03-02 21:21:50 +01:00
Sipke Schoorstra 1e0fdf937d
Add output picker for SetWorkflowOutput activity (#3728)
* Add output picker for SetWorkflowOutput activity

* Update designer version
2023-02-21 21:15:09 +01:00
Sipke Schoorstra 1d1808af89
Workflow input/output (#3726)
* Improve activity JSON converter

Handles wrapped and unwrapped input

* Add SetWorkflowOutput activity

* Implement handling of child workflow output
2023-02-21 11:47:20 +01:00
Sipke Schoorstra 5f6454b59c
Workflow as Activity - input/output (#3699)
* Restructure component folders

* Restructure JavaScript module folders

* Remove ActivityType field from descriptor 

No longer necessary.

* Incremental work on synthetic properties

* Implement synthetic property persistence

* Add JS functions to return input from composed activity

* Cleanup

* Take into account versioning

* Fix versioning

* Add Output management

* Implement output handling
2023-02-13 12:15:20 +01:00
Sipke Schoorstra 0dd3e2bad8
Tweaks and fixes (#3672)
* Various additions and tweaks

* Fix WriteHttpResponse when no content type provided

* Bump designer version

* Return when sending response

* Remove faulty validation
2023-02-03 14:29:44 +01:00
Sipke Schoorstra 11b684274c Add variable types to Type Definition output 2023-01-31 11:01:39 +01:00
Sipke Schoorstra 64ceb843d0 Fix tests 2023-01-31 10:50:32 +01:00
gurkanguran 407bfa6913
Use workflow definition as activity (#3654)
* Implemented usage of workflow definitions as activities

* Updated designer

* Removed activity definitions module

* Allow user to mark workflow to be used as activity

* Refactor

* Refactor

* Cleanup csproj

* Cleanup WorkflowDefinitionActivity

* Pascalize typename

* Fix JS intellisense initial load issue

* Add XML comments

* Add Jobs dependency

* Hide Composite root port from designer

* Move finding workflow activities logic to lower level

* Generate unique identities across hierarchy

* Refactor

* Revert "Generate unique identities across hierarchy"

This reverts commit 74f5e7830309ee76af6ab3a000a5e1ec41f1e90c.

* Implement unique node IDs

* Introduce new VersionOptions option

* Remove unused namespaces

---------

Co-authored-by: Sipke Schoorstra <sipkeschoorstra@outlook.com>
2023-01-28 00:36:03 +01:00
Sipke Schoorstra fe845e65e7 Fix JsonObject type handling 2023-01-25 11:46:07 +01:00
Sipke Schoorstra 2697f512e9 Implement XML content writer 2023-01-24 22:39:31 +01:00
Sipke Schoorstra e3deafedf3 Add toJson JS function
The Jint implementation of JSON.stringify only supports a limited set of objects (not .NET LocalDate for example)
2023-01-20 19:26:38 +01:00
Sipke Schoorstra 354781e193 Rename Activity to CodeActivity and ActivityBase to Activity 2023-01-19 21:49:24 +01:00
Sipke Schoorstra 28e9922060
JavaScript intellisense (#3639)
* Incremental work

* Incremental work

* Incremental work

* Initial support for intellisense

* Implement variable type definition provider
2023-01-19 14:09:58 +01:00
Sipke Schoorstra 8ccc20722c
Fix tool buttons (#3604)
* Fix tool buttons
2023-01-06 20:00:03 +01:00
Sipke Schoorstra 750c2094cc
RunTask activity (#3594)
* Implement RunTask activity
2023-01-04 20:36:38 +01:00
Sipke Schoorstra 7a98cdf60d
Normalize extensions namespaces (#3577) 2022-12-31 16:16:43 +01:00
Sipke Schoorstra 01c70e5563 Update docker things 2022-12-30 19:29:34 +01:00
Sipke Schoorstra e6536636d7
Additional samples + fixes and improvements (#3574)
* Incremental work on samples

* Rename HTTP middleware and update samples

* Rename HTTP Activities to Workflows

* Automatically register core activities when adding Elsa

* Fix feature registration bug

* Add default auth feature

* Make activity serializer more flexible

* Bump designer version

* Add workflow server + designer samples

* Simplify EntityFrameworkCore projects

* Update solution

* Add Sqlite package references to ensure the correct version is used

* Update sample project with EF Core

* Update EF extensions

* Add server + designer sample project

* Cleanup AllInOne project and add some XML comments

* Rename ci.yml and add CI for Docker file
2022-12-30 13:11:29 +01:00
Sipke Schoorstra bbe8ee34c0 Update packages 2022-12-22 15:55:20 +01:00
Sipke Schoorstra 2dcd9bcd73 Add .NET 7 as a target 2022-12-22 15:40:31 +01:00
Sipke Schoorstra 764cd6187b
Fix workflow navigation (#3541)
* Incremental work

* Reimplement flowchart navigation

* Fix activity property editing

* Fix workflow property editor

* Fix designer lookup upon new activity added

* Restore Variables context

* Add Start event

* Add XML comments to WriteLine

* Implement variable getter and setters for JS
2022-12-15 22:53:56 +01:00
Sipke Schoorstra 026430fd2d
Composite Activity fixes and improvements (#3512)
* Implement consistent input/output/variable memory block identifiers

* Telnyx fixes and improvements

* Fix bookmark burning

* Refactor AnswerCall

* Incremental work on source + line registration

* Handle missing bookmarks

* Fix bookmark persisted callback mechanism

* Implement distributed locking for default workflow runtime

* Fix recording bookmark

* Increase source file and line coverage
2022-12-07 20:47:36 +01:00
Sipke Schoorstra c70247e133 Fix memory referencing and some other stuff 2022-12-02 22:57:26 +01:00
Sipke Schoorstra 1f3b849e68
Add JS functions (#3492) 2022-11-30 21:52:41 +01:00
Sipke Schoorstra 6f429e9867
Add support for accessing workflow variables from liquid expressions (#3491) 2022-11-30 21:20:25 +01:00
Sipke Schoorstra e4647affe1 Configure RunJavaScript to use javascript language for Monaco editor 2022-11-28 19:12:01 +01:00
Sipke Schoorstra 9dcae97a0e Add support for lazy initialization of output 2022-11-20 20:37:56 +01:00
Sipke Schoorstra 660cfbfd05 Update DB context class names and create SQL Server provider 2022-11-20 19:00:03 +01:00
Sipke Schoorstra 8cc8d1bcbf
Telnyx integration (#3453)
* Incremental work on Telnyx integration

* Incremental port of Telnyx activities

* Fix polymorphic JSON serialization for webhook data

* Fix IsFirstPass logic

* Fix trigger base to prevent activity auto completion

* Temporarily disable persistent snapshotting provider for testing

* Fix namespaces

* Add method to register activities in bulk using marker type

* Fix Telnyx refit client setup

* Register all Telnyx activities by default

* Incremental work on webhook driven resumption and correlation

* Incremental work on post-bookmark signaling

* Fix bookmark resolution

* Include correlation ID with bookmark

* Fix Telnyx resumption input

* Replace bookmark persisted signal with handler

* Fix SpeakText completion

* Add flow outcomes to SpeakText activity

* Update GatherUsingSpeak and GatherUsingaudio

* Refactor "is first pass" concept

* Fix WebhookEvent activity

* Add HTTP absolute URL provider

* Formatting and small changes

* Various API enhancements
2022-11-19 22:30:43 +01:00
Sipke Schoorstra 3bed8b970b Fix package tags 2022-11-11 21:25:14 +01:00
Sipke Schoorstra e9d4c9b6d5 Prepare projects for packaging 2022-11-03 21:40:23 +01:00
Sipke Schoorstra 31942ae96f
Implement async workflow state exporter for DB workflow instance (#3291)
* Incremental work on in-process message consumers

* Implement asynchronous workflow state DB exporter

* Fixes
2022-09-07 17:28:36 +02:00
Sipke Schoorstra 4ed7f4b5da
Designer Activity Definitions (#3221)
* Incremental work on custom activities

* Incremental work on refactoring versioned entities

* Add ActivityDefinition infrastructure

* Incremental work on activity definition manager

* Incremental work on API endpoints

* Refactored flowchart component to include hierarchical nav

* Incremental work on modularization of designer component

* Restructuring into modules

* Rename CustomActivities module

* Apply security

* Fix activity definition GET endpoint

* Incremental work on activity definition provider

* Incremental work on activity definition execution

* Update ActivityDefinitionMaterializer.cs

* Update ActivityDefinitionActivityProvider.cs

* Add activity definition referenced version update handler

* Maintain position of not found activity

* Fix prefix naming
2022-07-21 16:18:42 +02:00
Sipke Schoorstra 4ac74864cd Incremental work on transposition 2022-06-14 15:56:41 +02:00
Sipke Schoorstra e67e40bd7b Incremental work on persistent variables 2022-06-06 15:49:54 +02:00
Sipke Schoorstra 17f7e4d58d Update JintJavaScriptEvaluator.cs 2022-06-04 20:21:29 +02:00
Sipke Schoorstra ea40b05a6b Simplify memory API names 2022-06-04 20:03:40 +02:00
Sipke Schoorstra 1fc93afcb2 Rename Memory to MemoryBlocks 2022-06-04 20:02:59 +02:00
Sipke Schoorstra 951149b5d4 Improve memory API 2022-06-04 20:01:20 +02:00
Sipke Schoorstra 2563406a7d Renaming register API and introduce hierarchical memory register 2022-06-04 18:52:58 +02:00