-
Notifications
You must be signed in to change notification settings - Fork 653
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #73 from lwander/factor-multiple-build-events
Factor BuildEvent into BuildEvent and GitEvent
- Loading branch information
Showing
11 changed files
with
621 additions
and
270 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 20 additions & 0 deletions
20
echo-model/src/main/groovy/com/netflix/spinnaker/echo/model/trigger/DockerEvent.groovy
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
/* | ||
* Copyright 2016 Google, Inc. | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License") | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
package com.netflix.spinnaker.echo.model.trigger | ||
|
||
class DockerEvent extends TriggerEvent { | ||
} |
44 changes: 44 additions & 0 deletions
44
echo-model/src/main/groovy/com/netflix/spinnaker/echo/model/trigger/GitEvent.groovy
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
/* | ||
* Copyright 2016 Netflix, Inc. | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License") | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
package com.netflix.spinnaker.echo.model.trigger | ||
|
||
import com.fasterxml.jackson.annotation.JsonIgnore | ||
import com.fasterxml.jackson.annotation.JsonIgnoreProperties | ||
import groovy.transform.Canonical | ||
|
||
@Canonical | ||
@JsonIgnoreProperties(ignoreUnknown = true) | ||
class GitEvent extends TriggerEvent { | ||
Content content; | ||
|
||
public static final String TYPE = 'GIT'; | ||
|
||
@Canonical | ||
@JsonIgnoreProperties(ignoreUnknown = true) | ||
public static class Content { | ||
String repoProject; | ||
String slug; | ||
String hash; | ||
String branch; | ||
} | ||
|
||
@JsonIgnore | ||
public String getHash() { | ||
return content.hash; | ||
} | ||
} | ||
|
23 changes: 23 additions & 0 deletions
23
echo-model/src/main/groovy/com/netflix/spinnaker/echo/model/trigger/TriggerEvent.groovy
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
/* | ||
* Copyright 2016 Google, Inc. | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License") | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
package com.netflix.spinnaker.echo.model.trigger | ||
|
||
import com.netflix.spinnaker.echo.model.Metadata | ||
|
||
abstract class TriggerEvent { | ||
Metadata details | ||
} |
151 changes: 0 additions & 151 deletions
151
...triggers/src/main/java/com/netflix/spinnaker/echo/pipelinetriggers/BuildEventMonitor.java
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.