Привет всем, у меня есть ошибка во время выполнения моего кода scala.он говорит java.lang.ClassCastException: scala.runtime.BoxedUnit не может быть приведен к scala.Tuple4
во время шага сохранения, когда я пытаюсь преобразовать наборы данных
val datasets = Try(Computing.process(input_bi.asInstanceOf[(Dataset[SortieFondsct], Dataset[SortieFondIP], Dataset[EntreeFondsct], Dataset[EntreeFondIP])], connector)) match {
case Success(v) => System.out.println("Success")
case Failure(err) => {
val monitoringToSave = err match {
case _: ArrayIndexOutOfBoundsException => Logger.error(ERROR_TYPE_MISSING_ARGS, "Computing", DRIVER_VIR_SORT_NAME, err, true, idDimTemps)
case _: AnalysisException => Logger.error(ERROR_TYPE_INVALID_QUERY, "Computing", DRIVER_VIR_SORT_NAME, err, true, idDimTemps)
case _: FileNotFoundException => Logger.error(ERROR_TYPE_FILE_NOT_FOUND, "Computing", DRIVER_VIR_SORT_NAME, err, true, idDimTemps)
case _: EmptyFileException => Logger.error(ERROR_TYPE_FILE_IS_EMPTY, "Computing", DRIVER_VIR_SORT_NAME, err, true, idDimTemps)
case _: EmptyColumnException => Logger.error(ERROR_TYPE_COLUMN_VALUE_EMPTY, "Computing", DRIVER_VIR_SORT_NAME, err, true, idDimTemps)
case _: Throwable => Logger.error(ERROR_UNKNOWN, "Computing", DRIVER_VIR_SORT_NAME, err, true, idDimTemps)
}
CassandraClient.saveMonitoring(monitoringToSave, connector)
throw err
}
}
// ******************** SAVING STEP ********************
val persist = Try(Saving.process(datasets.asInstanceOf[(Dataset[SortieFondsct], Dataset[SortieFondIP], Dataset[EntreeFondsct], Dataset[EntreeFondIP])])) match { //error here
case Success(v) => System.out.println("Success")
case Failure(err) => {
val monitoringToSave = err match {
case _: DifferentNumberInsertedLinesException => Logger.error(ERROR_TYPE_DIFF_NB_LINES_INSERT, "Saving", DRIVER_VIR_SORT_NAME, err, true, idDimTemps)
case _: CannotGetDataFromCassandra => Logger.error(ERROR_TYPE_CANNOT_GET_DATA_FROM_DB, "Saving", DRIVER_VIR_SORT_NAME, err, true, idDimTemps)
case _: Throwable => Logger.error(ERROR_UNKNOWN, "Saving", DRIVER_VIR_SORT_NAME, err, true, idDimTemps)
}
CassandraClient.saveMonitoring(monitoringToSave, connector)
throw err
}
}