java.lang.Exception

There are no available Samebug tips for this exception. Do you have an idea how to solve this issue? A short tip would help users who saw this issue last week.

  • h3. Summary JSON File Example provided on JIRA 7 documentation is not compatible with JIRA 7. h3. Steps to Reproduce Attempt to import a project using the JSON Source Example (_Project Key and Issue Key_) provided on [Importing data from JSON|https://confluence.atlassian.com/adminjiraserver071/importing-data-from-json-802592907.html#ImportingdatafromJSON-CreatingaJSONfileforImport] documentation {noformat} { "projects": [ { "name": "Sample data", "key": "SAM", "issues": [ { "key" : "SAM-123", "status" : "Open", "reporter" : "admin", "summary" : "Parent case", "externalId": "123" } ] } ] } {noformat} h3. Expected Results To have the project created and imported properly. h3. Actual Results The project is not imported since it's missing the project type, giving the error below: {noformat} 2016-06-10 15:08:07,044 INFO - ------------------------------ 2016-06-10 15:08:07,044 INFO - Importing: Users 2016-06-10 15:08:07,044 INFO - ------------------------------ 2016-06-10 15:08:07,044 INFO - Only new items will be imported 2016-06-10 15:08:07,044 INFO - 0 users associated with import. All of them imported as inactive, this can be changed after import in User Access step. 2016-06-10 15:08:07,044 INFO - ------------------------------ 2016-06-10 15:08:07,044 INFO - Finished Importing : Users 2016-06-10 15:08:07,044 INFO - ------------------------------ 2016-06-10 15:08:07,044 INFO - 0 users successfully created. 2016-06-10 15:08:07,044 INFO - Retrieving projects... 2016-06-10 15:08:07,045 ERROR - Unexpected failure occurred. Importer will stop immediately. Data may be in an unstable state java.lang.Exception: Unable to import Project ExternalProject{id='null', key='SAM', externalName='null', name='Sample data'} at com.atlassian.jira.plugins.importer.imports.importer.impl.DefaultJiraDataImporter.importProject(DefaultJiraDataImporter.java:648) at com.atlassian.jira.plugins.importer.imports.importer.impl.DefaultJiraDataImporter.doImport(DefaultJiraDataImporter.java:357) at com.atlassian.jira.plugins.importer.imports.importer.impl.ImporterCallable.call(ImporterCallable.java:26) at com.atlassian.jira.plugins.importer.imports.importer.impl.ImporterCallable.call(ImporterCallable.java:15) at com.atlassian.jira.task.TaskManagerImpl$TaskCallableDecorator.call(TaskManagerImpl.java:538) at com.atlassian.jira.task.TaskManagerImpl$TaskCallableDecorator.call(TaskManagerImpl.java:501) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at com.atlassian.jira.task.ForkedThreadExecutor$ForkedRunnableDecorator.run(ForkedThreadExecutor.java:254) at java.lang.Thread.run(Thread.java:745) Caused by: com.atlassian.jira.plugins.importer.external.ExternalException: Unable to create project: ExternalProject{id='null', key='SAM', externalName='null', name='Sample data'} at com.atlassian.jira.plugins.importer.managers.CreateProjectManagerImpl.createProject(CreateProjectManagerImpl.java:95) at com.atlassian.jira.plugins.importer.imports.importer.impl.DefaultJiraDataImporter.importProject(DefaultJiraDataImporter.java:633) ... 10 more Caused by: com.atlassian.jira.exception.CreateException: An invalid project type was specified. Unfortunately you can't create a project without a project type. Please talk to your JIRA administrator for help. at com.atlassian.jira.plugins.importer.managers.CreateProjectManagerImpl.createProject(CreateProjectManagerImpl.java:82) ... 11 more 2016-06-10 15:08:07,045 INFO - No issues need to be reindexed. {noformat} h3.Solution / Workaround Include the project type as per JSON below: {noformat} { "projects": [ { "name": "Sample data", "key": "SAM", "type": "software", "issues": [ { "key" : "SAM-123", "status" : "Open", "reporter" : "admin", "summary" : "Parent case", "externalId": "123" } ] } ] } {noformat}
    via by Luciano Fagundes [Atlassian],
    • java.lang.Exception: Unable to import Project ExternalProject{id='null', key='SAM', externalName='null', name='Sample data'} at com.atlassian.jira.plugins.importer.imports.importer.impl.DefaultJiraDataImporter.importProject(DefaultJiraDataImporter.java:648) at com.atlassian.jira.plugins.importer.imports.importer.impl.DefaultJiraDataImporter.doImport(DefaultJiraDataImporter.java:357) at com.atlassian.jira.plugins.importer.imports.importer.impl.ImporterCallable.call(ImporterCallable.java:26) at com.atlassian.jira.plugins.importer.imports.importer.impl.ImporterCallable.call(ImporterCallable.java:15) at com.atlassian.jira.task.TaskManagerImpl$TaskCallableDecorator.call(TaskManagerImpl.java:538) at com.atlassian.jira.task.TaskManagerImpl$TaskCallableDecorator.call(TaskManagerImpl.java:501) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at com.atlassian.jira.task.ForkedThreadExecutor$ForkedRunnableDecorator.run(ForkedThreadExecutor.java:254) at java.lang.Thread.run(Thread.java:745) Caused by: com.atlassian.jira.plugins.importer.external.ExternalException: Unable to create project: ExternalProject{id='null', key='SAM', externalName='null', name='Sample data'} at com.atlassian.jira.plugins.importer.managers.CreateProjectManagerImpl.createProject(CreateProjectManagerImpl.java:95) at com.atlassian.jira.plugins.importer.imports.importer.impl.DefaultJiraDataImporter.importProject(DefaultJiraDataImporter.java:633) ... 10 more Caused by: com.atlassian.jira.exception.CreateException: An invalid project type was specified. Unfortunately you can't create a project without a project type. Please talk to your JIRA administrator for help. at com.atlassian.jira.plugins.importer.managers.CreateProjectManagerImpl.createProject(CreateProjectManagerImpl.java:82) ... 11 more
    No Bugmate found.