public static MultipartUploadHolder getRequiredImage(@NotNull MultipartFormDataInput multipartInput,
         @NotNull String partName, long sizeLimitBytes)
         throws IOException {
        InputPart imgPart =  MultipartHelper.getRequiredPart(multipartInput, partName, new MediaType("image", "*"));
        MediaType imgMediaType = imgPart.getMediaType();
        ContentDisposition imgContentDisposition = MultipartHelper.getContentDisposition(imgPart);
        String filename = Optional.ofNullable(imgContentDisposition.getFilename()).orElse("");
        FileBackedOutputStream fbos = MultipartHelper.transferToFbos(imgPart, sizeLimitBytes); // TODO(msavy): add threshold to config
        return new MultipartUploadHolder(filename, fbos, imgMediaType);
    }
@author Marc Savy {@literal <marc@blackparrotlabs.io>}
manager/api/rest-impl/src/main/java/io/apiman/manager/api/rest/impl/util/MultipartHelper.java