Skip to content

Provide support for Jakarta EE #50

Description

@sleepo581

Describe the bug

I'm migrating an application from old javax to new jakarta EE packages, however I got a few issues with Uploadcare Java client.
I suppose that Uploadcare uses javax.activation which is conflicting with jakarta.activation package.

The error can be reproduced like this:

  • Add com.uploadcare:uploadcare:3.5.1 dependency
  • Add jakarta.activation:jakarta.activation-api:2.1.1 dependency
  • Try to upload file via FileUploader

Expected behavior

File is uploaded without exceptions

Code / screenshots

java.lang.IllegalAccessError: failed to access class com.sun.activation.registries.LogSupport from class javax.activation.MimetypesFileTypeMap (com.sun.activation.registries.LogSupport and javax.activation.MimetypesFileTypeMap are in unnamed module of loader 'app')
	at javax.activation.MimetypesFileTypeMap.<init>(MimetypesFileTypeMap.java:130)
	at com.uploadcare.api.RequestHelper.getMimeType(RequestHelper.java:80)
	at com.uploadcare.upload.FileUploader.upload(FileUploader.java:127)

Environment

  • 3.5.1
  • Java/SpringBoot
  • macOS

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions