Skip to content

Commit

Permalink
fix for scala 2.12
Browse files Browse the repository at this point in the history
  • Loading branch information
clairemcginty committed Sep 12, 2024
1 parent 81e3f07 commit a730718
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,10 @@ package magnolify.parquet

import org.apache.hadoop.conf.Configuration

import java.util.Objects

/**
* Properties for reading and writing Magnolify ParquetType classes,
* configurable via a Hadoop [[Configuration]] instance.
*/
object MagnolifyParquetProperties {
val WriteGroupedArrays: String = "magnolify.parquet.write-grouped-arrays"
val WriteGroupedArraysDefault: Boolean = false
Expand All @@ -32,8 +34,6 @@ object MagnolifyParquetProperties {

// Hash any Configuration values that might affect schema creation to use as part of Schema cache key
private[parquet] def hashValues(conf: Configuration): Int = {
Objects.hash(
Option(conf.get(WriteGroupedArrays)).map(_.toBoolean).getOrElse(WriteGroupedArraysDefault)
)
Option(conf.get(WriteGroupedArrays)).map(_.toBoolean).getOrElse(WriteGroupedArraysDefault).hashCode()
}
}
4 changes: 2 additions & 2 deletions parquet/src/main/scala/magnolify/parquet/ParquetField.scala
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,9 @@ import org.apache.parquet.io.api._
import org.apache.parquet.schema.PrimitiveType.PrimitiveTypeName
import org.apache.parquet.schema.Type.Repetition
import org.apache.parquet.schema.{LogicalTypeAnnotation, Type, Types}
import org.typelevel.scalaccompat.annotation.nowarn

import scala.annotation.implicitNotFound
import scala.annotation.{implicitNotFound, nowarn}
import scala.collection.compat._
import scala.collection.concurrent

sealed trait ParquetField[T] extends Serializable {
Expand Down

0 comments on commit a730718

Please sign in to comment.