Hey Team, I changed some data model and get `*:met...
# troubleshoot
r
Hey Team, I changed some data model and get
*:metadata-service:restli-servlet-impl:checkRestModel* FAILED
issue. anyone has any idea of how to fix it?
Copy code
> Task :metadata-service:restli-servlet-impl:checkRestModel
[checker] 
[checker] idl compatibility report:
[checker] Incompatible changes:
[checker]   1) /collection/actions/batchIngest/parameters/entities/type: new union added members com.linkedin.metadata.snapshot.DataDocSnapshot
[checker]   2) com.linkedin.entity.Entity/value/com.linkedin.metadata.snapshot.Snapshot/ref/union: new union added members com.linkedin.metadata.snapshot.DataDocSnapshot, breaks old readers
[checker]   3) com.linkedin.metadata.aspect.VersionedAspect/aspect/com.linkedin.metadata.aspect.Aspect/ref/union: new union added members com.linkedin.datadoc.DataDocContent, com.linkedin.datadoc.DataDocInfo, com.linkedin.datadoc.EditableDataDocProperties, com.linkedin.metadata.key.DataDocKey, breaks old readers
[checker]   4) com.linkedin.metadata.aspect.VersionedAspect/aspect/com.linkedin.metadata.aspect.Aspect/ref/union: new union added members com.linkedin.datadoc.DataDocContent, com.linkedin.datadoc.DataDocInfo, com.linkedin.datadoc.EditableDataDocProperties, com.linkedin.metadata.key.DataDocKey, breaks old readers
[checker] 
[checker] [RS-COMPAT]: false
[checker] [MD-COMPAT]: false
[checker] [RS-I]:/collection/actions/batchIngest/parameters/entities/type: new union added members com.linkedin.metadata.snapshot.DataDocSnapshot
[checker] [MD-I]:com.linkedin.entity.Entity/value/com.linkedin.metadata.snapshot.Snapshot/ref/union: new union added members com.linkedin.metadata.snapshot.DataDocSnapshot, breaks old readers
[checker] [MD-I]:com.linkedin.metadata.aspect.VersionedAspect/aspect/com.linkedin.metadata.aspect.Aspect/ref/union: new union added members com.linkedin.datadoc.DataDocContent, com.linkedin.datadoc.DataDocInfo, com.linkedin.datadoc.EditableDataDocProperties, com.linkedin.metadata.key.DataDocKey, breaks old readers
[checker] [MD-I]:com.linkedin.metadata.aspect.VersionedAspect/aspect/com.linkedin.metadata.aspect.Aspect/ref/union: new union added members com.linkedin.datadoc.DataDocContent, com.linkedin.datadoc.DataDocInfo, com.linkedin.datadoc.EditableDataDocProperties, com.linkedin.metadata.key.DataDocKey, breaks old readers
[checker]
e
hey! could you run like this?
Copy code
./gradlew :metadata-service:war:build -Prest.model.compatibility=ignore
unfortunately adding new union members or enums are backward incompatible
but by building like ^ you should be able to bypass it
btw want to understand what you are adding here
are you adding a new aspect or a new entity?
in both cases, you don’t have to add it to unions any more
r
@early-lamp-41924 thanks for replying! Here is the RFC info thread 🙂
e
Awesome!! So now you don’t have to create unions for entities, and instead just add to this https://github.com/linkedin/datahub/blob/master/metadata-models/src/main/resources/entity-registry.yml
in that case, you won’t run into backward compatibility issue above!
Note that in ingestion you have to use the ingestProposal endpoint by sending in MCP (which don’t depend on the Snapshot union)
r
thanks for the info. You mean I do not need to change anything under
com.linkedin.metadata.snapshot
?
From the entity-registry.yml file, looks like I do not even need to change anything under
com.linkedin.metadata
e
Yes! You do need to add the aspect pdls themselves and the key aspect pdl
and then it’s just this registry
r
I do not need to extend the
Aspect.pdl
and I also do not need something like
DataDocAspect.pdl
?
Only register the new entity and aspects in the entity-registry.yml, right?
There will be tools/code building the python or java objects, right?
e
Yes!!
r
cool Thanks a lot!
BTW, normally how long should I expect some review for the RFC?
e
I’ll make sure it doesn’t get lost! Hoping we can close it next week
👍 1
thankyou1 1