Github user liningalex commented on a diff in the pull request: https://github.com/apache/incubator-predictionio/pull/387#discussion_r120186563 --- Diff: data/src/main/scala/org/apache/predictionio/data/storage/Storage.scala --- @@ -306,9 +306,18 @@ object Storage extends Logging { } val constructor = clazz.getConstructors()(0) try { - constructor.newInstance(ctorArgs: _*). + val instance = constructor.newInstance(ctorArgs: _*). asInstanceOf[T] + try { + val init = instance.getClass.getMethod("init") + init.invoke(instance) + } + catch { + case e: NoSuchMethodException => None --- End diff -- ok, good point.
--- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. ---