Skip to content
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

refactor: restructure project to load Sorald as a service using Java SPI #808

Merged
merged 13 commits into from
May 20, 2022

Conversation

algomaster99
Copy link
Member

@algomaster99 algomaster99 commented May 18, 2022

@MartinWitt, thanks for your work, first of all. It is a great milestone toward integrating the Qodana static analyzer and development in general, as the code quality has definitely increased.

Let's work towards merging this now because there is feature request #807 that require a lot of code movement. I feel it is better to start working on top of the changes in this PR to avoid dealing with merge conflicts later. Some things that need to be done before we merge this PR:

@MartinWitt , please give your opinions about subtasks 2 and 3. Once all of them are resolved, we can proceed to merge. Note that this PR will not be squashed as each commit is an atomic change in itself.

* chore: fix Sonar scan in CI

* Try skipping Sonar for sub modules

* Force Sonar analysis

* Prevent skipping of sonar scan

* Run Sonar scan only to speed up debugging process

* Assign SpoonLabs_sorald to parent module

* Distinguish modules by module key

* Compile project for Sonar to use

* Run tests only for Ubuntu

* Revert "Run tests only for Ubuntu"

This reverts commit 01c8c3d.

* Revert "Compile project for Sonar to use"

This reverts commit 6f13c61.

* Revert "Distinguish modules by module key"

This reverts commit 1aca72d.

* Revert "Assign SpoonLabs_sorald to parent module"

This reverts commit e8aa9dd.

* Revert "Run Sonar scan only to speed up debugging process"

This reverts commit e08d9ba.

* Revert "Prevent skipping of sonar scan"

This reverts commit 3d8aa20.

* Revert "Force Sonar analysis"

This reverts commit 64e5d47.

* Revert "Try skipping Sonar for sub modules"

This reverts commit 37de1c0.

* Revert "chore: fix Sonar scan in CI"

This reverts commit 96e2736.

* Add moduleKey to sonar configuration
* Publish usage docs in the root of the repository

* Document completion options for `MineCommand.ruleTypes`

* Dogfooding Sorald

* Please spotless
* Use APIs defined in RuleRepository in RuleProvider

* Use valid syntax to document return value of RuleProvider.inferRules

* Test all cases defined in RuleProvider.inferRules

* Rename test class to match the API definition
@algomaster99
Copy link
Member Author

algomaster99 commented May 20, 2022

Merging this PR as it is needed to implement some requested features. I have fixed whatever was necessary. I have not tested the deployment of SNAPSHOT version and it may fail, but I don't have access to its credentials as of now. However, @monperrus , @slarse, and I have had a discussion over this. If there is a need to revoke the tokens, I will create an OSSRH account chains-bot with email chains@eecs.kth.se.

The SonarCloud scan is failing, but I am unsure why. The conditions for failure it presents persist in the master branch as well. Hence, I am classifying it as false-positive. Proceeding via Merge pull request.

EDIT:

The deployment worked! 😱 See https://github.com/SpoonLabs/sorald/runs/6524990778?check_suite_focus=true.
I have no idea why. I need to figure out how it knew that it had to deploy sorald (which is not a submodule). There were sorald-parent and sorald-api as well, but neither the maven plugin tried to deploy their jar nor it threw any error.

@algomaster99 algomaster99 merged commit 50b5ec6 into master May 20, 2022
@algomaster99 algomaster99 deleted the spi branch May 20, 2022 12:47
@algomaster99
Copy link
Member Author

Thanks for your work, @MartinWitt ! It is an advancement towards the integration of the Qodana static analyzer.

@monperrus
Copy link
Contributor

Yes! Thanks @MartinWitt

@monperrus
Copy link
Contributor

I will create an OSSRH account chains-bot with email chains@eecs.kth.se

excellent initiative 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants