Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MySqlConnector.MySqlException (0x80004005): This version of MySQL doesn't yet support 'LIMIT & IN/ALL/ANY/SOME subquery' #6219

Closed
lujie19930803 opened this issue Dec 17, 2024 · 4 comments
Labels
bug Something isn't working

Comments

@lujie19930803
Copy link

lujie19930803 commented Dec 17, 2024

Description

when i use mysql to perisist data. i meet the following error. and my elsa version is 3.2.2. mysql version is 8.0.29.
image

Steps to Reproduce

i configure elsa like that.

services.AddElsa(elsa =>
        {
            elsa.UseWorkflowRuntime(runtime => runtime.UseEntityFrameworkCore(ef => ef.UseMySql(connectionStr)));
            elsa.UseWorkflowManagement(management => management.UseEntityFrameworkCore(ef => ef.UseMySql(connectionStr)));
            elsa.UseIdentity(identity =>
            {
                identity.TokenOptions = options => options.SigningKey = "sufficiently-large-secret-signing-key"; // This key needs to be at least 256 bits long.
                identity.UseAdminUserProvider();
            });
            elsa.UseDefaultAuthentication(auth => auth.UseAdminApiKey());
            elsa.UseWorkflowsApi();
            elsa.UseRealTimeWorkflows();
            elsa.UseCSharp();
            elsa.UseJavaScript();
            elsa.UseFileStorage();
            elsa.UseHttp();
            elsa.UseScheduling();
        });

i found when i comment UseWorkflowRuntime. this error disappeared.
image
@sfmskywalker please help me.

@lujie19930803 lujie19930803 added the bug Something isn't working label Dec 17, 2024
@r-kernberger
Copy link

@lujie19930803 I had the same error with v3.2. Give v3.3.0-rc3 a try. It was fixed for me then

@sfmskywalker
Copy link
Member

It sounds familiar to what is happening in #6126

If the issue persists despite @r-kernberger 's suggestion, here are two other options to consider:

  1. Upgrade to the latest MySql (>= v9) version.
  2. Generate EF Core migrations manually and use them instead.

The MySql EF Core migrations shipped with Elsa target the latest MySql version and are included for convenience, however these are not required. Some users even prefer to maintain their own migrations.

@sfmskywalker sfmskywalker moved this to Triage in ELSA 3 Dec 28, 2024
@sfmskywalker
Copy link
Member

I performed some tests with MySQL 8.0.0 and Elsa running on .NET 8, and I ran into some issues.
I was able to work around those issues by enabling primitive support and automatically translating parameterized collections to constants, as explained here.

After that, the MySql provider seems to work well, so far. I'll conduct more tests.

@sfmskywalker
Copy link
Member

The MySql provider + migrations seems to operate well on MySql 8.0. I would encourage you to try out the latest preview build. I'll close this issue as resolved, but please let me know if you still run into issues.

@github-project-automation github-project-automation bot moved this from Triage to Done in ELSA 3 Dec 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: Done
Development

No branches or pull requests

3 participants