Skip to content

Add support for JIRA API v3, including backward compatibility for com…#17

Draft
marko-p wants to merge 1 commit intoChavaillaz:masterfrom
marko-p:master
Draft

Add support for JIRA API v3, including backward compatibility for com…#17
marko-p wants to merge 1 commit intoChavaillaz:masterfrom
marko-p:master

Conversation

@marko-p
Copy link
Copy Markdown

@marko-p marko-p commented Jan 14, 2026

…ments and descriptions

* @param version The API version (2 or 3)
* @return This client for method chaining
* @throws IllegalArgumentException if the version is not 2 or 3
*/
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think you can remove this comment as the one in the method of the parent interface is more detailed and has the same purpose.

* Base API path for JIRA REST API v2.
* This is the default API version for backward compatibility.
*/
public static final String BASE_API_V2 = "/rest/api/2/";
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As it's not used anywhere else, I would propose to have both URLs directly in the enum below instead of being defined as constants.

* @param version The API version
* @return The base path for the specified version
*/
public static String getBaseApiPath(ApiVersion version) {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't find where this method is called, possibly to remove if it's unused.

/**
* Enumeration of supported JIRA REST API versions.
*/
public enum ApiVersion {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would propose to have that enum separated in a dedicated file and not as inner enum.

}

@Override
// ...existing code...
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Keep the Override annotation here

}

@Override
// ...existing code...
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Keep the Override annotation here

}

@Override
// ...existing code...
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Keep the Override annotation here

}

@Override
// ...existing code...
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Keep the Override annotation here

}

@Override
// ...existing code...
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Keep the Override annotation here

}

@Override
// ...existing code...
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Keep the Override annotation here

* @param urlPattern The URL pattern to append
* @return The complete URL
*/
protected String buildUrl(String urlPattern) {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think this method and the similar one in other implementationsn are used.

@marko-p marko-p marked this pull request as draft January 28, 2026 11:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants