-
Notifications
You must be signed in to change notification settings - Fork 55
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
Metadata Integration #242
Metadata Integration #242
Conversation
276d567
to
61ab410
Compare
@gaurabdg , same as in sonar plugin, please provide prove (screenshots) that new file is taken in priority over existed config. |
@gaurabdg , please add one more metafile with Tokens, we need few very different and representative files in this PR. |
61ab410
to
a8329c2
Compare
@gaurabdg , make it regular PR.
I do not see screenshots for this. Please also show that configured Checks are running fine. |
416a11f
to
ff6f1a0
Compare
@@ -12,6 +12,12 @@ | |||
<attribute name="test" value="true"/> | |||
</attributes> | |||
</classpathentry> | |||
<accessrules> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is this change for?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My IDE build failed for these cases, thats why I had to add them
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
test of sevntu is must do.
we have to make sure that we are backward compatible.
ff6f1a0
to
40b72f4
Compare
Please check description, I have provided screenshots. |
40b72f4
to
8464c1d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
https://user-images.githubusercontent.com/23253816/89645628-ce5d2300-d8d7-11ea-9bc0-1ba6b9e3913e.png - does not prove that sentu works, please share that metadata is loaded for any Check and and you can configure it in UI and it executes.
items:
Done |
8464c1d
to
7258760
Compare
f530c45
to
b757a08
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
items:
net.sf.eclipsecs.core/src/net/sf/eclipsecs/core/config/meta/CheckUtil.java
Outdated
Show resolved
Hide resolved
net.sf.eclipsecs.core/src/net/sf/eclipsecs/core/config/meta/CheckUtil.java
Outdated
Show resolved
Hide resolved
net.sf.eclipsecs.core/src/net/sf/eclipsecs/core/config/meta/CheckUtil.java
Outdated
Show resolved
Hide resolved
net.sf.eclipsecs.core/src/net/sf/eclipsecs/core/config/meta/MetadataFactory.java
Outdated
Show resolved
Hide resolved
net.sf.eclipsecs.core/src/net/sf/eclipsecs/core/config/meta/MetadataFactory.java
Outdated
Show resolved
Hide resolved
net.sf.eclipsecs.core/src/net/sf/eclipsecs/core/config/meta/MetadataFactory.java
Outdated
Show resolved
Hide resolved
net.sf.eclipsecs.core/src/net/sf/eclipsecs/core/config/meta/MetadataFactory.java
Outdated
Show resolved
Hide resolved
net.sf.eclipsecs.core/src/net/sf/eclipsecs/core/config/meta/MetadataFactory.java
Outdated
Show resolved
Hide resolved
net.sf.eclipsecs.core/src/net/sf/eclipsecs/core/config/meta/MetadataFactory.java
Outdated
Show resolved
Hide resolved
b757a08
to
ebecc9f
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please remove from commit net.sf.eclipsecs.core/lib/metadata-gen-1.0-SNAPSHOT.jar
please make sure you never have it.
Item:
net.sf.eclipsecs.core/src/net/sf/eclipsecs/core/config/meta/MetadataFactory.java
Show resolved
Hide resolved
net.sf.eclipsecs.core/src/net/sf/eclipsecs/core/config/meta/CheckUtil.java
Outdated
Show resolved
Hide resolved
ebecc9f
to
40699ac
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
items:
net.sf.eclipsecs.core/src/net/sf/eclipsecs/core/config/meta/MetadataFactory.java
Outdated
Show resolved
Hide resolved
net.sf.eclipsecs.core/src/net/sf/eclipsecs/core/config/meta/MetadataFactory.java
Outdated
Show resolved
Hide resolved
net.sf.eclipsecs.core/src/net/sf/eclipsecs/core/config/meta/MetadataFactory.java
Show resolved
Hide resolved
net.sf.eclipsecs.core/src/net/sf/eclipsecs/core/config/meta/MetadataFactory.java
Outdated
Show resolved
Hide resolved
net.sf.eclipsecs.core/src/net/sf/eclipsecs/core/config/meta/MetadataFactory.java
Outdated
Show resolved
Hide resolved
net.sf.eclipsecs.core/src/net/sf/eclipsecs/core/config/meta/MetadataFactory.java
Outdated
Show resolved
Hide resolved
net.sf.eclipsecs.core/src/net/sf/eclipsecs/core/config/meta/MetadataFactory.java
Outdated
Show resolved
Hide resolved
net.sf.eclipsecs.core/src/net/sf/eclipsecs/core/config/meta/MetadataFactory.java
Outdated
Show resolved
Hide resolved
net.sf.eclipsecs.core/src/net/sf/eclipsecs/core/config/meta/MetadataFactory.java
Outdated
Show resolved
Hide resolved
40699ac
to
d25e4aa
Compare
net.sf.eclipsecs.core/src/net/sf/eclipsecs/core/config/meta/CheckUtil.java
Outdated
Show resolved
Hide resolved
net.sf.eclipsecs.core/src/net/sf/eclipsecs/core/config/meta/CheckUtil.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
one item in not resolved from top.
few more minors:
net.sf.eclipsecs.core/src/net/sf/eclipsecs/core/config/meta/MetadataFactory.java
Outdated
Show resolved
Hide resolved
d25e4aa
to
6eb6e0a
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Items'
net.sf.eclipsecs.core/src/net/sf/eclipsecs/core/config/meta/MetadataFactory.java
Outdated
Show resolved
Hide resolved
net.sf.eclipsecs.core/src/net/sf/eclipsecs/core/config/meta/MetadataFactory.java
Outdated
Show resolved
Hide resolved
net.sf.eclipsecs.core/src/net/sf/eclipsecs/core/config/meta/MetadataFactory.java
Outdated
Show resolved
Hide resolved
6eb6e0a
to
67aab10
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Calixte , please finalize review.
The plugin is broken since this PR. Adding checks through the UI doesn't work anymore. |
ModuleDetails moduleDetails) { | ||
RuleMetadata modifiedRuleMetadata = new RuleMetadata( | ||
ruleMetadata.getRuleName(), moduleDetails.getFullQualifiedName(), | ||
moduleDetails.getParent(), ruleMetadata.getDefaultSeverityLevel(), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
moduleDetails.getParent()
will return the full qualified name of the parent, while RuleMetadata
expects the simple name of the parent. This breaks the plugin.
Draft PR to track progress
PoC
As you can see module description, tokens/enum values are all working perfectly after making the commit changes.
Before:
![Screenshot_20200724_035832](https://user-images.githubusercontent.com/23253816/88344978-87612080-cd62-11ea-8682-5689448948c0.png)
![Screenshot_20200724_035725](https://user-images.githubusercontent.com/23253816/88344995-90ea8880-cd62-11ea-9ad2-1e0882936ac0.png)
After:
Overall working of the plugin
Before:
![Screenshot_20200727_102355](https://user-images.githubusercontent.com/23253816/88504878-901c5580-cff3-11ea-9b35-1187b606bf27.png)
After:
![Screenshot_20200727_102326](https://user-images.githubusercontent.com/23253816/88504885-93afdc80-cff3-11ea-9abd-e28d4371a83b.png)
Working of
createMeta()
- Modules which are not present in the eclipse-cs metafiles, are directly fetched from checkstyle, hence proving that we dont need to update the files manually(as has been done in #245).Here, the eclipse-cs meta files are the
master
ones, but the checkstyle JAR versionin this PR is 8.35, where a new checkPatternVariableName
was introduced. You can see that it is reflecting properly.SevNTU is working as before, not being affected by these changes
Updated metadata is also showing up for those checks having
checkstylemeta-.*
file name in the sevntu repo(PR: sevntu-checkstyle/sevntu.checkstyle#821). Hence proving third party module integrationCustom config having only
Empty Public Ctor in Class Check