demand that ComponentMetadataDetails parameter comes first in component metadata rule (REVIEW-4849)

- also throw more appriate exceptions