This is an automated email from the ASF dual-hosted git repository. bertty pushed a commit to branch WAYANG-34 in repository https://gitbox.apache.org/repos/asf/incubator-wayang.git
commit 3156bb31c4e9c232bac76f6e4df984241b4e66d4 Author: Bertty Contreras-Rojas <[email protected]> AuthorDate: Mon Sep 27 19:59:19 2021 +0200 [WAYANG-34] Correction compilation scala-11 and scala-13 Signed-off-by: bertty <[email protected]> --- .../main/scala/org/apache/wayang/apps/tpch/TpcH.scala | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/wayang-benchmark/code/main/scala/org/apache/wayang/apps/tpch/TpcH.scala b/wayang-benchmark/code/main/scala/org/apache/wayang/apps/tpch/TpcH.scala index 3c101e8..c28952f 100644 --- a/wayang-benchmark/code/main/scala/org/apache/wayang/apps/tpch/TpcH.scala +++ b/wayang-benchmark/code/main/scala/org/apache/wayang/apps/tpch/TpcH.scala @@ -22,13 +22,13 @@ import org.apache.wayang.apps.tpch.queries.{Query1, Query3Database, Query3File, import org.apache.wayang.apps.util.{Parameters, ProfileDBHelper, StdOut} import org.apache.wayang.commons.util.profiledb.model.Experiment import org.apache.wayang.core.api.Configuration +import org.apache.wayang.core.platform.Platform import org.apache.wayang.jdbc.platform.JdbcPlatformTemplate import org.apache.wayang.postgres.Postgres import org.apache.wayang.postgres.operators.PostgresTableSource import org.apache.wayang.sqlite3.Sqlite3 import org.apache.wayang.sqlite3.operators.Sqlite3TableSource -import scala.collection.JavaConverters /** * This app adapts some TPC-H queries. @@ -50,12 +50,15 @@ object TpcH { val jdbcPlatforms = plugins .flatMap( plugin => { - JavaConverters - .collectionAsScalaIterable( - plugin.getRequiredPlatforms - ) - .toSeq - }) + val list = plugin.getRequiredPlatforms + var array: List[Platform] = List[Platform]() + val iterator = list.iterator() + while(iterator.hasNext){ + array :+= iterator.next() + } + array + } + ) .filter(_.isInstanceOf[JdbcPlatformTemplate]) .distinct if (jdbcPlatforms.size == 1) jdbcPlatforms.head.asInstanceOf[JdbcPlatformTemplate]
