This commit modifies the branch verification procedure in the GitHub workflows file. The code now includes a condition that checks if the event is a release that has been published before proceeding with fetching from the main branch. For other cases, the procedure remains the same, with fetching taking place from the referenced branch.
* Refactor search filtering and move ListWorkflowDefinitionsRequest file
Updated the searching mechanism in `WorkflowDefinitionFilter.cs` by validating that Name and Description are not null before performing the search. In `ListWorkflowDefinitionsRequest.cs`, the file was moved from the Responses namespace to Requests and a new property `SearchTerm` was added, allowing filtering of workflow definitions by their name, ID or description.
* Update code style settings for csproj
The .DotSettings file for the project has been adjusted with changes to code naming rules and settings migration. These modifications adjust policies for naming conventions of Instance and Static fields, enhancing code style conformance. Also, an additional settings migration rule has been applied.
* Add 'issue/*' branch to GitHub actions workflow
The GitHub actions workflow has been updated to include the 'issue/*' branch. This ensures that any changes made in the 'issue/*' branches will trigger the workflow and any associated tests or builds, improving the overall continuous integration process.
* Remove Skip and Take methods from SqlServerDialect
The mentioned functions have been removed from SqlServerDialect class in the Elsa.Dapper module. The base class provides the correct default implementation for the SQL Server dialect.
The GitHub Actions configuration has been updated to also trigger on Push events and Workflow Dispatch events. OnPushBranches and OnPullRequestBranches now also include branches prefixed with 'feature', 'patch', 'fix', and 'enhancement'. This is reflected in both the Build.CI.GitHubActions.cs file and the packages.yml GitHub workflow.
The updates in this commit refine the way branch names and package prefixes are determined in the GitHub workflow for package building. Moreover, the workflow now recognizes and supports additional branch patterns, including 'patch/*' and 'preview/*', extending the existing support for 'main' and 'feature/*' branches.
The commit message updates the branch names in the packages.yml GitHub workflows file by enclosing them in single quotes. The change is done on both 'main' and 'feature/*' branches.
This update modifies the GitHub packages workflow. 'issue/*' and 'bug/*' branches were removed from the workflow trigger, and branch name handling logic updated. Now, if the branch name is 'main', the version is labeled as 'preview'. Otherwise, the branch name is used.
This update modifies the GitHub workflow in packages.yml for improved branch name extraction and more accurate commit verification. It provides more feedback by outputting the extracted branch name, and checks for commits in the specific branch rather than in 'origin/dispatch-channels'.
Expanded GitHub action to now trigger on push events for feature/*, issue/*, and bug/* branches. The workflow has been modified to fetch the name of the current working branch, check if the commit exists on that branch, and append it to version number. This will effectively allow isolated workflows for each specific branch.
* Improve Elsa workflow expression serialization
Added serialization support for expressions in Elsa workflows, enabling serialization and deserialization to maintain consistent types across sessions. Updated relevant test cases for validation.
* Remove PR workflow from GitHub actions
The PR workflow has been removed from GitHub actions.
The GitHub Actions workflow has been updated to focus on the v3.0.2 branch instead of the main branch. As part of this change, the verification step and VERSION setting have been adjusted to reflect the new branch name.
The previous text had a typographical error in the workflow name in the Elsa Studio GitHub workflow configuration. The updated version has the proper spelling for the Elsa Studio reference application.
The branch reference in the packages.yml workflow file has been updated. We are no longer verifying commits against origin/v3.1.0, and instead verifying them against origin/main. This change aligns with the latest naming convention
This commit updates the Github Actions CI/CD workflow to track changes from the main branch instead of branch v3.0.1. It changes actions in package.yml to fetch, verify commits, and grep in the 'main' branch.
* Update packages.yml for version 3.0.1
The packages.yml workflow file has been updated to target the v3.0.1 branch instead of main. The version also has been updated from 3.0.0 to 3.0.1 in the version prediction logic. Hotfix tags usage has been removed.
* Update git branch for commit verification in workflow
The Github workflow's step for verifying commits' existence has been updated. Instead of searching in the 'origin/main' branch, the workflow now checks in the 'origin/v3.0.1' branch. This modification ensures compatibility and consistency with the version being used.
* Update Elsa.Studio package versions
The Elsa.Studio and Elsa.Studio.Login.BlazorWasm packages in the Elsa.ServerAndStudio.Web and Elsa.Studio.Web projects have been updated from version 3.0.0-preview.177 to the stable version 3.0.0. This is to ensure we're using the stable and reliable versions of these packages in our projects.
* Add background execution to activities and update HTTP requests
Significantly enhanced the capabilities of background execution of activities. Included a change in activity type of "SendHttpRequest" from 'Task' to 'Action'. Introduced new classes for handling outcomes of context in background execution. Made some necessary adjustments to HTTP Request Task to handle sending HTTP requests from a background task. Updated several middleware classes to align with these modifications.
* Add background execution handling to activity context
This commit adds the ability to manage the background execution state directly within the activity execution context. This includes adding methods to set and verify the background execution state, and modifying the existing code to use these new methods. A method for handling activity scheduling during background execution has also been started, but its implementation is not finished yet. The HTTP Request activities were updated accordingly to reflect these changes.
* Add scheduling function for background activities
This commit achieves two main goals. Firstly, it introduces two new classes called ScheduledActivity and ScheduledActivityOptions to store scheduled activities' information. Secondly, it modifies how activities are executed in the background by capturing the scheduling information as a serializable format and storing it in the workflow execution context properties dictionary. This change allows the workflow execution context to resume the activity execution context.
* Refactor HTTP request handling by removing SendHttpRequestTask
SendHttpRequestTask was deleted and its functionality was merged into SendHttpRequestBase. This consolidation led to the addition of StatusCode and ResponseHeaders output fields in SendHttpRequestBase. Another change includes the update in FlowSendHttpRequest to indicate that it's no longer deprecated. Also, HttpHeaders class was extended to accommodate HttpResponseHeaders objects. The consolidation was done to streamline the HTTP request handling process.
* Update GitHub Actions workflow for new release
The GitHub Actions workflow configuration has been updated to target the '3.0.1' branch instead of 'main'. Furthermore, the preview version set in the workflow has been updated to '3.0.1-preview', changing from the previous '3.0.0-preview'.
* Update branch verification in GitHub workflow
The GitHub workflow configuration has been updated to verify that the commit exists in the branch 'origin/3.0.1' instead of 'origin/main'. This is done during the automated package generation process.
* New options to control retry logic for transient failures (#4750)
* Add an option to control the number of automatic retries for transient failures.
* Add SleepDurationProvider option for ElsaClientBuilderOptions
---------
Co-authored-by: admin <admin@admin.com>
* Add IExecuteWorkflowApi interface and refine retry policy configuration
A new interface, IExecuteWorkflowApi, was created to handle execution and dispatch of workflow definitions. This breaks down functionalities previously present in IWorkflowDefinitionsApi. Also, the retry policy configuration for HTTP requests has been refactored. Instead of hardcoding retry settings, now a delegate method can be optionally passed to customize the behavior. This makes it more flexible and shifts the responsibility of configuring retry policies to the client.
* Add option for synchronous broadcast in WorkflowInbox
This update introduces a new option to control synchronicity when broadcasting messages in the WorkflowInbox. The 'BroadcastWorkflowInboxMessageOptions' class allows the developer to specify whether the broadcasting will occur synchronously or asynchronously. The update also includes a new Endpoint and Workflow for demonstration and testing of this functionality.
* Update FastEndpoints packages to version 5.21.2
The current commit updates the version of all FastEndpoints packages from 5.20.1.7-beta to 5.21.2 in the 'Elsa.Api.Common' project. This ensures we are using the most recent stable release of these packages.
#4747
* Add decimal check in PolymorphicObjectConverter
In the PolymorphicObjectConverter class, the check for primitive types and specific object types was updated to include decimal.
Fixes#4714
* Refactor Dapper workflow and update migrations
Modified the store service to optimize the SaveManyAsync method by converting input to list only once. Also, enhanced deletion query in the store service to enable usage of different primary keys. Made changes in the Dapper migrations, replacing "NodeId" with "ActivityNodeId".
* Update workflow to use main branch and version 3.1.0
The workflow has been updated to work with updates on the 'main' branch rather than the 'v3.0.1' branch. Also, the version number for the 'VERSION' variable in preview mode has been updated to 3.1.0 from 3.0.1.
* Remove unnecessary Elsa Server activities
Deleted sample files: DataSourceActivity, MyEndpoint, and MyEventWorkflow from the Elsa Server Web bundle as part of our ongoing codebase optimization strategy. These files were no longer required and their removal simplifies our code structure.
* Update package workflow to reference v3.0.1
The GitHub actions workflow has been updated to pull from branch v3.0.1 instead of main. This change affects the commit verification and version setting steps, now using version 3.0.1-preview in the workflow process.
* Update Elsa.Studio packages to version 3.0.1-preview.196
This commit involves updating the versions of `Elsa.Studio`, `Elsa.Studio.Core.BlazorWasm`, and `Elsa.Studio.Login.BlazorWasm` packages in `Elsa.ServerAndStudio.Web.csproj` and `ElsaStudioWebAssembly.csproj` files to 3.0.1-preview.196. This update will incorporate the new changes and improvements included in this newer version.
* Update Elsa.Studio package versions
The Elsa.Studio and Elsa.Studio.Login.BlazorWasm package versions have been updated in the Elsa.Studio.Web project. Both package versions have been upgraded from 3.0.0 to 3.0.1-preview.196.
* Remove unused Workflow models and simplify AddStorageDriver method
The commit removes BackgroundExecutionOutcome and BackgroundExecutionResult models from Elsa.Workflows.Core, as they are no longer in use. Additionally, it simplifies the AddStorageDriver extension method in ModuleExtensions.cs, now it directly adds the service as an implementation of the IStorageDriver interface.
* Remove unnecessary dependencies in DefaultBackgroundActivityInvoker
Dependencies on IBookmarksPersister and IWorkflowStateExtractor have been removed in the DefaultBackgroundActivityInvoker.cs file. Additionally, an unused `using` statement for Elsa.Workflows.Helpers has been eliminated. This commit aims to declutter the code and increase its maintainability by eliminating unnecessary dependencies.
---------
Co-authored-by: Night Wu <lofrank@outlook.com>
Co-authored-by: admin <admin@admin.com>
The GitHub actions workflow has been updated to pull from branch v3.0.1 instead of main. This change affects the commit verification and version setting steps, now using version 3.0.1-preview in the workflow process.
The workflow has been updated to work with updates on the 'main' branch rather than the 'v3.0.1' branch. Also, the version number for the 'VERSION' variable in preview mode has been updated to 3.1.0 from 3.0.1.
The Github workflow's step for verifying commits' existence has been updated. Instead of searching in the 'origin/main' branch, the workflow now checks in the 'origin/v3.0.1' branch. This modification ensures compatibility and consistency with the version being used.
The packages.yml workflow file has been updated to target the v3.0.1 branch instead of main. The version also has been updated from 3.0.0 to 3.0.1 in the version prediction logic. Hotfix tags usage has been removed.
* Feature/change singleton to scope (#4635)
* feat(scoped): move dependencies to scoped instead of singleton if possible.
* fix(scoped): Timer and LiveTest
* fix(scoped): change scope of python and csharp features
* fix(scoped): remove FireAndForgetStrategy and replace if by BackgroundStrategy
* fix(scoped): add .editorconfig to avoid changing the sort order of using (system.* first) and fix the scope in BackgroundEventPublisher
* Update title in README.md
The README.md file has been updated to reflect the new version of Elsa - Elsa 3.0.
* Remove npm-packages workflow, adjust branch triggers in workflows
The npm-packages.yml workflow has been removed. The branch triggers in the workflows npm-packages.yml, packages.yml, and all-in-one-web.yml have been changed from 'v3' to 'main'. An unnecessary reference to the deleted workflow file npm-packages.yml is also removed from Elsa.sln.
* Remove obsolete files from designer packages
Numerous unused and obsolete files have been removed from various designer packages including angular-workspace, elsa-workflows-designer, react-workspace, and others. This cleanup enhances the maintainability of the project by eliminating unnecessary files and reducing clutter.
* Add badges to README.md
The README.md file has been updated to include badges for packages, continuous delivery, and discussions related to Elsa workflows. These badges provide quick access to key information and resources like Nuget, npm, GitHub Actions, feedz.io, Docker, Discord, Stack Overflow, and subreddit subscribers.
* Update README with enhanced instructions for Elsa server and studio
The README updates include specific instructions for running the Elsa server on port 5001 and the Elsa studio application on port 6001. These enhanced guidelines provide comprehensive steps for configuring the applications regarding authentication, module usage, and use of API endpoints.
* Add IsWorkflowDefinitionActivity method to ActivityExtensions
A new method, GetIsWorkflowDefinitionActivity, has been added to the ActivityExtensions class. This method checks a given JsonObject representing an activity to determine if it's a workflow definition activity. It returns true if the activity indeed is; otherwise, it returns false.
* Refactor MassTransit & AzureServiceBus configuration and delete unnecessary options
AzureServiceBusOption.cs and RabbitMqOptions.cs files were removed as they're no longer needed. The system now defers the configuration of MassTransit and AzureServiceBus to the application layer (Program.cs). The configuration for PrefetchCount is also allowed at the transport-level. A new abstraction, ConsumerTypeDefinition, collects all the consumer types with their respective definitions if provided. Adjustments have been made in related extension methods and classes to reflect these changes.
* Enhance configuration options for MassTransit
This commit enhances the configuration options for the MassTransit integration, providing additional settings for both Azure Service Bus and RabbitMq. It also refines the MassTransit workflow dispatcher configuration by allowing for custom dispatcher options. A default RabbitMq connection string has been added to the appsettings.json.
* Renamed AI file
* Update Elsa.Studio package versions
The package references for Elsa.Studio, Elsa.Studio.Core.BlazorWasm, and Elsa.Studio.Login.BlazorWasm in Elsa.AllInOne.Web and ElsaStudioWebAssembly projects were updated. The version has been changed from 3.0.0-preview.160 to 3.0.0-preview.164 to incorporate the latest features and bug fixes.
* Reorganize README and add Docker instructions
The README file was reorganized to make it more readable by grouping related badges together. Additionally, instructions on how to start the Elsa Docker container were appended for users who want to quickly try out the Elsa Studio and Elsa Server.
* Update description in README.md
The current diff modifies the description of the Docker image in the README file. The revised description consolidates information about the image, its reference ASP.NET application nature, and its non-production intention into a single, more succinct sentence.
* Add tests for implicit joins and fix duplicate activity scheduling
This commit includes new integration tests for implicit join scenarios. The tests ensure that join and parallel join activities execute correctly and complete as expected. Additionally, a change has been made to the workflow execution context to prevent duplicate activity scheduling. Now, aside from checking if the activity is already scheduled, it also checks if the activity is scheduled for the specified owner.
Fixes#4703
* Add ExpressionEvaluatorOptions to JavaScriptEvaluator
The JavaScriptEvaluator now accepts an options parameter of type ExpressionEvaluatorOptions. This allows adding custom arguments to the evaluation context. An 'Empty' static instance of ExpressionEvaluatorOptions is added for convenience. Additionally, the usage of MassTransitAzureServiceBus in Program.cs is turned off by setting the flag to 'false'.
* Update README to add access information when user tried to run elsa with docker (#4708)
* [no ci] add link to Elsa 2 in README
* Remove Console and ASP.NET examples, simplify README.md
Simplified README.md by removing in-depth Console and ASP.NET Core examples, as well as mentions about building from source, serving overall clarity and readability. Added descriptions for coded and visual workflow design possibilities.
* Implement batch processing in BulkDispatchWorkflows
The changes introduce a batch processing mechanism in the BulkDispatchWorkflows activity. Previously, each workflow was dispatched individually. Now, the process groups the workflows in batches, processes each batch concurrently, and handles errors. This change improves performance, particularly for large data sources.
* Refactor workflow methods for async execution
Modified methods in the WorkflowInstance.cs to implement re-entrant approach for asynchronous execution. This is achieved by replacing 'await' with task-based calls passed through the Context.ReenterAfter method, providing more efficient non-blocking operations. Minor changes were also made in ClusterExtensions.cs and ProtoActorWorkflowRuntime.cs, including code clean up and slight modifications to maintain consistency.
* Refactor background activities scheduling
Background activities scheduling was moved to its own middleware where the actual scheduling happens instead of in the invoking middleware. Removed ScheduleBackgroundActivities.cs handler and added ScheduleBackgroundActivitiesMiddleware.cs instead. As a part of this change, restructured BackgroundActivityInvokerMiddleware to BackgroundActivityCollectorMiddleware, and updated all relevant references.
Minor modifications to a few other files include changes in their package dependencies and activity kind settings.
* Change ActivityKind from Job to Task in BulkDispatchWorkflows
The ActivityKind property in BulkDispatchWorkflows class has been changed from Job to Task. This updates the type of activity associated with the BulkDispatchWorkflows process within the Elsa workflow runtime module.
* Update BulkDispatchWorkflows activity
The BulkDispatchWorkflows.cs activity in Elsa.Workflows.Runtime module has been updated with some key changes: Added detailed description to the input element, introduced the dispatchedInstancesCount to accurately track the number of instances dispatched, and removed some unnecessary white spaces for improved readability.
* Add methods to handle activity run asynchronously flag
New methods have been added to handle the custom property 'runAsynchronously' on a JsonObject activity. These methods will help in getting and setting a value that indicates whether a specified activity can trigger a workflow asynchronously. This additional level of control can enhance workflow execution based on specific requirements.
* Add 'Persister' to UserDictionary in DotSettings
The new dictionary entry for 'Persister' has been added to Elsa.sln.DotSettings. This expands the vocabulary of the solution's user dictionary and ensures that 'Persister' is recognized as a valid term within the project context.
* Add Bookmark Persister and Bookmark Updater
The code introduces BookmarkPersister for processing bookmarks as part of the workflow runtime. This refactoring improves readability and maintainability by separating the bookmark persisting logic from the PersistBookmarkMiddleware class. A new class, BookmarkUpdater, is also added to handle updating of bookmarks. Changes also include adjustments to several other classes for improved functionality and code consistency.
* Add bookmarks processing to DefaultBackgroundActivityInvoker
The code addition includes two dependencies, IBookmarksPersister and IWorkflowStateExtractor, in the DefaultBackgroundActivityInvoker service. With these changes, during the workflow execution phase, bookmarks are captured and processed for any state changes. These modifications provide more control and efficiency over handling workflow states during the system's background operations.
* Update workflow handling and simplify codebase
Refactored the workflow handling logic and simplified numerous components in the codebase. Major changes include the enhancement of the Workflow Runtime handler, altering the broadcast and deliver functions in the Default Workflow Inbox, and the removal of unnecessary details in the Workflow Runtime feature. Also, unnecessary services and requests were removed for better code efficiency and readability.
* Add conversion support for long type in ObjectConverter
The ObjectConverter file has been updated to support conversion of 'long' type. This is done by adding an additional conditional statement for checking the underlying source type for 'long', then returning the converted value.
* Add 'Noop' method to WorkflowExecutionContext
A Noop method has been added to the WorkflowExecutionContext, and is now assigned to the ExecuteDelegate field when no resumption point is specified. The change, will prevent the invocation of the regular "ExecuteAsync" method, closing the activity without additional operations.
* Add AutoComplete option to workflow bookmarks
The AutoComplete option has been added to the workflow bookmarks, which determines whether the activity should automatically be completed if no callback is specified. This change improves the flexibility of bookmark creation and impacts various workflow elements and procedures. The corresponding adjustments have been made at functions where bookmarks are used or created.
* Refactor object initialization in ActivityExecutionContext
Refactoring was performed in the ActivityExecutionContext class to use object initializers for readability and clarity. This modification mainly targets the CreateBookmark and ScheduleActivityAsync methods, making their code more explicit and thus easier to understand.
* Refactor code for readability and improved logging
Code in several activity files and Worker.cs that involve creating bookmarks and handling messages received was refactored to improve readability and clarity. The instantiated "CreateBookmarkArgs" parameter was split into its individual arguments for improved readability. Logging in the Worker.cs file was also fine-tuned, with explicit count of workflows triggered by service bus messages being included in the debug log.
* Refactor code structure for ServiceBus Integration tests
Refactored the ServiceBus Integration tests for improved readability and maintenance. The changes included reducing the number of lines by removing unnecessary curly braces, removing unnecessary use of 'this' qualifier, replacing null checks with null-conditional operators, and organizing various code blocks for better understanding.
* Remove specific activity instance bookmarks
The change clears specific activity instance bookmarks in the context from the WorkflowExecutionContext. This is an extra step in the process of clearing bookmarks, which assists in managing and cleaning up workflow state effectively.
* Update Elsa.Studio.Login.BlazorWasm version
The version number of Elsa.Studio.Login.BlazorWasm has been updated in the Elsa.AllInOne.Web.csproj file. This change reflects the newest release, moving from version 3.0.0-preview.164 to 3.0.0-preview.167.
* Update artwork
* Implement pagination for activity descriptor fetching
Updated the WorkflowDefinitionActivityProvider code to fetch activity descriptors in a paginated manner. This change will be useful to avoid overloading system resources when interacting with large amounts of data. It retrieves a limited number of descriptors per request, looping until all are fetched.
Closes#4689
* Refactor task payload extraction and update workflow builder
Modified the way task payload is extracted in the OrderFoodTaskHandler.cs for more robustness. The input parameter of the workflow builder in the HungryWorkflow.cs file has also been refactored for efficiency. Making these tweaks streamlines management of values within the tasks.
* Update localhost port for workflow sample
The localhost port for the Elsa.Samples.AspNet.RunTaskIntegration has been updated from 7211 to 5001 in both the run-workflow.http and launchSettings.json files. This adjustment ensures that the workflow sample correctly points to the new localhost port, maintaining synchronization within the application.
* Refactor ExpressionExecutionContextExtensions module
Modified the GetInput methods to consider the case where the method is called within a composite activity, ensuring that only local variables have precedence over workflow input when executing within a composite activity.
* Feature HTTP Activity : Allow adding Authorization Header without validation (#4721)
* Add capability to add Authorization Header without validation
* Refactor authorization header handling in HTTP requests
This commit simplifies the syntax for input attributes in the SendHttpRequestBase.cs module. It also renames the boolean value `AddAuthorizatonHeaderWithoutValidation` to `DisableAuthorizationHeaderValidation` for more clarity. This change improves code readability and understanding in relation to handling authorization headers in HTTP requests.
---------
Co-authored-by: Jérémie DEVILLARD <jdevillard@users.noreply.github.com>
Co-authored-by: Sipke Schoorstra <sipkeschoorstra@outlook.com>
* Add a more generic UIHandler to customize how inputAttributes can be handle by UI (#4688)
* add a more generic UIHandler to customize how inputAttributes can be handle by the ui
* Add IPropertyUIHandlerResolver and update PropertyUIHandlerResolver
Introduced a new interface, IPropertyUIHandlerResolver, to resolve UI options for a property. Refactored PropertyUIHandlerResolver to implement this interface and removed the unnecessary partial class structure. Also, cleaned up some unnecessary usings in various files for better code organization.
* Refactor variable name and description in InputDescriptor
The 'uISpecifications' variable in the InputDescriptor model is renamed to 'uiSpecifications' for better readability. Additionally, the associated comment was revised to explain that the dictionary is used by the UI.
* "Refactor codebase for improved organization and cleaner architecture"
The codebase has been significantly refactored, moving several classes to more appropriate namespaces for improved organization and cleaner architecture. This includes shifting UI hint handlers, activities, and memory-related components, amongst others. The changes should improve code readability and maintainability, but as this is a broad refactoring effort, thorough regression testing is advised.
* Add CheckList UIHint with associated handler and provider
This update introduces a new UIHint called CheckList to the Elsa.Workflows.Core. This includes the necessary handler and provider classes. The handler is registered in the WorkflowsFeature.cs, and the CheckList UIHint key has been added to the InputUIHints.cs. Various associated files have been created in both the Elsa.Api.Client and Elsa.Workflows.Core project to support this new UIHint.
---------
Co-authored-by: Jérémie DEVILLARD <jdevillard@users.noreply.github.com>
Co-authored-by: Sipke Schoorstra <sipkeschoorstra@outlook.com>
* Update GitHub actions for packages publishing
This update changes the trigger for the package publishing action to only 'published' releases and prereleases. It also segregates the publishing mechanism into two separate actions: one for publishing preview packages to nuget.org, and another for publishing release packages. This change provides better clarity and control over the publishing process.
* Update FastEndpoints package and enable JWT Bearer Auth
The FastEndpoints package was updated to '5.20.1.7-beta' from '5.20.0-rc1'. Enabling JWT Bearer Authentication was also set from 'false' to 'true' in the SwaggerExtensions file. Removed conditions that were limiting the addition and usage of Swagger to .NET 6.0 or 7.0, which allows the Swagger to be used in any environment.
* Refactor input output assignment and JSON converter
The code has been updated to provide clear and meaningful block reference names using the Humanizer library in the IdentityGraphService. The redundancy in assigning input/output Id's in both IdentityGraphService and InputJsonConverter has also been removed, resulting in cleaner, less convoluted code.
* Enhanced script language support in Elsa.AllInOne.Web
This update introduces expanded language support in Elsa.AllInOne.Web. The changes allow CLR access in JavaScript, and also introduce the ability to use both C# and Python. The changes also include adding project references for the C# and Python modules.
* Add logging to PythonGlobalInterpreterManager
Implemented logging in the PythonGlobalInterpreterManager class to ensure visibility during Python engine initialization and shutdown. These changes are important for spotting errors, troubleshooting issues, and understanding potential failures in Python engine initialization.
* Refactor project structure and Docker configurations
The changes included in this commit are made to refactor the project structure and Docker configurations. Previously, the application was structured around the AllInOneWeb solution, but it has been split into Server.Web and ServerAndStudio.Web solutions for better separation of concerns. Additionally, the Docker configurations have been updated to reflect the new structure, which should streamline the build and deployment process.
* Add GitHub Actions workflows for Elsa Docker images
This commit introduces two new GitHub Actions workflows: one for building and deploying the Elsa Server + Studio Docker image, and another for the Elsa Server Docker image. Both processes automate the build and push actions to Docker Hub using the latest ubuntu version and buildx for multi-platform support.
* Update Dockerfiles and add Python 3.11
Working directories in both ElsaServer.Dockerfile and ElsaServerAndStudio.Dockerfile have been updated for better consistency. Additionally, Python 3.11 has been installed in the ElsaServer.Dockerfile, accompanied by relevant environment variables and symbolic links to improve interoperability.
* Update Dockerfiles for Python 3.11 installation
Added lines in Dockerfiles to install Python 3.11 and set the PYTHONNET_PYDLL environment variable. This enhancement helps to ensure compatibility with recent Python updates and improves general performance.
* Add Elsa.Studio.Web project to the solution
A new project, Elsa.Studio.Web, was added to the solution which included adding appropriate configuration files, host pages, project settings and important dependencies. Necessary adjustments were also made in Elsa.ServerAndStudio.Web.csproj to match with the latest updates.
* Add Docker build script for Elsa Studio
This commit introduces a Dockerfile for the Elsa Studio application and a corresponding GitHub workflow for building and deploying the Docker image. These make it possible to automatically build and deploy Elsa Studio as a Docker image.
* Update Elsa.Studio package versions
Updated the version of Elsa.Studio and Elsa.Studio.Login.BlazorWasm from '3.0.0-preview.169' to '3.0.0-preview.170' in Elsa.Studio.Web and Elsa.ServerAndStudio.Web projects. This is to keep the dependencies up to date and leverage any enhancements or bug fixes in the new version.
* Update Elsa.Studio packages to version 3.0.0-preview.171
The Elsa.Studio and Elsa.Studio.Login.BlazorWasm packages are updated from version 3.0.0-preview.170 to 3.0.0-preview.171 in both Elsa.Studio.Web and Elsa.ServerAndStudio.Web projects. The updated packages include satisfying the latest enhancements and bug fixes.
* Update Elsa.Studio package versions
The Elsa.Studio package versions in ElsaStudioWebAssembly project have been updated from "3.0.0-preview.164" to "3.0.0-preview.171". The packages include Elsa.Studio, Elsa.Studio.Core.BlazorWasm, and Elsa.Studio.Login.BlazorWasm.
* Add CodeEditorOptions, EditorHeight, and MultiLineOptions classes
This commit introduces three new classes to the CodeEditor namespace. CodeEditorOptions provides various configuration options for the code editor while EditorHeight defines available height options. MultiLineOptions is specifically built for managing multi-line editor settings.
* Update Elsa.Studio packages to version 3.0.0-preview.172
The packages Elsa.Studio, Elsa.Studio.Login.BlazorWasm and Elsa.Studio.Core.BlazorWasm have been updated to version 3.0.0-preview.172 in the Elsa.Studio.Web, Elsa.ServerAndStudio.Web, and ElsaStudioWebAssembly projects.
* Add non-generic GetVariable method and Python accessors
A non-generic version of GetVariable method has been added to the ExecutionContextProxy.cs, allowing direct access to variables without specifying a type. To leverage this, Python accessors for getting and setting workflow variables have been added to GenerateWorkflowVariableAccessors.cs. This enhances the interaction between the Python scripts and the context variables.
* Add UI hints to input fields in workflow core modules
Changed a number of instances in both activities and UI Hints classes across multiple modules in the workflow core to utilize UIHints. The UI hint "DropDown" has been added to relevant input fields to improve the user interface. Special handling for Enum properties in the drop-down options provider has also been created.
* Update HTTP endpoint authorization handler
The default authorization handler for HTTP endpoints is now the AuthenticationBasedHttpEndpointAuthorizationHandler instead of the AllowAnonymousHttpEndpointAuthorizationHandler. The configuration was updated in HttpFeature.cs and the override in Program.cs was removed. This provides more security to HTTP endpoints by requiring authentication.
* Add JSON editor UI hint to HTTP activities
This commit introduces a JSON editor UI hint to HTTP activities within Elsa Workflow. It includes creating new classes for a JSON editor options provider and a handler for this UI hint. Also, these additions are registered within the Elsa Workflow. The hint is applied to the 'RequestHeaders' and 'ResponseHeaders' input fields found in HTTP-related activity classes.
* Add UI hints for HTTP endpoint and single line fields
Introduced HttpEndpointPathUIHandler to provide additional UI options for the Path input field in the HTTP Endpoint activity. This commits also adds SingleLineProps to offer more options for SingleLine input fields across different modules. The implementation improves UI component interactions.
* Update Elsa.Studio packages to version 3.0.0-preview.174
The Elsa.Studio, Elsa.Studio.Login.BlazorWasm, and Elsa.Studio.Core.BlazorWasm packages have been updated to version 3.0.0-preview.174 across multiple projects. The updated packages should provide the latest functionalities and fixes from the Elsa framework.
* Add API key authentication for Elsa client
Introduced an `ApiKeyHttpMessageHandler` to use an API key as the authorization header for Elsa API client. This ensures secure interaction with the Elsa server. Also made updates to the `ElsaClientOptions` class to include the API key. An `AddElsaClient` method is added with the API key parameter in `DependencyInjectionExtensions` class for convenience.
* add sample CustomUIHandler
* Fix Httpendpoint Path
* Refactor parameter in AddElsaClient method
The parameter "configureOptions" in the AddElsaClient method has been renamed and refactored to allow direct HTTP client configuration. This change enables the actions for configuring the HTTP client to be passed directly, providing greater flexibility for customization.
* Add extension method to get workflow instance ID
This adds a new extension method in HttpResponseMessageExtensions class which retrieves the workflow instance ID from the response. It also includes a HeaderNames class to maintain the consistency of header names used by the Elsa API.
* Remove ElsaClient and related interfaces
Files ElsaClient.cs, IElsaClient.cs and IElsaClientFactory.cs have been deleted from the Elsa.Api.Client project. The commit also includes an update in the DependencyInjectionExtensions.cs file where IElsaClient service registration is removed, reflecting these changes.
* Add condition to return json as string
A condition has been added to check if the returnType is of type 'string'. If so, the json is returned as string directly without converting. This is particularly useful to avoid unnecessary conversion when the returnType is already a string.
* Disable PythonEngine Shutdown to prevent deadlock
* Improve variable resolution in workflow activity
Added a reference to Variable.Id in the SetVariable activity within the Elsa.Workflows.Core module to ensure the correct variable scope is utilized. This change enhances the precision of the variable resolution process by ensuring the correct variable is identified and updated.
* Refactor Elsa API client to use API key authentication
The Elsa API client configuration has been refactored to use API key for authentication instead of HTTP handlers. Besides, the configuration method name was changed to 'AddElsaApiKeyClient' and its parameters were simplified for ease of use. Object 'ElsaClientBuilderOptions' has also been extended with additional properties for further customization.
* Add workflow result variable to context scope
In the ExpressionExecutionContextExtensions module, an additional check and yield operation has been implemented. This allows the inclusion of the workflow result variable, if it exists, to the current context scope.
* Refactor code by renaming and moving classes
Renamed 'VehiculeActivity', 'VehiculeUIHandler' to 'VehicleActivity', 'VehicleUIHandler' and moved them to their separate files. A debouncer was added to InputsTab in the WorkflowDefinitionEditor to limit the rate of firing refresh requests. Optimized codes by reducing unnecessary lines and improved consistency in the 'Program.cs' file.
* Add sample CustomUIHandler (#4729)
* add sample CustomUIHandler
* Refactor code by renaming and moving classes
Renamed 'VehiculeActivity', 'VehiculeUIHandler' to 'VehicleActivity', 'VehicleUIHandler' and moved them to their separate files. A debouncer was added to InputsTab in the WorkflowDefinitionEditor to limit the rate of firing refresh requests. Optimized codes by reducing unnecessary lines and improved consistency in the 'Program.cs' file.
---------
Co-authored-by: Jérémie DEVILLARD <jdevillard@users.noreply.github.com>
Co-authored-by: Sipke Schoorstra <sipkeschoorstra@outlook.com>
* Update Elsa.Studio packages and modify authentication setup
The Elsa.Studio packages have been updated to version "3.0.0-preview.177" from "3.0.0-preview.174" in several project files. Additionally, in the "Program.cs" of ElsaStudioWebAssembly, the way the authentication handler is set up for the remote backend has been simplified and made more straightforward.
* Add System.Runtime to CSharpOptions
The System.Runtime assembly and namespace has been added to CSharpOptions. This extends the functionality capabilities within the Elsa.CSharp module by providing access to the Guid class and its related methods and properties.
* Improve handling of non-HTTP context in HttpEndpoint
Updated the HttpEndpoint class to handle non-HTTP contexts better. Instead of throwing an exception when it finds itself in a non-HTTP context, it now creates a bookmark that allows the invoker to save the state and resume execution from there. A callback has also been added to the bookmarks creation process to prepare for resumption actions.
* Add non-generic variable accessor method
Added a non-generic version of the GetVariable method to the ExecutionContextProxy and GenerateWorkflowVariableAccessors classes in Elsa.CSharp module. Also, extended the CSharpOptions class to include additional namespaces and assemblies related to System.Text.Json. These adjustments provide a more flexible way to access workflow variables and extend the usability of JSON serialization within workflows.
* Add UIHint for FlowJoin activity
The FlowJoin activity's join mode now includes a UIHint, which indicates its input is a dropdown. This improves user interface interaction by allowing the selection of join mode from a dropdown menu rather than manual input.
* Add Parser for Form data 'application/x-www-form-urlencoded' (#4733)
* Update version naming in GitHub Actions
The convention for naming versions in GitHub Actions was modified. Previously, all tags were assigned just a sequential version, even if they were already marked as a release by a tag. Now, if they are tagged and marked as a published release, they use the tag as the version. The change should provide more accurate version information.
* Fix conditional formatting in GitHub workflow
A change has been made to correct the formatting in the conditional statement within the GitHub workflow file. This rectification ensures the proper assignment of the VERSION variable when a new release is published, through proper syntax adherence.
* Refactor variable names and update notification strategy
The variable names '_hosted' and '_backgroundEventService' in ServiceBusTests class have been refactored for clarity. They have been changed to '_backgroundCommandSenderHostedService' and '_backgroundEventPublisherHostedService' respectively to accurately depict the services they are hosting. Also, the notification strategy in the 'BackgroundEventPublisherHostedService' was changed from 'Background' to 'Sequential', fixing the process of sending notifications.
---------
Co-authored-by: Jean-Baptiste Dalle <jean-baptiste.dalle@stereograph.fr>
Co-authored-by: Vincent Doreau <vincent.doreau@stereograph.fr>
Co-authored-by: Sipke Schoorstra <sipkeschoorstra@outlook.com>
Co-authored-by: zergmk2 <zergmk2@users.noreply.github.com>
Co-authored-by: Mohamed Ali <antivirus.cs@gmail.com>
Co-authored-by: jdevillard <djay93@hotmail.com>
Co-authored-by: Jérémie DEVILLARD <jdevillard@users.noreply.github.com>
* Update service lifetimes and use IServiceScopeFactory for runtime activities
This commit introduces several modifications targeting the adjustment of service lifetimes. Classes that were previously instantiated as Scoped are changed to Singletons, and vice versa. Furthermore, it employs IServiceScopeFactory to resolve services required for runtime activities. This improves the application's infrastructure by ensuring more efficient service lifetimes and optimizing the runtime resource allocation.
---------
Co-authored-by: jeanbaptistedalle <jean-baptiste.dalle@laposte.net>
Co-authored-by: Jean-Baptiste Dalle <jean-baptiste.dalle@stereograph.fr>
Co-authored-by: Vincent Doreau <vincent.doreau@stereograph.fr>
Co-authored-by: zergmk2 <zergmk2@users.noreply.github.com>
Co-authored-by: Mohamed Ali <antivirus.cs@gmail.com>
Co-authored-by: jdevillard <djay93@hotmail.com>
Co-authored-by: Jérémie DEVILLARD <jdevillard@users.noreply.github.com>
A change has been made to correct the formatting in the conditional statement within the GitHub workflow file. This rectification ensures the proper assignment of the VERSION variable when a new release is published, through proper syntax adherence.
The convention for naming versions in GitHub Actions was modified. Previously, all tags were assigned just a sequential version, even if they were already marked as a release by a tag. Now, if they are tagged and marked as a published release, they use the tag as the version. The change should provide more accurate version information.
This commit introduces a Dockerfile for the Elsa Studio application and a corresponding GitHub workflow for building and deploying the Docker image. These make it possible to automatically build and deploy Elsa Studio as a Docker image.
This commit introduces two new GitHub Actions workflows: one for building and deploying the Elsa Server + Studio Docker image, and another for the Elsa Server Docker image. Both processes automate the build and push actions to Docker Hub using the latest ubuntu version and buildx for multi-platform support.
The changes included in this commit are made to refactor the project structure and Docker configurations. Previously, the application was structured around the AllInOneWeb solution, but it has been split into Server.Web and ServerAndStudio.Web solutions for better separation of concerns. Additionally, the Docker configurations have been updated to reflect the new structure, which should streamline the build and deployment process.
This update changes the trigger for the package publishing action to only 'published' releases and prereleases. It also segregates the publishing mechanism into two separate actions: one for publishing preview packages to nuget.org, and another for publishing release packages. This change provides better clarity and control over the publishing process.
The npm-packages.yml workflow has been removed. The branch triggers in the workflows npm-packages.yml, packages.yml, and all-in-one-web.yml have been changed from 'v3' to 'main'. An unnecessary reference to the deleted workflow file npm-packages.yml is also removed from Elsa.sln.
The PR body generator workflow has been removed from the repository. This includes the deletion of the workflow configuration file (pr-body-generator.yml) under the GitHub Actions workflows directory and the removal of reference to it in the Elsa.sln file.
* Implemented get version endpoint
* Get version from backend to display on designer
* Updated github pipelines
---------
Co-authored-by: Gürkan Güran <gguran@interfirst.com>