Skip to content
This repository has been archived by the owner on Jul 13, 2022. It is now read-only.

BeanCreationException while launching the jenkins-codequality-3.1.0-SNAPSHOT.jar #5

Open
sunabala opened this issue Aug 28, 2019 · 8 comments

Comments

@sunabala
Copy link

application.properties.txt
Hi,

I built hygieia-codequality-jenkins-collector and deployed using the below command:
java -jar jenkins-codequality-3.1.0-SNAPSHOT.jar --spring.config.name=jenkins-codequality --spring.config.location=..\application.properties
I am getting the BeanCreationException. Attached is my application.properties file and the error message. Please help.
image
image
image

Thanks,
Sunandha Ramasamy

@rvema
Copy link
Contributor

rvema commented Aug 28, 2019

@sunabala Can you add bigger screenshots. I am unable to see the error.

@sunabala
Copy link
Author

ErrorPage1
ErrorPage4
ErrorPage3
ErrorPage2

@sunabala
Copy link
Author

@rvema I have uploaded the bigger screenshots. Please let me know if these are visible.

@rvema
Copy link
Contributor

rvema commented Aug 29, 2019

@sunabala looks like its unable to locate the properties file. Can you give full path to properties file while launching the collector

@sunabala
Copy link
Author

@rvema, I had provided the complete path to properties file while launching the collector... Still the issue exists.

@sunabala
Copy link
Author

On further debugging, found that this.settings.getCron() call in public String getCron() method of JenkinsCodeQualityCollectorTask.java is null. What needs to be done for this to work?

@rvema
Copy link
Contributor

rvema commented Sep 20, 2019

the cron property is not properly formed or the property file is unable to be read. Can you check if other properties mentioned in the application.properties are read?

@sunabala
Copy link
Author

Yes it is reading the application.properties file. It is able to establish the connection with MONGO DB based on the DB credentials provided in the properties file.
This is the content of the properties file:

Database Name

dbname=dashboarddb

Database HostName - default is localhost

dbhost=localhost

Database Port - default is 27017

dbport=27017

MongoDB replicaset

dbreplicaset=false
dbhostport=localhost:27017

Database Username - default is blank

dbusername=dashboarduser

Database Password - default is blank

dbpassword=dbpassword

Collector schedule (required)

jenkins-codequality.cron=0 0/1 * * * *

Collector servers (required) - can be multiple

jenkins.servers[0]=https://jenkins.company.com

Collector types (note not required, but the regex should be match only the type specified)

jenkins-codequality.artifactRegex.junit=TEST-.*\.xml
jenkins-codequality.artifactRegex.findbugs=findbugsXml.xml
jenkins-codequality.artifactRegex.pmd=pmd.xml
jenkins-codequality.artifactRegex.checkstyle=checkstyle-result.xml
jenkins-codequality.artifactRegex.jacoco=jacoco.xml

Collector job depth (required) should be set to at least 1, and more if you use folder jobs etc

jenkins-codequality.jobDepth=4

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

No branches or pull requests

2 participants