hello Datahub team, I'm running into an issue with...
# troubleshoot
w
hello Datahub team, I'm running into an issue with custom metadata models in datahub 0.9.6.1 and 0.10.0; making a plugin (via
metadata-models-custom
) to add a custom aspect to the
container
entity results in this error:
java.lang.UnsupportedOperationException: Failed to find Snapshot associated with Config-based Entity
this seems to be caused by datahub expecting the base entity to have an entity snapshot, which containers do not have; is this intended behavior? I was under the impression that snapshot-based entities have been deprecated for over a year now
plus1 1
1
custom entity-registry.yml:
Copy code
id: customAspect
entities:
  - name: container
    aspects:
      - customAspect
CustomAspect.pdl:
Copy code
namespace com.mycompany.custom

@Aspect = {
  "name": "customAspect"
}
record CustomAspect {
  placeholder: string
}
full stacktrace:
Copy code
java.lang.UnsupportedOperationException: Failed to find Snapshot associated with Config-based Entity
	at com.linkedin.metadata.models.ConfigEntitySpec.getSnapshotSchema(ConfigEntitySpec.java:75)
	at com.linkedin.metadata.models.registry.MergedEntityRegistry.mergeEntitySpecs(MergedEntityRegistry.java:113)
	at com.linkedin.metadata.models.registry.MergedEntityRegistry.apply(MergedEntityRegistry.java:61)
	at com.linkedin.metadata.models.registry.PluginEntityRegistryLoader.loadOneRegistry(PluginEntityRegistryLoader.java:147)
	at com.linkedin.metadata.models.registry.PluginEntityRegistryLoader.lambda(PluginEntityRegistryLoader.java:100)
	at java.base/java.util.ArrayList.forEach(ArrayList.java:1541)
	at com.linkedin.metadata.models.registry.PluginEntityRegistryLoader.lambda(PluginEntityRegistryLoader.java:100)
	at java.base/java.util.concurrent.Executors.call(Executors.java:515)
	at java.base/java.util.concurrent.FutureTask.runAndReset(FutureTask.java:305)
	at java.base/java.util.concurrent.ScheduledThreadPoolExecutor.run(ScheduledThreadPoolExecutor.java:305)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
	at java.base/java.util.concurrent.ThreadPoolExecutor.run(ThreadPoolExecutor.java:628)
	at java.base/java.lang.Thread.run(Thread.java:829)
a
Hi Artem, just to confirm- you experienced this error on 0.10. or 0.9.6.1?
I think this is likely a bug with container entity, we’ll see about getting something out
w
this seemed to be the fix I was looking for, thank you!