Click to see the query in the CodeQL repository
A Javadoc @throws or @exception tag that references an exception that cannot be thrown is misleading.
Ensure that you only include the @throws or @exception tags in Javadoc when an exception can be thrown.
The following example shows a method with Javadoc that claims it can throw Exception. Since Exception is a checked exception and the method does not declare that it may throw an exception, the Javadoc is wrong and should be updated.
In the following example the Javadoc has been corrected by removing the @throws tag.
Java SE Documentation: How to Write Doc Comments for the Javadoc Tool,