public JobMetaDataParameterObject processJobMultipart(JobMultiPartParameterObject parameterObject)
            throws IOException, NoSuchAlgorithmException {
        // Change the timestamp in the beginning to avoid expiration
        changeLastUpdatedTime();

        validateReceivedParameters(parameterObject);

        validateReceivedPartNumbersAreExpected(parameterObject);

        validatePartChecksum(parameterObject);

        // Parts numbers are good. Save them
        currentPart = parameterObject.getCurrentPartNumber();
        totalPart = parameterObject.getTotalPartNumber();

        Path jarPath = jobMetaDataParameterObject.getJarPath();

        // Append data to file
        try (OutputStream outputStream = Files.newOutputStream(jarPath, StandardOpenOption.CREATE, StandardOpenOption.APPEND)) {
            outputStream.write(parameterObject.getPartData(), 0, parameterObject.getPartSize());
        }

        if (LOGGER.isInfoEnabled()) {
            String message = String.format("Session : %s jarPath: %s PartNumber: %d/%d Total file size : %d bytes",
                    parameterObject.getSessionId(), jarPath, currentPart, totalPart, Files.size(jarPath));
            LOGGER.info(message);
        }

        JobMetaDataParameterObject result = null;
        // If parts are complete
        if (currentPart == totalPart) {

            validateJarChecksum();

            result = jobMetaDataParameterObject;
        }
        return result;
    }
@Test
    public void testInvalidOrder() {
        JobMultiPartParameterObject jobMultiPartParameterObject = new JobMultiPartParameterObject();
        jobMultiPartParameterObject.setSessionId(null);
        jobMultiPartParameterObject.setCurrentPartNumber(2);
        jobMultiPartParameterObject.setTotalPartNumber(1);
        jobMultiPartParameterObject.setPartData(null);
        jobMultiPartParameterObject.setPartSize(0);

        Assert.assertThrows(JetException.class, () -> jobUploadStatus.processJobMultipart(jobMultiPartParameterObject));
    }