elsa-workflows / elsa-documentation Goto Github PK
View Code? Open in Web Editor NEWThe official Elsa documentation website
Home Page: elsa-documentation.vercel.app
License: Other
The official Elsa documentation website
Home Page: elsa-documentation.vercel.app
License: Other
How to register custom types.
I tried this and other tutorials on Http endpoint workflows and am confused.
If i import any of the samples, the UI gives me
No indication the URL or calling pattern.
https://v3.elsaworkflows.io/docs/samples/http/backend-api
I imported sample json above and hit it with the curl command on the page, and got "Nothing there" from the studio app.
In this page: https://v3.elsaworkflows.io/docs/installation/elsa-studio-stencil
On Deprecation Notice the link is incorrect:
we recommend using the Blazor version of the workflow designer.
Create a comprehensive guide on setting up the supported persistence providers, such as EF Core with SQL Server and MongoDB. The documentation should cover the configuration steps for both Workflow Runtime and Workflow Management modules, ensuring users can seamlessly integrate their preferred storage solutions.
This guide will serve as a valuable resource for developers looking to tailor Elsa Workflows to their project's needs by leveraging different database technologies for persistence.
The Webhooks module is used by the RunTask activity - how does one extend the Webhooks module with custom events?
We need a section about writing activities that are blocking and that can be used as triggers. This should include details about how to resume & trigger them.
See also this discussion containing a few quick pointers about this.
We need to bring example in documentation of how to updating the and/or signaling and/or querying states of any variable states in workflow
// Update state of workflow.
Task UpdateWorkflowParams(GreetingParams greetingParams) => _currentParams = greetingParams;
// Update state of workflow.
Task CompleteWorkflow() => _complete = true;
then
Workflow.WaitCondition(() => _complete == true);
triggered
// Query state in Workflow
string GetValueOfName() => _name;
Describe the HTTP Activity. how it works and how to invoke workflows with this activity used as a trigger.
There should be a topic on the ELSA architecture, probably from different levels and perspectives - starting with a high-level description about what happens when a workflow executes.
Hi,
I am in search of the equivalent packages for workflow testing/visualisation you had in Elsa V2 - Elsa.WorkflowTesting.Api
and services.AddWorkflowTestingServices();
- but for V3? Are these available or are they on your radar for a release anytime soon?
Many thanks
Liam.
https://v3.elsaworkflows.io/docs/extensibility/custom-activities seems to report outdated information.
Please upgrade it or indicate alternative documentation.
We need to bring example of wait condition during workflow execution
// Define condition.
var waitComplete = Workflow.WaitCondition(() => SomeCondition());
if (waitComplete == await Task.WhenAny(waitComplete))
Is your documentation issue related to a specific problem? Please describe.
https://v3.elsaworkflows.io/docs/guides/loading-workflows-from-json this documentation area has a bug
Describe the changes or additions you'd like
This statement: Add a package reference to Elsa.WorkflowProviders.FluentStorage to the workflow server project.
...is incorrect, it should say:
Add a package reference to Elsa.WorkflowProviders.BlobStorage to the workflow server project.
Identify which sections of the documentation are affected
setup guide
Explain the potential impact
Fixes a bug that makes getting started difficult
Add any other context or visuals
n/a
Add a section about configuring and using the DropIns module.
We need to getting all workflows list, filtering them by status or other filters.
Workflow.ListWorkflows("Status != 'Terminated'");
We need documentation about the V3 version of Workflow Context.
There are some significant onboarding gaps I experienced that the docs could alleviate
This is to just list these out.
The DbContextOptions passed to the AppDbContext constructor must be a DbContextOptions<AppDbContext>. When registering multiple DbContext types, make sure that the constructor for each context type has a DbContextOptions<TContext> parameter rather than a non-generic DbContextOptions parameter.
UseEntityFrameworkCore
need to ensure they include the ef => ef.UsePostgreSql(appConfig.DbConnectionString)
configuration.Micrososft.EntityFrameworkCore.Design
you're going to have problems with the Microsoft.CodeAnalysis.CSharp.Workspaces
dependency version because elsa
has it pinned as a specific versionfail: Microsoft.AspNetCore.Diagnostics.DeveloperExceptionPageMiddleware[1] An unhandled exception has occurred while executing the request. Swashbuckle.AspNetCore.SwaggerGen.SwaggerGeneratorException: Failed to generate Operation for action - HTTP: POST /elsa/api/identity/secrets/hash. See inner exception ---> Swashbuckle.AspNetCore.SwaggerGen.SwaggerGeneratorException: Failed to generate schema for type - Elsa. Identity.Endpoints.Secrets.Hash.Request. See inner exception ---> System.InvalidOperationException: Can't use schemaId "$Request" for type "$Elsa.Identity.Endpoints.Secr ets.Hash.Request". The same schemaId is already used for type "$Elsa.Identity.Endpoints.Users.Create.Request"
401 unauthorized
...
Hangfire
you're going to have slight pain because the Elsa dependency is pinned to 1.8.6
(Current is 1.8.12
). (You'll need to explicitly install the version needed)
Only use this feature if you are not configuring Hangfire yourself
If we are, is there any additional configuration Elsa needs?It's been 6h ~11h trying to get this running on an existing application, this is brutal ๐ฐ
Document how to provide custom icons for custom activities.
Document how to implement custom UI hints.
https://v3.elsaworkflows.io/docs/guides/loading-workflows-from-json and https://v3.elsaworkflows.io/docs/guides/invoking-workflows link to https://v3.elsaworkflows.io/docs/installation/aspnet-apps-workflow-server with text "ASP.NET workflow server".
Should these links and their text be updated to point to the Elsa Web page or the Elsa Server page?
Document the functionality of Bulk Dispatch Workflows (including one or two examples how to use it).
We need to port the Alterations documentation
In the Elsa Documentation for 3.0, in order to create a new user we are supposed to call the following rest endpoint
https://server-name/elsa/api/identity/applications \
--header 'Content-Type: application/json' \
--data '{
"name": "Postman",
"roles": ["admin"]
}
However, it's applicable only for localhost
as the documentation states
By default, creating applications is allowed for anonymous requests from the localhost.
I would like to host the application on my personal azure platform with App Service which will not have localhost
. What should be done in that case ?
cc
: @sfmskywalker @agriffard @VahidNaderi @mohdali
Originally posted by @Gupta-Krishnaa in #15
The documentation states that the output of an acticity can be retrieved by calling Output.From(string, string?)
. This leads to a compilation error stating that OutputProxy has no such method.
I took a look into the sourcecode and saw that the real method name is Output.Get(string, string?)
.
Also, let's make sure to document this: madelson/DistributedLock#74
The doc mentions rabbitMqFeature.ConfigureRabbitMq, but actualy there is no delegate named ConfigureRabbitMq, only one named ConfigureServiceBus.
It's easy to update the doc, but seems the right thing to do is to rename the delegate name from ConfigureServiceBus to ConfigureRabbitMq?
But this will be a break change.
Kindly confirm the right change to do here, then I will be happy to send a PR.
We need a topic about setting up Elsa on a distributed environment. This could be more general-purpose, with more specific configurations for targets like Kubernetes (#32).
How to integrate into:
With one or some of the following providers:
See also: elsa-workflows/elsa-core#4767
More specifically:
In a Discord support thread someone asked:
Hey guys, I am new to ELSA world. but i am wondering if we can create custom UI components (new web components, for example select/multiselect, interactive UI inputs) so we can provide the inputs in the designer itself. is this possible to add/alter the current activities to do such things?
or even write my custom components in a framework like react and inject them to be components in ELSA?
@sfmskywalker said that this already possible but not documented yet.
We need a section about the ability to define a workflow from code and then register it with the runtime. For example:
// Define workflow.
var workflow = new Workflow(new Flowchart())
{
Metadata = { DefinitionId = "MyDynamicWorkflow" }
Name = "MyDynamicWorkflow"
};
// Register workflow.
_runtime.register(workflow);
// Execute workflow.
_runtime.StartWorkflow("MyDynamicWorkflow", new StartWorkflowOptions());
We need a section about configuring the default Identity module and how to set users + roles + applications (with API keys).
There should be an entire section that walks through the process of dockerizing an Elsa Server app and deploying it to a Kubernetes cluster.
Hi, i noticed that the "Installing Elsa Dashboard"-section in v2 documentation links to a deprecated npm package of the workflow designer: https://www.npmjs.com/package/@elsa-workflows/elsa-workflow-designer
Should be https://www.npmjs.com/package/@elsa-workflows/elsa-workflows-studio
I need an tutorial on how to set an custon ActivityA that return an list of item, then foreach of then pass the value to Activities B and C.
I'm trying this, but without success
namespace CodeGeneratorWPF.Workflow
{
public class CodeGenerationWorkflow : WorkflowBase
{
protected override ValueTask BuildAsync(IWorkflowBuilder builder, CancellationToken cancellationToken = default)
{
var currentValueVariable = new Variable<EntityDefinition>("current", new EntityDefinition());
var entities = new Variable<List<EntityDefinition>>("entities", new List<EntityDefinition>());
builder.Root = new Sequence
{
Variables = { currentValueVariable, entities },
Activities =
{
new GetEntityDefinitionStep()
{
InputContainerModel = new(entities)
},
new SetVariable
{
Variable = entities,
Value = new(context =>
{
return builder.Outputs.FirstOrDefault(x => x.Name == "entities");
})
},
new ForEach<EntityDefinition>((ICollection<EntityDefinition>)entities.Value){
CurrentValue = new Output<EntityDefinition>(currentValueVariable),
Body = new Sequence
{
Activities =
{
new NetCore_EntityFrameworkStep(currentValueVariable)
{
},
new WriteLine(context => $"Counter {currentValueVariable.Get(context)}")
}
}
}
}
};
return ValueTask.CompletedTask;
}
}
}
public class GetEntityDefinitionStep : CodeActivityWithResult
{
public Output<List<EntityDefinition>> OutputEntities { get; set; }
public List<EntityDefinition> Entities { get; set; }
public Input<List<string>> InputPathOfClasses { get; set; }
public Input<ContainerModel> InputContainerModel { get; set; }
public Output<ContainerModel> OutputContainerModel { get; set; }
public Output<List<EntityDefinition>> OutputEntityDefinition { get; set; }
public List<string> PathOfClasses { get; set; }
class ClassInformatasdfion
{
public string Name { get; set; }
public List<PropertyInfoasdfrmation> Properties { get; set; }
public bool HasDecorator { get; set; }
public string SystemType { get; set; }
}
class PropertyInfoasdfrmation
{
public string Name { get; set; }
public string Type { get; set; }
public List<string> Decorators { get; set; } = new List<string>();
}
//public GetEntityDefinitionStep(Variable<List<string>> pathOfClasses)
//{
// InputPathOfClasses = new(pathOfClasses);
//}
protected override async ValueTask ExecuteAsync(ActivityExecutionContext context)
{
Console.WriteLine("BEGIN - " + this.GetType().Name);
//var a = InputPathOfClasses.Get(context);
var containerModel = context.WorkflowInput.FirstOrDefault(x => x.Key == "container").Value;
var container = GetEntityDefinition(containerModel as ContainerModel);
Console.WriteLine("END - " + this.GetType().Name);
//Result.SetPropertyValue("entities", container.Entities);
OutputContainerModel.Set(context, new Variable<ContainerModel>(container));
OutputEntityDefinition.Set(context, new Variable<List<EntityDefinition>>(container.Entities));
context.SetVariable("entities", container.Entities);
}
}
There seems to be a discrepancy between the documentation and the actual behavior of the system. When following the steps outlined in the Elsa-Server documentation to set up an Elsa server, the step to create a new admin results in a 401 Unauthorized error. This is unexpected as the documentation mentions that requests from localhost should be allowed.
The request in question is:
curl --location 'https://localhost:5001/elsa/api/identity/applications' \\
--header 'Content-Type: application/json' \\
--data '{
"name": "Postman",
"roles": ["admin"]
}'
Additionally, the provided Program.cs
configuration is as follows:
using Elsa.Extensions;
using osisa.SmartWeb2.Api.Workflows;
var builder = WebApplication.CreateBuilder(args);
// Add services to the container.
builder.Services.AddControllers();
builder.Services.AddElsa(elsa =>
elsa
// Configure identity so that we can create a default admin user.
.UseIdentity(identity =>
{
var configuration = builder.Configuration;
var identitySection = configuration.GetSection("Identity");
var identityTokenSection = identitySection.GetSection("Tokens");
identity.IdentityOptions = options => identitySection.Bind(options);
identity.TokenOptions = options => identityTokenSection.Bind(options);
identity.UseConfigurationBasedUserProvider(options => identitySection.Bind(options));
identity.UseConfigurationBasedApplicationProvider(options => identitySection.Bind(options));
identity.UseConfigurationBasedRoleProvider(options => identitySection.Bind(options));
})
// Use default authentication (JWT + API Key).
.UseDefaultAuthentication(auth => auth.UseAdminApiKey())
// EXPOSE API ENDPOINTS
.UseWorkflowsApi()
// REGISTER WORKFLOWS AS HTTP ENDPOINTS under /workflows/{name}
.UseWorkflowRuntime(
runtime => runtime
.AddWorkflow<HelloWorldHttpWorkflow>())
.UseHttp()
);
// Configure CORS to allow designer app hosted on a different origin to invoke the APIs.
builder.Services.AddCors(cors => cors.AddDefaultPolicy(policy => policy.AllowAnyOrigin().AllowAnyHeader().AllowAnyMethod()));
var app = builder.Build();
// Configure the HTTP request pipeline.
app.UseHttpsRedirection();
app.UseAuthorization();
// ENABLE CORS
app.UseCors();
// ENABLE AUTHENTICATION
app.UseAuthentication();
// ENABLE WORKFLOWS API
app.UseWorkflowsApi();
// REGISTER CONTROLLERS AS HTTP ENDPOINTS
app.MapControllers();
// ENABLE WORKFLOWS TO BE USED AS HTTP ENDPOINTS
app.UseWorkflows();
app.Run();
It would be beneficial for users if the documentation could be updated to reflect the correct steps or provide additional troubleshooting steps for this issue.
Hi,
In the dashboard documentation, the three first links are broken :
Elsa Server
ElsaDashboard.Web
ElsaDashboard + Docker
See you !
We should have a section that explains workflow providers to dynamically provide workflows to the system.
Use cases:
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.