BPM: Setting the value of io.jmix.core.FileRef from io.jmix.bpm.entity.FileDescription

UPD:
If your problem still not solved, i can offer you check this topic. In short, you need just transform FileDescription into FileRef as i said before.
Steps:

  1. Add service task with SpringBean type before EntityDataTask
  2. Extract your FileDescription and transform it inside spring bean
    import io.jmix.bpm.entity.FileDescription;
    import io.jmix.core.FileRef;
    import io.jmix.core.FileStorage;
    import org.springframework.stereotype.Component;
    
    import java.io.ByteArrayInputStream;
    import java.io.IOException;
    import java.io.InputStream;
    
    @Component
     public class ProcessFileManager {
    
        private FileStorage fileStorage;
    
        public ProcessFileManager(FileStorage fileStorage) {
            this.fileStorage = fileStorage;
        }
    
        public FileRef saveFileToFileStorage2(FileDescription fileDescription) throws IOException {
             try (InputStream is = new ByteArrayInputStream(fileDescription.getFileContent())) {
                FileRef fileRef = fileStorage.saveStream(fileDescription.getFileName(), is);
                return fileRef;
            }
        }
    }
    
  3. Put into service task’s method argument your FileDescription (named fileVar and marked as process variable)
  4. Publish ServiceTask result as process variable (named fileRefVar in screenshot)
    As i said, you just need to transform FileDescription into FileRef.
  5. Use your new FileRef by process variable named fileRefVar

Otherwise, you can use ServiceTask inside of EntityDataTask and taransoform and create necessary Entity insidea SpringBean manually to prevent bpmn schema complication.

If you need more detail explanation/demo, attach your demo project.

Regard, Dmitry