Fix conflict between java.io.Serializable and use of Scala's Serializable