Skip to content

Commit 319d3b7

Browse files
rfavreaudependabot[bot]Dbzman
authored
Release 2.4.0 (#37)
* Bump golang.org/x/mod from 0.22.0 to 0.23.0 (#29) Bumps [golang.org/x/mod](https://github.com/golang/mod) from 0.22.0 to 0.23.0. - [Commits](golang/mod@v0.22.0...v0.23.0) --- updated-dependencies: - dependency-name: golang.org/x/mod dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * Bump github.com/hashicorp/terraform-plugin-sdk/v2 from 2.35.0 to 2.36.1 (#31) Bumps [github.com/hashicorp/terraform-plugin-sdk/v2](https://github.com/hashicorp/terraform-plugin-sdk) from 2.35.0 to 2.36.1. - [Release notes](https://github.com/hashicorp/terraform-plugin-sdk/releases) - [Changelog](https://github.com/hashicorp/terraform-plugin-sdk/blob/main/CHANGELOG.md) - [Commits](hashicorp/terraform-plugin-sdk@v2.35.0...v2.36.1) --- updated-dependencies: - dependency-name: github.com/hashicorp/terraform-plugin-sdk/v2 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Richard FAVREAU <[email protected]> * Bump golang.org/x/mod from 0.23.0 to 0.24.0 (#34) Bumps [golang.org/x/mod](https://github.com/golang/mod) from 0.23.0 to 0.24.0. - [Commits](golang/mod@v0.23.0...v0.24.0) --- updated-dependencies: - dependency-name: golang.org/x/mod dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * Bump github.com/hashicorp/terraform-plugin-docs from 0.20.1 to 0.21.0 (#33) Bumps [github.com/hashicorp/terraform-plugin-docs](https://github.com/hashicorp/terraform-plugin-docs) from 0.20.1 to 0.21.0. - [Release notes](https://github.com/hashicorp/terraform-plugin-docs/releases) - [Changelog](https://github.com/hashicorp/terraform-plugin-docs/blob/main/CHANGELOG.md) - [Commits](hashicorp/terraform-plugin-docs@v0.20.1...v0.21.0) --- updated-dependencies: - dependency-name: github.com/hashicorp/terraform-plugin-docs dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Richard FAVREAU <[email protected]> * Upgrade the queue UnitTests * Merge branch 'issues/32' * Fix Queue import * Update queue unit test * Fix golangci linters * Fix linters * Fix TestAccQueue_VhostDefaultQueueType * Add type field for ressouce_queue * Add datasource_queue * Fix Tests * Fix Documentations * Fix queue status returned * Fix datasource vhost #36 * New Release --------- Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: timo.litzius <[email protected]>
1 parent a4b4bca commit 319d3b7

File tree

23 files changed

+939
-370
lines changed

23 files changed

+939
-370
lines changed

.golangci.yml

Lines changed: 26 additions & 64 deletions
Original file line numberDiff line numberDiff line change
@@ -1,65 +1,27 @@
1-
# Visit https://goreleaser.com for documentation on how to customize this
2-
# behavior.
3-
before:
4-
hooks:
5-
# this is just an example and not a requirement for provider building/publishing
6-
- go mod tidy
7-
builds:
8-
- env:
9-
# goreleaser does not work with CGO, it could also complicate
10-
# usage by users in CI/CD systems like HCP Terraform where
11-
# they are unable to install libraries.
12-
- CGO_ENABLED=0
13-
mod_timestamp: '{{ .CommitTimestamp }}'
14-
flags:
15-
- -trimpath
16-
ldflags:
17-
- '-s -w -X main.version={{.Version}} -X main.commit={{.Commit}}'
18-
goos:
19-
- freebsd
20-
- windows
21-
- linux
22-
- darwin
23-
goarch:
24-
- amd64
25-
- '386'
26-
- arm
27-
- arm64
28-
ignore:
29-
- goos: darwin
30-
goarch: '386'
31-
binary: '{{ .ProjectName }}_v{{ .Version }}'
32-
archives:
33-
- format: zip
34-
name_template: '{{ .ProjectName }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}'
35-
checksum:
36-
extra_files:
37-
- glob: 'terraform-registry-manifest.json'
38-
name_template: '{{ .ProjectName }}_{{ .Version }}_manifest.json'
39-
name_template: '{{ .ProjectName }}_{{ .Version }}_SHA256SUMS'
40-
algorithm: sha256
41-
signs:
42-
- artifacts: checksum
43-
args:
44-
# if you are using this in a GitHub action or some other automated pipeline, you
45-
# need to pass the batch flag to indicate its not interactive.
46-
- "--batch"
47-
- "--local-user"
48-
- "{{ .Env.GPG_FINGERPRINT }}" # set this environment variable for your signing key
49-
- "--output"
50-
- "${signature}"
51-
- "--detach-sign"
52-
- "${artifact}"
53-
release:
54-
extra_files:
55-
- glob: 'terraform-registry-manifest.json'
56-
name_template: '{{ .ProjectName }}_{{ .Version }}_manifest.json'
57-
# If you want to manually examine the release before its live, uncomment this line:
58-
# draft: true
59-
changelog:
60-
skip: true
1+
# Visit https://golangci-lint.run/ for usage documentation
2+
# and information on other useful linters
613
issues:
62-
exclude-rules:
63-
- linters:
64-
- errcheck
65-
text: "Error return value of `d.Set` is not checked"
4+
max-issues-per-linter: 0
5+
max-same-issues: 0
6+
7+
linters:
8+
disable-all: true
9+
enable:
10+
- durationcheck
11+
# - errcheck
12+
- copyloopvar
13+
# - forcetypeassert
14+
# - godot
15+
- gofmt
16+
- gosimple
17+
- ineffassign
18+
- makezero
19+
- misspell
20+
- nilerr
21+
- predeclared
22+
- staticcheck
23+
- unconvert
24+
# - unparam
25+
- unused
26+
- govet
27+
- testifylint

CHANGELOG.md

Lines changed: 25 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,30 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](http://keepachangelog.com/)
66
and this project adheres to [Semantic Versioning](http://semver.org/).
77

8+
## 2.4.0 (March 16, 2025)
9+
10+
FEATURE:
11+
12+
* Add `type` read only field for `rabbitmq_queue` resource - @rfavreau
13+
14+
* Add `rabbitmq_queue` datasource - @rfavreau
15+
16+
FIX:
17+
18+
* `x-queue-type` argument causing always queue recreation [#32](https://github.com/rfd59/terraform-provider-rabbitmq/issues/32) - @pnowy
19+
([#35](https://github.com/rfd59/terraform-provider-rabbitmq/pull/35))
20+
21+
* Datasource _vhost_ returns no error message when the vhost doesn't exist [#36](https://github.com/rfd59/terraform-provider-rabbitmq/issues/36) - @rfavreau
22+
23+
BUILD / DEV:
24+
25+
* Update dependencies - @rfavreau
26+
([#29](https://github.com/rfd59/terraform-provider-rabbitmq/pull/29), [#31](https://github.com/rfd59/terraform-provider-rabbitmq/pull/31), [#33](https://github.com/rfd59/terraform-provider-rabbitmq/pull/33), [#34](https://github.com/rfd59/terraform-provider-rabbitmq/pull/34))
27+
28+
* Upgrade _resource_queue_ unit tests - @rfavreau
29+
30+
* Fix golangci-lint - @rfavreau
31+
832
## 2.3.0 (December 06, 2024)
933

1034
FEATURES:
@@ -44,7 +68,7 @@ BUILD / DEV:
4468

4569
FEATURES:
4670

47-
* Manage the user limits - @rfavreau
71+
* Manage the user limits [#10](https://github.com/rfd59/terraform-provider-rabbitmq/issues/10) - @rfavreau
4872
([#10](https://github.com/rfd59/terraform-provider-rabbitmq/pull/10))
4973

5074
BUILD / DEV:

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ terraform {
2727
required_providers {
2828
rabbitmq = {
2929
source = "rfd59/rabbitmq"
30-
version = "2.3.0"
30+
version = "2.4.0"
3131
}
3232
}
3333
}

docs/data-sources/queue.md

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
---
2+
# generated by https://github.com/hashicorp/terraform-plugin-docs
3+
page_title: "rabbitmq_queue Data Source - terraform-provider-rabbitmq"
4+
subcategory: ""
5+
description: |-
6+
Use this data source to access information about an existing queue.
7+
---
8+
9+
# rabbitmq_queue (Data Source)
10+
11+
Use this data source to access information about an existing _queue_.
12+
13+
## Example Usage
14+
15+
```terraform
16+
# Read the queue settings
17+
data "rabbitmq_queue" "example" {
18+
name = "myqueue"
19+
}
20+
21+
# Display the queue type
22+
output "type" {
23+
value = data.rabbitmq_queue.example.type
24+
}
25+
```
26+
27+
<!-- schema generated by tfplugindocs -->
28+
## Schema
29+
30+
### Required
31+
32+
- `name` (String) The name of the queue.
33+
34+
### Optional
35+
36+
- `vhost` (String) The virtual host where is stored the queue. Default to `/`.
37+
38+
### Read-Only
39+
40+
- `id` (String) The ID of this resource.
41+
- `status` (String) The status of the queue.
42+
- `type` (String) The type of the queue.

docs/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ provider "rabbitmq" {
1919
endpoint = "http://127.0.0.1:15672"
2020
username = "guest"
2121
password = "guest"
22-
22+
2323
headers = {
2424
"X-Custom-Header" = "CustomValue"
2525
}

docs/resources/queue.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,7 @@ resource "rabbitmq_queue" "example" {
6767
### Read-Only
6868

6969
- `id` (String) The ID of this resource.
70+
- `type` (String) The queue type created. The value are `classic`, `quorum` or `stream`.
7071

7172
<a id="nestedblock--settings"></a>
7273
### Nested Schema for `settings`
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
# Read the queue settings
2+
data "rabbitmq_queue" "example" {
3+
name = "myqueue"
4+
}
5+
6+
# Display the queue type
7+
output "type" {
8+
value = data.rabbitmq_queue.example.type
9+
}

examples/provider/provider.tf

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,10 @@ provider "rabbitmq" {
33
endpoint = "http://127.0.0.1:15672"
44
username = "guest"
55
password = "guest"
6+
7+
headers = {
8+
"X-Custom-Header" = "CustomValue"
9+
}
610
}
711

812
# Create a virtual host

go.mod

Lines changed: 24 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
module github.com/rfd59/terraform-provider-rabbitmq
22

33
require (
4-
github.com/hashicorp/terraform-plugin-docs v0.20.1
5-
github.com/hashicorp/terraform-plugin-sdk/v2 v2.35.0
4+
github.com/hashicorp/terraform-plugin-docs v0.21.0
5+
github.com/hashicorp/terraform-plugin-sdk/v2 v2.36.1
66
github.com/michaelklishin/rabbit-hole/v2 v2.16.0
7-
golang.org/x/mod v0.22.0
7+
golang.org/x/mod v0.24.0
88
)
99

1010
replace github.com/michaelklishin/rabbit-hole/v2 => github.com/rfavreau/rabbit-hole/v2 v2.16.1
@@ -15,18 +15,18 @@ require (
1515
github.com/Masterminds/goutils v1.1.1 // indirect
1616
github.com/Masterminds/semver/v3 v3.2.0 // indirect
1717
github.com/Masterminds/sprig/v3 v3.2.3 // indirect
18-
github.com/ProtonMail/go-crypto v1.1.0-alpha.2-proton // indirect
18+
github.com/ProtonMail/go-crypto v1.1.3 // indirect
1919
github.com/agext/levenshtein v1.2.3 // indirect
2020
github.com/apparentlymart/go-textseg/v15 v15.0.0 // indirect
2121
github.com/armon/go-radix v1.0.0 // indirect
2222
github.com/bgentry/speakeasy v0.1.0 // indirect
23-
github.com/bmatcuk/doublestar/v4 v4.7.1 // indirect
23+
github.com/bmatcuk/doublestar/v4 v4.8.1 // indirect
2424
github.com/cloudflare/circl v1.3.8 // indirect
2525
github.com/fatih/color v1.17.0 // indirect
2626
github.com/golang/protobuf v1.5.4 // indirect
2727
github.com/google/go-cmp v0.6.0 // indirect
2828
github.com/google/uuid v1.6.0 // indirect
29-
github.com/hashicorp/cli v1.1.6 // indirect
29+
github.com/hashicorp/cli v1.1.7 // indirect
3030
github.com/hashicorp/errwrap v1.1.0 // indirect
3131
github.com/hashicorp/go-checkpoint v0.5.0 // indirect
3232
github.com/hashicorp/go-cleanhttp v0.5.2 // indirect
@@ -37,19 +37,19 @@ require (
3737
github.com/hashicorp/go-retryablehttp v0.7.7 // indirect
3838
github.com/hashicorp/go-uuid v1.0.3 // indirect
3939
github.com/hashicorp/go-version v1.7.0 // indirect
40-
github.com/hashicorp/hc-install v0.9.0 // indirect
41-
github.com/hashicorp/hcl/v2 v2.22.0 // indirect
40+
github.com/hashicorp/hc-install v0.9.1 // indirect
41+
github.com/hashicorp/hcl/v2 v2.23.0 // indirect
4242
github.com/hashicorp/logutils v1.0.0 // indirect
43-
github.com/hashicorp/terraform-exec v0.21.0 // indirect
44-
github.com/hashicorp/terraform-json v0.23.0 // indirect
45-
github.com/hashicorp/terraform-plugin-go v0.25.0 // indirect
43+
github.com/hashicorp/terraform-exec v0.22.0 // indirect
44+
github.com/hashicorp/terraform-json v0.24.0 // indirect
45+
github.com/hashicorp/terraform-plugin-go v0.26.0 // indirect
4646
github.com/hashicorp/terraform-plugin-log v0.9.0 // indirect
47-
github.com/hashicorp/terraform-registry-address v0.2.3 // indirect
47+
github.com/hashicorp/terraform-registry-address v0.2.4 // indirect
4848
github.com/hashicorp/terraform-svchost v0.1.1 // indirect
4949
github.com/hashicorp/yamux v0.1.1 // indirect
5050
github.com/huandu/xstrings v1.3.3 // indirect
5151
github.com/imdario/mergo v0.3.15 // indirect
52-
github.com/mattn/go-colorable v0.1.13 // indirect
52+
github.com/mattn/go-colorable v0.1.14 // indirect
5353
github.com/mattn/go-isatty v0.0.20 // indirect
5454
github.com/mattn/go-runewidth v0.0.9 // indirect
5555
github.com/mitchellh/copystructure v1.2.0 // indirect
@@ -66,23 +66,23 @@ require (
6666
github.com/vmihailenco/tagparser/v2 v2.0.0 // indirect
6767
github.com/yuin/goldmark v1.7.7 // indirect
6868
github.com/yuin/goldmark-meta v1.1.0 // indirect
69-
github.com/zclconf/go-cty v1.15.0 // indirect
69+
github.com/zclconf/go-cty v1.16.2 // indirect
7070
go.abhg.dev/goldmark/frontmatter v0.2.0 // indirect
71-
golang.org/x/crypto v0.28.0 // indirect
71+
golang.org/x/crypto v0.33.0 // indirect
7272
golang.org/x/exp v0.0.0-20230626212559-97b1e661b5df // indirect
73-
golang.org/x/net v0.28.0 // indirect
74-
golang.org/x/sync v0.9.0 // indirect
75-
golang.org/x/sys v0.26.0 // indirect
76-
golang.org/x/text v0.20.0 // indirect
73+
golang.org/x/net v0.34.0 // indirect
74+
golang.org/x/sync v0.11.0 // indirect
75+
golang.org/x/sys v0.30.0 // indirect
76+
golang.org/x/text v0.22.0 // indirect
7777
golang.org/x/tools v0.22.0 // indirect
7878
google.golang.org/appengine v1.6.8 // indirect
79-
google.golang.org/genproto/googleapis/rpc v0.0.0-20240814211410-ddb44dafa142 // indirect
80-
google.golang.org/grpc v1.67.1 // indirect
81-
google.golang.org/protobuf v1.35.1 // indirect
79+
google.golang.org/genproto/googleapis/rpc v0.0.0-20241015192408-796eee8c2d53 // indirect
80+
google.golang.org/grpc v1.69.4 // indirect
81+
google.golang.org/protobuf v1.36.3 // indirect
8282
gopkg.in/yaml.v2 v2.4.0 // indirect
8383
gopkg.in/yaml.v3 v3.0.1 // indirect
8484
)
8585

86-
go 1.23
86+
go 1.23.0
8787

88-
toolchain go1.23.4
88+
toolchain go1.24.1

0 commit comments

Comments
 (0)