Browse Source

first commit

placidenduwayo 2 years ago
parent
commit
4a09109582

+ 4
- 4
src/main/scala/fr/natan/akkastreamfileprocessingapi/service/AkkaStreamFileProcessingImpl.scala View File

100
     val finalFuture: Future[IndexedSeq[Person]] =
100
     val finalFuture: Future[IndexedSeq[Person]] =
101
       tvSerieIDFuture.andThen({
101
       tvSerieIDFuture.andThen({
102
         case Success(value: Option[String]) =>
102
         case Success(value: Option[String]) =>
103
-          logger.info(s"TvSerie ID: $value")
103
+          logger.info(s"TvSerie ID: ${value.get}")
104
           logger.info(s"STEP 1/3 END, elapsed time:${(System.currentTimeMillis() - start1) / 1000} sec")
104
           logger.info(s"STEP 1/3 END, elapsed time:${(System.currentTimeMillis() - start1) / 1000} sec")
105
 
105
 
106
       })
106
       })
113
             )
113
             )
114
             listPersonIDsFuture.andThen({
114
             listPersonIDsFuture.andThen({
115
               case Success(value) =>
115
               case Success(value) =>
116
-                value.foreach((personID: Option[String]) => logger.info(s"Person ID:$personID"))
116
+                value.foreach((personID: Option[String]) => logger.info(s"Person ID:${personID.get}"))
117
                 logger.info(s"STEP 2/3 END, elapsed time:${(System.currentTimeMillis() - start2) / 1000} sec")
117
                 logger.info(s"STEP 2/3 END, elapsed time:${(System.currentTimeMillis() - start2) / 1000} sec")
118
             })
118
             })
119
               .flatMap({
119
               .flatMap({
142
     tvSerieIdFuture.andThen({
142
     tvSerieIdFuture.andThen({
143
       case Failure(exception) => logger.error(s"${exception.printStackTrace()}")
143
       case Failure(exception) => logger.error(s"${exception.printStackTrace()}")
144
       case Success(value: Option[String]) =>
144
       case Success(value: Option[String]) =>
145
-        logger.info(s"$value")
145
+        logger.info(s"${value.get}")
146
         logger.info(s"STEP 1/3 END, elapsed time:${(System.currentTimeMillis() - start1) / 1000} sec")
146
         logger.info(s"STEP 1/3 END, elapsed time:${(System.currentTimeMillis() - start1) / 1000} sec")
147
 
147
 
148
     })
148
     })
155
           listOfPersonsIDsFuture.andThen({
155
           listOfPersonsIDsFuture.andThen({
156
             case Failure(exception) => logger.error(s"${exception.printStackTrace()}")
156
             case Failure(exception) => logger.error(s"${exception.printStackTrace()}")
157
             case Success(value: IndexedSeq[Option[String]]) =>
157
             case Success(value: IndexedSeq[Option[String]]) =>
158
-              value.foreach((personID: Option[String]) => logger.info(s"Person ID:$personID"))
158
+              value.foreach((personID: Option[String]) => logger.info(s"Person ID:${personID.get}"))
159
               logger.info(s"STEP 2/3 END, elapsed time:${(System.currentTimeMillis() - start2) / 1000} sec")
159
               logger.info(s"STEP 2/3 END, elapsed time:${(System.currentTimeMillis() - start2) / 1000} sec")
160
           })
160
           })
161
             .flatMap({
161
             .flatMap({

Powered by TurnKey Linux.