This is looking quite weird and could actually be a bug: I changed the EL expression to
someStaticKeyand now it works. Therefore, the EL must really evaluate to null for some reason. However, within the method, the same EL (copy-paste) evaluates to the intended string (myKey) that is also printed in the log output.
Am I doing something wrong or does this look like a bug to you too?
maybe You have 2 instances of mycomponent somewhere in your app and the annotation gets a different instance than the value expression?
Try printing the hashCode() of the instance in the getMemberField() method and compare them for both calls.