-
Notifications
You must be signed in to change notification settings - Fork 3.3k
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
When 2.x is upgraded to 3.x, an error of className inconsistency is reported #2217
Comments
升级3.x后 ,job会判断任务根节点下存储className是否和当前任务相同,明显此时是没有的, |
|
The error of class Name inconsistency that you're encountering when upgrading from version 2.x to 3.x of a software typically happens because:
How to resolve it 👍 :
|
@samiya2804 I have to assume you don't actually use elasticjob unless you plan on submitting a PR. |
Theortically i have a knowleadge of elastic job |
The reason is that the 3.x version and 2.x have different structures for storing data in zk. The className of 3.x is stored under the jobRootNode, while the 2.x version is stored under the config node, and the 2.x is upgraded to In 3.x, an error will be reported when judging the className, but I read the source code, and the code for judging the task className is as follows:
Among them, null != originalJobClassName is to judge whether there is a className under the jobRootNode node in zk, but the judgment here is not null. I found that this String will always be referenced in the test, so null != originalJobClassName is always true, even if the string is an empty character string, so I think, is it possible to change to
In this way, the desired judgment logic can be achieved. May I ask if the official can modify it in this way? Is there any situation that I have not considered?
The text was updated successfully, but these errors were encountered: