RESTEASY-795 for trunk
Merge pull request #255 from liweinan/RESTEASY-795,trunk,redo

RESTEASY-795 for trunk