Commit 4ca0d42c authored by Jonas Waeber's avatar Jonas Waeber
Browse files

Fix issue with invalid creator type fields

parent cb9e0f57
......@@ -30,7 +30,6 @@ import org.memobase.builder.ResourceBuilder
import org.memobase.helpers.ReportStatus
import org.memobase.mapping.MappingConfig
import org.memobase.settings.SettingsLoader
import javax.management.remote.rmi._RMIConnectionImpl_Tie
class KafkaTopology(
private val settings: SettingsLoader
......
......@@ -278,7 +278,7 @@ class MappingConfig(directory: String) {
(mapper as AgentFieldMapper).property = key
if (value.containsKey(KEYS.creatorType)) {
mapper.creationType = parseAnnotationField(value.entries.first { i -> i.key == KEYS.creatorType })
mapper.creationType = parseSimpleAnnotationField(KEYS.creatorType, value.entries.first { i -> i.key == KEYS.creatorType }.value)
}
return mapper
}
......
......@@ -19,12 +19,12 @@
package org.memobase.mapping.mappers
import org.memobase.builder.IResource
import org.memobase.mapping.fields.ConfigField
import org.memobase.mapping.fields.ConstantField
import org.memobase.mapping.fields.MappedAnnotationField
import org.memobase.mapping.fields.SimpleAnnotationField
class AgentFieldMapper : TypeFieldMapper() {
var creationType: ConfigField? = null
var creationType: SimpleAnnotationField? = null
var property: String = ""
override fun apply(source: Map<String, String>, subject: IResource) {
translateProperties(source, subject)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment