Skip to content

[Bug] [Task Plugin] AliyunServerlessSpark plugins use incompatible credentials-java (0.3.0), causing NoSuchFieldError: providerName #18178

@includetts

Description

@includetts

Search before asking

  • I had searched in the issues and found no similar issues.

What happened

Both AliyunServerlessSpark plugins (datasource and task) explicitly declare credentials-java:0.3.0. However, emr_serverless_spark20230808:2.4.1 transitively depends on tea-openapi:0.3.8, which requires credentials-java:1.0.1.

The explicit 0.3.0 declaration overrides the transitive 1.0.1 during Maven shade packaging. Version 0.3.0 lacks the CredentialModel.providerName field that tea-openapi:0.3.8's Client.doRequest() accesses at runtime, causing NoSuchFieldError.

What you expected to happen

The credentials-java version should be 1.0.1 to match the requirement of tea-openapi:0.3.8.

Error log:
java.lang.NoSuchFieldError: providerName
at com.aliyun.teaopenapi.Client.doRequest(Client.java:...)
at com.aliyun.emr_serverless_spark20230808.Client.startJobRunWithOptions(Client.java:...)

How to reproduce

  1. Deploy DolphinScheduler (standalone or cluster mode)
    1. Install both AliyunServerlessSpark plugins
    1. Submit an AliyunServerlessSpark task
    1. The task fails with NoSuchFieldError: providerName
      Dependency chain: emr_serverless_spark20230808:2.4.1 -> tea-openapi:0.3.8 -> credentials-java:1.0.1

Both plugins need the fix:

  • dolphinscheduler-datasource-aliyunserverlessspark/pom.xml: credentials-java 0.3.0 -> 1.0.1
    • dolphinscheduler-task-aliyunserverlessspark/pom.xml: credentials-java 0.3.0 -> 1.0.1

Anything else

This bug occurs every time. The fix is to upgrade credentials-java from 0.3.0 to 1.0.1 in both plugin pom.xml files. Related issue: #18177

Version

dev

Are you willing to submit PR?

  • Yes I am willing to submit a PR!

Code of Conduct

Metadata

Metadata

Assignees

Labels

backendbugSomething isn't working

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions