score:0

Accepted answer

following up from the comments

define a custom objectmappermodule

class camelcasemodule extends scalaobjectmappermodule {

    override val propertynamingstrategy: propertynamingstrategy =
      new propertynamingstrategy.uppercamelcasestrategy

    override def additionalmapperconfiguration(mapper: objectmapper): unit = {
      mapper.configure(deserializationfeature.fail_on_unknown_properties, true)
 }
}

override the default jackson module for your server

override def jacksonmodule = new camelcasemodule

make sure you have

"com.twitter" %% "finatra-jackson" % yourfinatraversion % "test"

in your build.sbt

and that you import

import com.fasterxml.jackson.databind.{deserializationfeature, module, objectmapper, propertynamingstrategy}
import com.twitter.finatra.jackson.modules.scalaobjectmappermodule

tested it locally and it seems to work hope this helps


Related Query

More Query from same tag