ConsumeEvent (blocking=true) is running on executor-thread - quarkus

Quarkus Version 2.1.2.Final
When running in quarkusDev everything is running in the correct thread (vert.x-worker-thread-x) and is even obeying the quarkus.vertx.worker-pool-size property as I would expect.
When running the quarkus-app that is built from the build task I am seeing the thread of execution as (executor-thread-x).
Not sure why the thread of execution is changing when running the application after it's been built vs running in quarkusDev. As an aside I am using the exact same properties for both the quarkusDev and running the output of the build task.
I have created a sample project that showcases the above described issue. (https://github.com/owlkaboom/quarkus-threading-question) This sample project uses 2.2.1-final since I wanted to see if this was resolved in a later release.
You will notice it "submits 500" items into an eventbus which when you run it with quarkusDev you will notice it is actually using the worker-threads correctly and obeying the pool size limits.
When you build and run via java -jar you will now notice it does not obey worker-threads and just runs on the executor-thread instead.

The above mentioned issue is not expected behavior. Opened a new GitHub issue (https://github.com/quarkusio/quarkus/issues/19911).
This is not expected behavior and once the GitHub issue has been resolved / merged this behavior should no longer be happening.

Related

SpringBoot Kotlin project wont run and debug from Intellij

We have inherited a SpringBoot project written in Kotlin. Using Intellij, I would expect to be able to go to the Application main method and click the green arrow to start the project. I would also expect to be able to run the project in debug mode and set breakpoints, this only works with tests.
When I try and run the project I get a exception FileNotFound which has yielded me no answers. Every file appears to be accounted for and there is clearly nothing missing.
This is a multi-module gradle project with many unique configurations and I suspect one is causing an issue. I am having trouble determining which configuration is causing the issue because the project doesn't even seem to get to the point of standing up Spring (no banner).
I have tried many different combinations of bash scripts, environment variables, and gradle tasks and the project does not seem to run at all. Is there any way I can use Intellij to debug the sequence of configurations and gradle tasks?
So, I am answering my own question because searches lead me nowhere and this was a surprisingly difficult problem to debug. It turns out I was taking the wrong approaches and asking the wrong questions. I took a lot of time to study up on Spring configurations and Gradle tasks to realize none of our stuff was wrong. The Kotlin compiler was failing at the very beginning.
What had happened was one developer naively cd'ed into the Application's module and ran an echo statement that piped gradle output to a file called out with no extensions.
Kotlin would find this file and then proceed to not compile anything starting at the Application main. When we ran the app from terminal the app would recompile itself from the very beginning with no problems. But the automatically generated Intellij config simply ran the app with the bad file every time.
The troubling part was that our .gitignore file was configured to ignore all of the kotlin /out/ directories, but not files like /out so this troublesome file was committed to the repository for quite a while.
Surprisingly, deleting this out file fixed most of the issues our project had with Intellij.
Another note:
Our script was also set to source certain variables from other scripts, which meant we either had to carry them over to the runtime configs. We could also run Intelli from the same terminal we had already sourced the script in (using Tools> Create command line launcher). Once I had that sorted the project ran and debugged perfectly.

TeamCity keeps using the same agent if it fails

My current TeamCity setup has several agents with pretty much the same configuration and all of them are also eligible for running the builds. However, I have noticed that TeamCity keeps scheduling runs on the same agent in a roll, even if the build fail. Actually, it happens only when it fails. Is this a known behaviour or a bug? Is there any way to change such configuration?
Check your "Agent Requirements" in the build conf according to https://confluence.jetbrains.com/display/TCD8/Agent+Requirements

Running all featurefiles together in maven goal failing

I am trying to run multiple feature files through maven goal(command line) but after 2 feature files that run successfully, the other feature files (3rd one onwards) fails in some test cases which when ran independently passes all the test cases.
So f I run each feature file individually I get proper results but running them all together gives wrong results.
We are using serenity framework with cucumber jvm. Please help how can we resolve this issue.
Your failing tests fail to fully setup the context. Some state is leaking from the previous ones. Look for what has changed during the first runs (database/mocks/whatever state) that has to be reset before running the third and following.

SonarQube 5.1 fails execution with message "The project already being analyzed"

We have had occurrences where a SonarQube job is running for hours, appears to be hung with no ETA on its completion in our CI environment. We have used a workaround solution of not only aborting the build job, but there seems to be a secondary process executing SonarQube on the CI agent itself. I have read that specifying sonar.forceAnalysis=true should resolve the issue but this has been deprecated as of version 3.X and there is no need to use this analysis parameter. We would like to be able to proactively address this and not have to respond after a team running SonarQube notifies us of this issue. Is there some way of specifying a timeout where the process running the analysis will just terminate?
If you are looking for killing the analysis running in your CI environment after a certain time, I would suggest you look into the feature offered by your CI environment.
There is no such thing in SonarQube.
As a side note, you should have a look into the upcoming 5.2 release of SonarQube. We have cut the connection to the database from the analyzer which means the error “The project already being analyzed” can not occur any more. In addition, quite a bunch of work done by the analysis job has been moved to the server which allow it to run faster.

Sonar runner exit code is always 0

I use Sonar through the sonar runner client. Actually, I call it from NAnt build system, and the NAnt exec call should fail in case the exit code is not 0.
However, I've recently faced with an issue that sonar runner always returns 0 exit code, even if one of the plugins (e.g. NDeps) throws exception. As far as I can see, the analysis data is not committed to the database in this case, hence it is a good reason to fail.
I seem to remember that one of the previous versions of Sonar / Sonar runner used to behave the way I expected - in case a plugin fails, the exit code was not 0.
Today I use Sonar 3.2 / Sonar runner 2.0 / C# Ecosystem 1.4, which is all the latest as far as I can see.
Is there a configuration flag somewhere to return proper exit codes? Any other workaround to this issue?
For information: discussion happened on this topic is currently happening on Sonar User mailing-list. It can be followed here: http://sonar.15.n6.nabble.com/Sonar-runner-exit-code-is-always-0-tt5003433.html
EDIT: after investigation with Yan, it turns out that the Sonar BAT script behaves differently depending on the vesion of Windows that is used. Yan has suggested a way to fix this, and a ticket has been opened for next version of the Sonar Runner.

Resources