|
1 | 1 | # Terratest v2 Import Map |
2 | 2 |
|
3 | | -Status: FROZEN. The one open decision (renames) is resolved: the three hyphenated packages are renamed to idiomatic Go names at the `/v2` boundary. |
| 3 | +Status: FROZEN for import paths. The one open decision (renames) is resolved: the three hyphenated packages are renamed to idiomatic Go names at the `/v2` boundary. |
| 4 | + |
| 5 | +Some symbols also moved between modules during the beta. See [Symbols relocated during the v2 beta](#symbols-relocated-during-the-v2-beta). |
4 | 6 |
|
5 | 7 | Built from the actual v1 layout at tag `v1.0.1-test` (27 `modules/` packages, 2 `cmd/` binaries, 1 `internal/lib` tree). |
6 | 8 |
|
@@ -66,6 +68,31 @@ So e.g. `modules/logger/parser` -> `modules/core/v2/logger/parser`, `modules/aws |
66 | 68 | |---|---| |
67 | 69 | | `internal/lib/formatting` | `internal/formatting` | |
68 | 70 |
|
| 71 | +## Symbols relocated during the v2 beta |
| 72 | + |
| 73 | +Moved to the module owning the type, so `teststructure` no longer requires `aws`, `k8s`, `packer` and `ssh` (#1877). |
| 74 | +Signatures and on-disk filenames are unchanged, and every call site is a compile error. |
| 75 | + |
| 76 | +| beta.1 | beta.2 onwards | |
| 77 | +|---|---| |
| 78 | +| `teststructure.{Save,Load}Ec2KeyPair` | `aws.{Save,Load}Ec2KeyPair` | |
| 79 | +| `teststructure.{Save,Load}KubectlOptions` | `k8s.{Save,Load}KubectlOptions` | |
| 80 | +| `teststructure.{Save,Load}PackerOptions` | `packer.{Save,Load}PackerOptions` | |
| 81 | +| `teststructure.{Save,Load}SSHKeyPair` | `ssh.{Save,Load}SSHKeyPair` | |
| 82 | + |
| 83 | +Nothing else moved. Watch for files that alias Terratest's `aws` because plain `aws` is the AWS SDK. |
| 84 | + |
| 85 | +## Behaviour changes during the v2 beta |
| 86 | + |
| 87 | +**Node addresses prefer `ExternalIP`** (#1878). `k8s.FindNodeHostnameContextE` and `GetServiceEndpoint` (NodePort) |
| 88 | +now return the Node's `ExternalIP` when present, falling back to the internal hostname as before. On EKS that is the |
| 89 | +public IP, so no EC2 call and no `ec2:DescribeInstances` permission is needed. Signatures are unchanged; the new |
| 90 | +`FindNodeHostnameWithOptionsContext[E]` consults `NodePublicIPLookup` for clusters with no `ExternalIP`. |
| 91 | + |
| 92 | +**`KubectlOptions` carrying a `RestConfig` no longer serializes** (#1879). `MarshalJSON` returns |
| 93 | +`k8s.ErrRestConfigNotSerializable` instead of dropping the config. This already failed, with an opaque |
| 94 | +`json: unsupported type: transport.WrapperFunc`. Use `NewKubectlOptions` or `NewKubectlOptionsWithInClusterAuth`. |
| 95 | + |
69 | 96 | ## Accounting |
70 | 97 |
|
71 | 98 | 27 `modules/` packages = 6 collapsed into core + 15 standalone submodules + 6 removed. Plus 2 removed `cmd/` binaries and 1 internal flatten. Submodule count: 16. |
|
0 commit comments