gocd-janitor icon indicating copy to clipboard operation
gocd-janitor copied to clipboard

404 for /go/api/pipelines.xml

Open Deepak1100 opened this issue 3 years ago • 1 comments

getting the following issue when trying to use it with 21.3.0 gocd version

bash-5.1$ /gocd-jre/bin/java -cp /tmp/gocd-janitor.jar in.ashwanthkumar.gocd.artifacts.Janitor --conf janitor.conf --dry-run --delete-artifacts
12:49:19.721 INFO  in.ashwanthkumar.gocd.artifacts.Janitor - Starting Janitor
12:49:19.723 INFO  in.ashwanthkumar.gocd.artifacts.Janitor - Go Server - https://gocd
12:49:19.723 INFO  in.ashwanthkumar.gocd.artifacts.Janitor - Artifact Dir - /godata/artifacts/pipelines/
12:49:19.723 INFO  in.ashwanthkumar.gocd.artifacts.Janitor - Working in Dry run mode, we will not delete anything in this run.
12:49:19.723 INFO  in.ashwanthkumar.gocd.artifacts.Janitor - Finding pipelines to process
12:49:19.729 DEBUG in.ashwanthkumar.gocd.client.http.HttpClient - Hitting https://gocd/go/api/pipelines.xml
Exception in thread "main" com.google.api.client.http.HttpResponseException: 404 Not Found
	at com.google.api.client.http.HttpRequest.execute(HttpRequest.java:1070)
	at in.ashwanthkumar.gocd.client.http.HttpClient.getXML(HttpClient.java:75)
	at in.ashwanthkumar.gocd.client.GoCD.allPipelineNames(GoCD.java:58)
	at in.ashwanthkumar.gocd.artifacts.Janitor.pipelinesNotInConfiguration(Janitor.java:109)
	at in.ashwanthkumar.gocd.artifacts.Janitor.getPipelines(Janitor.java:197)
	at in.ashwanthkumar.gocd.artifacts.Janitor.run(Janitor.java:89)
	at in.ashwanthkumar.gocd.artifacts.Janitor.main(Janitor.java:71)
bash-5.1$ /gocd-jre/bin/java -cp /tmp/gocd-janitor.jar in.ashwanthkumar.gocd.artifacts.Janitor --conf janitor.conf --dry-run --delete-artifacts%

is this project still active or work for latest gocd?

Deepak1100 avatar Feb 15 '22 13:02 Deepak1100

it seems api have changed to /go/api/feed/pipelines.xml

Deepak1100 avatar Feb 15 '22 16:02 Deepak1100