Custom SonarQube plugin activated at server startup - plugins

I developed a custom SonarQube widget as a plugin which is able to synchronize the LDAP groups to the SonarQube database when the user press a button. source:
https://github.com/bakaibalazs/SonarQube-LDAPGroup-Synchronizer
I would like to execute this synchronization process every time when the server starts up. Is it possible? What is the preferred way to code is as a custom extension?
Thanks.

This is possible and should be implemented using the specific ServerExtension ServerStartHandler.

Related

How to customize share user interface of Alfresco 7.2 installed using Docker

I installed Alfresco Communiy 7.2 using Docker compose on Ubuntu 20.04. I want to customize the Share interface, such as changing default logos, share login page, a custom UI theme, etc.
My question is:
How can I do this, which files are affected and how can I modify them?
Thanks for your help
First you need to learn Alfresco SDK.
This is used to make customization in alfresco and generate jar/amp which we can deploy so original file will remain untouched and through override technique we can achive.
https://docs.alfresco.com/content-services/6.0/develop/sdk/

Unable to Finish connecting to SonarQube server

This is going to sound like a ridiculous question, but using the SonarLint Eclipse plugin (v3.2.0) on the latest Eclipse (Oxygen), I am unable to add a new SonarQube server connection.
I am working behind a company firewall, but that doesnt appear to be an issue. I am following the steps here and am able to successfully connect to our internal SonarQube instance, provide my credentials, but it is just on the final step, that the 'Finish' button does not seem to do anything, see screen below:
I appreciate there is probably some background processes need to run in order for this Finish to actually finish :) But this doesnt appear to be doing anything...Anyone else experience this issue?
Any before people ask, I've restarted Eclipse/laptop, uninstalled and reinstalled SonarLint plugin etc.
Thanks in advance!
SonarLint in Eclipse are storing credentials in Eclipse secure storage that itself is protected by a master password. So you must reset it or delete it to add a new SonarQube server connection. You can try this step :
In your Eclipse Go to Window > Preferences, filter and find Secure Storage.
In the Tab Contents find and highlight org.sonarlint.eclipse.core, click Delete > Apply > OK. After deletion process is finished, Eclipse will ask if you want to restart the IDE. It is strongly recommended that you restart the IDE and try again to adding SonarQube server in Eclipse.
Thanks.
On my linux machine I had the same issue, because the used master password provider doesn't work properly.
This answer worked for me:
Open Window > Preferences
Go to General > Security > Secure Storage
At Master password providers uncheck the used provider. The enabled provider with the highest priority is the used one [for me it was "Linux Integration (64 bit)"].
Click apply
I also encountered this problem, but was able to work around it.
This is environment in which I was running:
Eclipse Oxygen.1
Linux VM (VirtualBox) on Windows host
Solution that worked for me based on this post:
Uninstall SonarLint.
Reinstall using Help -> Install new software...
On the Install dialog, un-check the option "Show only the latest versions of available software"
Select the older version of SonarLint.
Select Next and continue with the install.
After installing, configure your SonarQube server like normal.
Upgrade to the latest version of SonarLint via Help -> Check for Updates
In my case the problem also concerned the credentials storage but was caused by the Avecto Defendpoint Client. The company restricted the permissions to create subfolders in user home (c:\users<username>). I had to create manually missing subfolders (.sonarlint and .eclipse) after access level elevation and after filling the reason in a text field. Then I had to give the permissions to those folders for myself. Having created them I could proceed with adding server to sonarlint plugin.

Bluemix - Can't select space in boilerplate

[Edited with new info]
I have created some spaces under my organization name in Bluemix successfully, using both Bluemix web interface & CLI.
I was trying to create an app from IoTFoundation Boilerplate by clicking the icon on the catalog. It leads me to the introduction page, and at the right hand side I was asked to select Space, Name, Host domain etc.
My problem is though I have spaces created and shown successfully in the Bluemix web interface, it is NOT POSSIBLE for me to select the space in the boilerplate. [new info: After > 10 minutes of creating the space using CLI, it finally appears in the boilerplate, however, the spaces created using Bluemix web interface doesn't appear even after a day...].
May I know what is the possible cause in this case?
Thanks in advance for any advise.
BRs,
KH
Generally, to fix this kind of issue follow these steps:
logout
close browser
clean the cache and login in Bluemix console
If the issue is still there open a support request directly from your Bluemix console or you can open a new ticket here: https://support.ng.bluemix.net/gethelp/ .

Logging in Talend ESB

We had a web service developed in Talend and deployed in TAC(Talend runtime). Service is working fine on the local system but not after the deployment.We had tried various methods to debug it like placing the logger component and putting logging mechanism in Java component of Talend but those messages are not populating in the log file.Please suggest.
Talend Enterprise 5.6 comes with log4j logging. (It can be enabled in the project settings.) Maybe open studio has this feature as well.
If you activate that and start the logserver (based on Kibana / Logstash) you could have a web interface that shows the log messages in real-time, across all the deploys you have.
We're using this approach for development and some production projects. It tells you all the SQL-s connection details, execution times, records fetched, etc..
In TAC you should see the same logs if you click on the magnifier button on the corresponding job on Job Conductor tab. In case if it's empty, check the log4j setting in File->Edit Project Properties->Log4J, and make sure that the default CONSOLE appender is enabled. Also try to build the project manually, and check the log4j.properties in the built zip file.
Finally check the log level at the job properties on TAC->Job Conductor, and make sure it set to the right level.

Why do we need to restart the CRM server after registering the custom workflow using Plugin Registration tool to make that work properly

Can we have any alternative way to make run-able the custom Workflow activity in Workflow steps.
All the time what I do is register the dll using Plugin registration tool and then restart the server. Then only we can use the custom workflow activity on Workflow.
I have tried after restarting the IIS and hoping so it'll be done but no luck.
All the time restarting server should not be any solution. Is there any alternative way for it please suggest. All you are suggestion would be greatly appreciated.
1) You do not need to restart IIS; restart the application pool (its far faster and doesn't disrupt other applications that might be running on the server; by default its the 'CrmAppPool') using the command:
%systemroot%\system32\inetsrv\appcmd recycle apppool CrmAppPool
2) Similarly, you can recycle the async process by running (powershell):
Restart-Service -displayname "Microsoft Dynamics CRM Asynchronous Processing Service"
3) Both of these commands can be run remotely using the powershell command:
powershell Invoke-Command [CrmServerName] -ScriptBlock { ["Restart-Service...."] }
4) You do not need to deploy to the server to debug plugins. Its far easier/faster to create a test harness. The link below outlines how to setup a dev environment for unit testing.
How I develop and unit test CRM 2011 plugins
CRM caches the dlls, restarting the services causes it to refresh those caches.
If you register a synchronous plugin then you need to reset IIS.
If you register an asynchronous plugin or custom workflow activity you need to reset the asynchronous service.
We don't need to restart the server to make it run the plug-in code, the only thing is you need to restart IIS after that.
Try restart IIS and then restart the asynchronous service, this must be the only thing necessary.
The point here is very specific -
It's not only true for the CRM, but is also true for any web application hosted on IIS. Web App (CRM for you case) caches dlls for the very first time when the message is executed (plugin message/event - Although this is done by .net platform internally, so to address the other similar calls more efficiently.). So, in that case you need to flush off the synced thing from your web app. And that is why you need to recycle app pool (SMART WAY -> for single application flush, and without impacting other applications on the server, you should always go for APPPOOL Recycle instead to IIS restart.)
For this, what I would suggest you is to write a powershell script to recycle AppPool for your application and trigger it on Post build event of your project (plugin project) in VS. So, that will make your process automated and will reduce your efforts to much lesser.
Regarding custom WF assembly, Since it executes under Async. Service, so you need to discard off the cached content from here as well.
Hope this helps!
You shouldn't need to restart anything.
What you need to do is increment the build number of the assembly you are updating each time you deploy it.
This makes sure that CRM knows not to use it's cached version but to load the updated one the database
If you want to see the CWAs without any need of restarts just select the activity in the plugin registration tool and press the "save" button below the properties