Skip to content

Commit

Permalink
Switch Triggers resources to v1beta1
Browse files Browse the repository at this point in the history
Update API calls for the following resources to use `v1beta1` instead
of `v1alpha1`:
- `ClusterTriggerBinding`
- `EventListener`
- `Trigger`
- `TriggerBinding`
- `TriggerTemplate`

`v1beta1` has been supported since Triggers v0.15.0, and our current
minimum supported version is v0.21.0.
  • Loading branch information
AlanGreene authored and tekton-robot committed Nov 30, 2022
1 parent b9c0946 commit 3e0603a
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 15 deletions.
6 changes: 3 additions & 3 deletions src/api/clusterTriggerBindings.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
Copyright 2019-2021 The Tekton Authors
Copyright 2019-2022 The Tekton Authors
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
Expand All @@ -23,7 +23,7 @@ import {
function getClusterTriggerBindingsAPI({ filters, isWebSocket, name }) {
return getTektonAPI(
'clustertriggerbindings',
{ group: triggersAPIGroup, isWebSocket, version: 'v1alpha1' },
{ group: triggersAPIGroup, isWebSocket, version: 'v1beta1' },
getQueryParams({ filters, name })
);
}
Expand All @@ -37,7 +37,7 @@ export function getClusterTriggerBinding({ name }) {
const uri = getTektonAPI('clustertriggerbindings', {
group: triggersAPIGroup,
name,
version: 'v1alpha1'
version: 'v1beta1'
});
return get(uri);
}
Expand Down
6 changes: 3 additions & 3 deletions src/api/eventListeners.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
Copyright 2019-2021 The Tekton Authors
Copyright 2019-2022 The Tekton Authors
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
Expand All @@ -23,7 +23,7 @@ import {
function getEventListenersAPI({ filters, isWebSocket, name, namespace }) {
return getTektonAPI(
'eventlisteners',
{ group: triggersAPIGroup, isWebSocket, namespace, version: 'v1alpha1' },
{ group: triggersAPIGroup, isWebSocket, namespace, version: 'v1beta1' },
getQueryParams({ filters, name })
);
}
Expand All @@ -38,7 +38,7 @@ export function getEventListener({ name, namespace }) {
group: triggersAPIGroup,
name,
namespace,
version: 'v1alpha1'
version: 'v1beta1'
});
return get(uri);
}
Expand Down
6 changes: 3 additions & 3 deletions src/api/triggerBindings.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
Copyright 2019-2021 The Tekton Authors
Copyright 2019-2022 The Tekton Authors
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
Expand All @@ -23,7 +23,7 @@ import {
function getTriggerBindingsAPI({ filters, isWebSocket, name, namespace }) {
return getTektonAPI(
'triggerbindings',
{ group: triggersAPIGroup, isWebSocket, namespace, version: 'v1alpha1' },
{ group: triggersAPIGroup, isWebSocket, namespace, version: 'v1beta1' },
getQueryParams({ filters, name })
);
}
Expand All @@ -38,7 +38,7 @@ export function getTriggerBinding({ name, namespace }) {
group: triggersAPIGroup,
name,
namespace,
version: 'v1alpha1'
version: 'v1beta1'
});
return get(uri);
}
Expand Down
6 changes: 3 additions & 3 deletions src/api/triggerTemplates.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
Copyright 2019-2021 The Tekton Authors
Copyright 2019-2022 The Tekton Authors
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
Expand All @@ -23,7 +23,7 @@ import {
function getTriggerTemplatesAPI({ filters, isWebSocket, name, namespace }) {
return getTektonAPI(
'triggertemplates',
{ group: triggersAPIGroup, isWebSocket, namespace, version: 'v1alpha1' },
{ group: triggersAPIGroup, isWebSocket, namespace, version: 'v1beta1' },
getQueryParams({ filters, name })
);
}
Expand All @@ -38,7 +38,7 @@ export function getTriggerTemplate({ name, namespace }) {
group: triggersAPIGroup,
name,
namespace,
version: 'v1alpha1'
version: 'v1beta1'
});
return get(uri);
}
Expand Down
6 changes: 3 additions & 3 deletions src/api/triggers.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
Copyright 2021 The Tekton Authors
Copyright 2021-2022 The Tekton Authors
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
Expand All @@ -23,7 +23,7 @@ import {
function getTriggersAPI({ filters, isWebSocket, name, namespace }) {
return getTektonAPI(
'triggers',
{ group: triggersAPIGroup, isWebSocket, namespace, version: 'v1alpha1' },
{ group: triggersAPIGroup, isWebSocket, namespace, version: 'v1beta1' },
getQueryParams({ filters, name })
);
}
Expand All @@ -38,7 +38,7 @@ export function getTrigger({ name, namespace }) {
group: triggersAPIGroup,
name,
namespace,
version: 'v1alpha1'
version: 'v1beta1'
});
return get(uri);
}
Expand Down

0 comments on commit 3e0603a

Please sign in to comment.