Is the X-Forwaded-For request header being set when the request gets sent out from the loadbalancer? Also, which exact version of JBoss AS/WildFly was this working fine previously? WildFly 10 uses Undertow as its underlying web container and I remember there was a bug in some specific case where this header was being overwritten in the container.
On a slightly related note, WildFly 11.0.0.Final has been released and if that's something that you can upgrade to, then it would be good to try this on that version WildFly 11 Final is now available! · WildFly