stable

Clone or download

Read-only

chore(jira): Unify detection of JiraCloud vs JiraServer

2 implementations were made, one based on the domain name and another one based the status of API endpoint. This refactoring aligns on the second approach as we don't know if domain name is reliable enough. The refactoring is huge because of the initial design of ClientWrapper that was embedding the builder in itself and the dependency on the implementation along the stack. As we now need to know at build time the type of remote jira server AND that we have to connect to the target Jira server to detect that, the ClientWrapperBuilder is now a bit magical because it requires a closure so the build is done really "just in time". Part of: request #22580 Get list of jira projects doesnt work with Jira Server Change-Id: I64cf453771b10d6a042080402c33f04f8c522671

Modified Files

Name
M plugins/jira_import/include/Project/CreateProjectFromJira.php +0 −1 Go to diff View file
M plugins/jira_import/include/Project/CreateProjectFromJiraCommand.php +1 −1 Go to diff View file
M plugins/timetracking/tests/unit/JiraImporter/Configuration/JiraTimetrackingConfigurationRetrieverTest.php +15 −25 Go to diff View file
M plugins/tracker/include/Tracker/Creation/JiraImporter/AsynchronousJiraRunner.php +2 −26 Go to diff View file
D plugins/tracker/include/Tracker/Creation/JiraImporter/Client/JiraHTTPClientBuilder.php +0 −50 Go to diff View file
M plugins/tracker/include/Tracker/Creation/JiraImporter/ClientWrapper.php +64 −54 Go to diff View file
M plugins/tracker/include/Tracker/Creation/JiraImporter/ClientWrapperBuilder.php +18 −2 Go to diff View file
M plugins/tracker/include/Tracker/Creation/JiraImporter/FromJiraTrackerCreator.php +4 −4 Go to diff View file
M plugins/tracker/include/Tracker/Creation/JiraImporter/Import/Artifact/Attachment/AttachmentDownloader.php +5 −38 Go to diff View file
M plugins/tracker/include/Tracker/Creation/JiraImporter/Import/JiraXmlExporter.php +22 −130 Go to diff View file
M plugins/tracker/include/Tracker/Creation/JiraImporter/Import/Structure/JiraFieldRetriever.php +2 −12 Go to diff View file
M plugins/tracker/include/Tracker/Creation/JiraImporter/Import/User/JiraUserInfoQuerier.php +3 −13 Go to diff View file
M plugins/tracker/include/Tracker/Creation/JiraImporter/JiraClient.php +4 −0 Go to diff View file
R plugins/tracker/include/Tracker/Creation/JiraImporter/JiraInstanceURLChecker.php Go to diff View file
M plugins/tracker/include/Tracker/Creation/JiraImporter/JiraConnectionException.php +3 −1 Go to diff View file
M plugins/tracker/include/Tracker/Creation/JiraImporter/JiraProjectListController.php +1 −1 Go to diff View file
M plugins/tracker/include/Tracker/Creation/JiraImporter/JiraRunner.php +12 −63 Go to diff View file
A plugins/tracker/include/Tracker/Creation/JiraImporter/JiraServerClient.php +32 −0 Go to diff View file
M plugins/tracker/include/Tracker/Creation/JiraImporter/JiraTrackerBuilder.php +1 −1 Go to diff View file
M plugins/tracker/include/Tracker/Creation/JiraImporter/JiraTrackersListController.php +1 −1 Go to diff View file
M plugins/tracker/include/trackerPlugin.php +10 −19 Go to diff View file
M plugins/tracker/tests/unit/Tracker/Creation/JiraImporter/ClientWrapperBuilderTest.php +23 −9 Go to diff View file
M plugins/tracker/tests/unit/Tracker/Creation/JiraImporter/ClientWrapperTest.php +1 −1 Go to diff View file
M plugins/tracker/tests/unit/Tracker/Creation/JiraImporter/Import/AlwaysThereFieldsExporterTest.php +31 −33 Go to diff View file
M plugins/tracker/tests/unit/Tracker/Creation/JiraImporter/Import/Artifact/ArtifactsXMLExporterTest.php +21 −52 Go to diff View file
M plugins/tracker/tests/unit/Tracker/Creation/JiraImporter/Import/Artifact/Attachment/AttachmentDownloaderTest.php +5 −20 Go to diff View file
M plugins/tracker/tests/unit/Tracker/Creation/JiraImporter/Import/Semantic/SemanticsXMLExporterTest.php +0 −4 Go to diff View file
M plugins/tracker/tests/unit/Tracker/Creation/JiraImporter/Import/Structure/JiraFieldRetrieverTest.php +39 −40 Go to diff View file
M plugins/tracker/tests/unit/Tracker/Creation/JiraImporter/Import/Values/StatusValuesCollectionTest.php +74 −99 Go to diff View file
D plugins/tracker/tests/unit/Tracker/Creation/JiraImporter/JiraInstanceURLCheckerTest.php +0 −51 Go to diff View file
M plugins/tracker/tests/unit/Tracker/Creation/JiraImporter/JiraProjectBuilderTest.php +66 −75 Go to diff View file
M plugins/tracker/tests/unit/Tracker/Creation/JiraImporter/JiraRunnerTest.php +11 −1 Go to diff View file
M plugins/tracker/tests/unit/Tracker/Creation/JiraImporter/JiraTrackerBuilderTest.php +48 −48 Go to diff View file
M plugins/tracker/tests/unit/Tracker/Creation/JiraImporter/Stub/JiraCloudClientStub.php +13 −0 Go to diff View file
M plugins/tracker/tests/unit/Tracker/Creation/JiraImporter/Stub/JiraServerClientStub.php +11 −0 Go to diff View file