Using MetaType.getPrimaryKey as MetaObject's PrimaryKey expect StateMachineObject

1. add relationship between RelationMetadata and RelationObject
Merge remote-tracking branch 'upstream/master'
Fix findRelation logic: Once findRelation from composite state, OwningStateMachine should also be considered
Merge remote-tracking branch 'upstream/master'