It seems to me that there is one sense of each that is the same, and other senses that are quite different.
Looking at the differences, discernment seems to be about the ability to distinguish something.
In most cases discernment comes with practice and familiarity with something.
Often there is a sort of “cross fertilisation” between domains, as discernment developed in one domain is applied to another domain that is similar in some respect.
Judgement (in the different sense) seems to be more about weighing probabilities and outcomes associated with particular distinctions.
Thus discernment is more about being able to distinguish something, and judgment is more about knowing how to relate to that something, or how to relate that something with other things.