Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(bamboo): keep plan name same in both /search-remote-scopes and /remote-scopes #6284

Merged
merged 1 commit into from
Oct 19, 2023

Conversation

d4x1
Copy link
Contributor

@d4x1 d4x1 commented Oct 19, 2023

⚠️ Pre Checklist

Please complete ALL items in this checklist, and remove before submitting

  • I have read through the Contributing Documentation.
  • I have added relevant tests.
  • I have added relevant documentation.
  • I will add labels to the PR, such as pr-type/bug-fix, pr-type/feature-development, etc.

Summary

What does this PR do?
In bamboo, /search/plans.json return json like:

{
	"size": 3,
	"searchResults": [
		{
			"id": "HLW-P1",
			"type": "chain",
			"searchEntity": {
				"id": "HLW-P1",
				"key": "HLW-P1",
				"projectName": "hlw",
				"planName": "p1",
				"branchName": "Default",
				"description": "hlw plan descdddd",
				"type": "chain"
			}
		},
		{
			"id": "VDEV-HYP",
			"type": "chain",
			"searchEntity": {
				"id": "VDEV-HYP",
				"key": "VDEV-HYP",
				"projectName": "vdev",
				"planName": "hyperapi",
				"branchName": "master",
				"type": "chain"
			}
		},
		{
			"id": "VDEV-UN",
			"type": "chain",
			"searchEntity": {
				"id": "VDEV-UN",
				"key": "VDEV-UN",
				"projectName": "vdev",
				"planName": "UNITTEST",
				"branchName": "master",
				"type": "chain"
			}
		}
	],
	"start-index": 0,
	"max-result": 3
}

planName field is plan's pure name.
while in API /plan.json, resp is like:

{
	"expand": "plans",
	"link": {
		"href": "http://18.232.129.138:8085/rest/api/latest/plan",
		"rel": "self"
	},
	"plans": {
		"size": 3,
		"expand": "plan",
		"start-index": 0,
		"max-result": 3,
		"plan": [
			{
				"shortName": "p1",
				"shortKey": "P1",
				"type": "chain",
				"enabled": true,
				"link": {
					"href": "http://ip:port/rest/api/latest/plan/HLW-P1",
					"rel": "self"
				},
				"key": "HLW-P1",
				"name": "hlw - p1",
				"planKey": {
					"key": "HLW-P1"
				}
			}
                         // other elements                 
		]
	}
}

plan name is {projectName} - {planPureName}.

This PR just keep plan's name the same.

Does this close any open issues?

Closes N/A

Screenshots

Include any relevant screenshots here.
image

Other Information

Any other information that is important to this PR.

@d4x1 d4x1 changed the title fix(bamboo): keep plan name same in both /search-remote-scopes and /r… fix(bamboo): keep plan name same in both /search-remote-scopes and /remote-scopes Oct 19, 2023
@abeizn abeizn merged commit 0cd881f into apache:main Oct 19, 2023
@d4x1 d4x1 deleted the lw-fix-bamboo-remote-fullname branch October 19, 2023 07:27
@d4x1 d4x1 added the pr-type/bug-fix This PR fixes a bug label Oct 26, 2023
@d4x1 d4x1 added this to the v0.20 milestone Oct 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pr-type/bug-fix This PR fixes a bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants