softvis-research / jqa-jira-plugin

This is a Jira parser for jQAssistant. It enables jQAssistant to scan and to analyze data from Jira.
GNU General Public License v3.0
5 stars 3 forks source link

[bug] "There is no existing transaction" #6

Open b-pos465 opened 4 years ago

b-pos465 commented 4 years ago

Environment

Using jQAssistant command line distribution 1.6.0. Active plugins:

2019-08-07 18:31:34.403 [main] INFO PluginConfigurationReaderImpl - Loaded jQAssistant plugins [CDI, Common, Core Analysis, Core Report, EJB3, GraphML, JAX-RS, JPA 2, JSON, JUnit, Java, Java 8, Jira, Maven 2 Repository, Maven 3, OSGi, RDBMS, Spring, TestNG, Tycho, XML, YAML].

Test run fails

I tried running the plugin against https://issues.apache.org/jira/projects/MNG/. The plugin failed two times at the same issue: MNG-5795.

The error seems to be related to jQAssistant:

2019-08-07 18:31:31.858 [main] INFO IssueBuilder - Processing issue with KEY: 'MNG-5795'
Exception in thread "main" com.buschmais.xo.api.XOException: There is no existing transaction.
        at com.buschmais.xo.neo4j.embedded.impl.datastore.EmbeddedNeo4jDatastoreTransaction.ensureTransaction(EmbeddedNeo4jDatastoreTransaction.java:47)
        at com.buschmais.xo.neo4j.embedded.impl.datastore.EmbeddedNeo4jDatastoreTransaction.commit(EmbeddedNeo4jDatastoreTransaction.java:28)
        at com.buschmais.xo.impl.XOTransactionImpl.commit(XOTransactionImpl.java:38)
        at com.buschmais.jqassistant.core.store.impl.AbstractGraphStore.commitTransaction(AbstractGraphStore.java:168)
        at com.buschmais.jqassistant.commandline.task.ScanTask.scan(ScanTask.java:137)
        at com.buschmais.jqassistant.commandline.task.ScanTask.executeTask(ScanTask.java:86)
        at com.buschmais.jqassistant.commandline.task.AbstractStoreTask.run(AbstractStoreTask.java:55)
        at com.buschmais.jqassistant.commandline.Main.executeTask(Main.java:259)
        at com.buschmais.jqassistant.commandline.Main.executeTasks(Main.java:208)
        at com.buschmais.jqassistant.commandline.Main.interpretCommandLine(Main.java:197)
        at com.buschmais.jqassistant.commandline.Main.run(Main.java:79)
        at com.buschmais.jqassistant.commandline.Main.main(Main.java:50)

I will try to wrap the plugin logic in a try - catch(Exception e) as there has been an issue with errors which have not been logged properly.

b-pos465 commented 4 years ago

The try - catch(Exception e) helps to identify the problem:

2019-08-07 18:43:44.376 [main] INFO IssueBuilder - Processing issue with KEY: 'MNG-5795'
RestClientException{statusCode=Optional.of(404), errorCollections=[ErrorCollection{status=404, errors={}, errorMessages=[Der Benutzer namens 'carej' existiert nicht]}]}

@DirkMahler: There seems to be an issue with the exception logging in jQAssistant 1.6.0. The uncaught RestClientException leads to a com.buschmais.xo.api.XOException with the message:

There is no existing transaction.

b-pos465 commented 4 years ago

If I go to the Web UI and open issue MNG-5795 I can see that the not found user carej is assigned to it. Furthermore, I can click on his name in one of the comments. This leads me to: https://issues.apache.org/jira/secure/ViewProfile.jspa?name=carej%40us.ibm.com. As we can see in the URL the name carej seems to exist in the Jira instance. I can even look at his profile and see his activities. Now why does JJRC tell me that this user does not exist? It should not be a permission problem as I can see his profile in the normal UI.