-
Notifications
You must be signed in to change notification settings - Fork 72
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
RuleManager.matchAs with two parameters - Object, T ruleListHandle throws NullPointerException #395
Comments
Ajit, is there a vaild need to pass in null? If not, I'm ok with this throwing a NullPointerException . . . that's common even within Java's core APIs. I prefer IllegalArgumentException but I'm not seeing a pressing need to change that everywhere. |
Sam, We have published the following method signature:
and that was the reason for the test. |
Here is a simple test method to reproduce the issue.
Here are the documents inserted into the database.
constraint2.xml
constraint3.xml
constraint4.xml
constraint5.xml
Rules written to the database are
Rule Name:- RULE-TEST-2
|
Ajit, can you tell me what writeDocumentUsingInputStreamHandle does? Or translate it into Java Client API code? |
Sam,
|
Good find, Ajit. |
Running the above test does not produce NullPointerException. |
(cherry picked from commit ebb5e8e)
When a test method uses the following snippet from RuleManager class
which is of the following JavaDocs description
JerseyServices class throws a NullPointerException. Here is the stack trace when the test method with above snippet is run.
JerseyServices' match might need to handle the case when no candidate rules are passed.
The text was updated successfully, but these errors were encountered: