Rename go module to agent/v3 - #643
Open
antgamdia wants to merge 1 commit into
Open
Conversation
Signed-off-by: Antonio Gamez Diaz <antonio.gamez@suse.com>
Contributor
There was a problem hiding this comment.
Pull request overview
Updates the repository’s Go module path to include the /v3 major-version suffix so the module can be accepted by Go tooling (e.g., sum.golang.org, pkg.go.dev) when publishing v3.x.y tags.
Changes:
- Renamed the module path in
go.modtogithub.com/trento-project/agent/v3. - Updated Go import paths across the codebase to reference the new module path.
- Adjusted release workflow and build ldflags to use the
/v3module path.
Reviewed changes
Copilot reviewed 192 out of 192 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| plugin_examples/sleep/sleep.go | Update example plugin imports to /v3 module path. |
| plugin_examples/dummy/dummy.go | Update example plugin imports to /v3 module path. |
| pkg/utils/log_test.go | Update test import to /v3 module path. |
| pkg/utils/commandexecutor_test.go | Update test import to /v3 module path. |
| pkg/factsengine/plugininterface/rpc.go | Update entities import to /v3 module path. |
| pkg/factsengine/plugininterface/rpc_internal_test.go | Update test import to /v3 module path. |
| pkg/factsengine/plugininterface/interface.go | Update entities import to /v3 module path. |
| pkg/factsengine/entities/facts_gathered_test.go | Update test import to /v3 module path. |
| pkg/factsengine/entities/fact_value_test.go | Update test import to /v3 module path. |
| Makefile | Update ldflags package paths to /v3 module path. |
| main.go | Update cmd import to /v3 module path. |
| internal/support/retry_test.go | Update test import to /v3 module path. |
| internal/operations/policy.go | Update internal imports to /v3 module path. |
| internal/operations/policy_test.go | Update test imports to /v3 module path. |
| internal/operations/operator/serviceenable_v1.go | Update systemd import to /v3 module path. |
| internal/operations/operator/serviceenable_v1_test.go | Update test imports to /v3 module path. |
| internal/operations/operator/servicedisable_v1.go | Update systemd import to /v3 module path. |
| internal/operations/operator/servicedisable_v1_test.go | Update test imports to /v3 module path. |
| internal/operations/operator/saptunechangesolution_v1.go | Update internal/pkg imports to /v3 module path. |
| internal/operations/operator/saptunechangesolution_v1_test.go | Update test imports to /v3 module path. |
| internal/operations/operator/saptuneapplysolution_v1.go | Update internal/pkg imports to /v3 module path. |
| internal/operations/operator/saptuneapplysolution_v1_test.go | Update test imports to /v3 module path. |
| internal/operations/operator/sapsystemstop_v1.go | Update sapcontrolapi import to /v3 module path. |
| internal/operations/operator/sapsystemstop_v1_test.go | Update test imports to /v3 module path. |
| internal/operations/operator/sapsystemstart_v1.go | Update sapcontrolapi import to /v3 module path. |
| internal/operations/operator/sapsystemstart_v1_test.go | Update test imports to /v3 module path. |
| internal/operations/operator/sapinstancestop_v1.go | Update sapcontrolapi import to /v3 module path. |
| internal/operations/operator/sapinstancestop_v1_test.go | Update test imports to /v3 module path. |
| internal/operations/operator/sapinstancestart_v1.go | Update sapcontrolapi import to /v3 module path. |
| internal/operations/operator/sapinstancestart_v1_test.go | Update test imports to /v3 module path. |
| internal/operations/operator/registry_test.go | Update test imports to /v3 module path. |
| internal/operations/operator/mocks/mock_Operator.go | Update generated mock import to /v3 module path. |
| internal/operations/operator/hostreboot_v1.go | Update internal/pkg imports to /v3 module path. |
| internal/operations/operator/hostreboot_v1_test.go | Update test imports to /v3 module path. |
| internal/operations/operator/executor_test.go | Update test import to /v3 module path. |
| internal/operations/operator/crmclusterstop_v1.go | Update internal imports to /v3 module path. |
| internal/operations/operator/crmclusterstop_v1_test.go | Update test imports to /v3 module path. |
| internal/operations/operator/crmclusterstart_v1.go | Update internal imports to /v3 module path. |
| internal/operations/operator/crmclusterstart_v1_test.go | Update test imports to /v3 module path. |
| internal/operations/operator/clusterresourcerefresh_v1.go | Update cluster import to /v3 module path. |
| internal/operations/operator/clusterresourcerefresh_v1_test.go | Update test imports to /v3 module path. |
| internal/operations/operator/clustermaintenancechange_v1.go | Update internal/pkg imports to /v3 module path. |
| internal/operations/operator/clustermaintenancechange_v1_test.go | Update test imports to /v3 module path. |
| internal/operations/operator/base.go | Update pkg/utils import to /v3 module path. |
| internal/operations/mapper.go | Update operator import to /v3 module path. |
| internal/operations/mapper_test.go | Update test imports to /v3 module path. |
| internal/operations/engine.go | Update internal imports to /v3 module path. |
| internal/operations/engine_integration_test.go | Update integration test imports to /v3 module path. |
| internal/messaging/eventhandler.go | Update internal imports to /v3 module path. |
| internal/identity/identity_test.go | Update test imports to /v3 module path. |
| internal/factsengine/policy.go | Update internal/pkg imports to /v3 module path. |
| internal/factsengine/policy_test.go | Update test imports to /v3 module path. |
| internal/factsengine/mapper.go | Update entities import to /v3 module path. |
| internal/factsengine/mapper_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gathering.go | Update internal/pkg imports to /v3 module path. |
| internal/factsengine/gathering_internal_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/xml.go | Update entities import to /v3 module path. |
| internal/factsengine/gatherers/verifypassword.go | Update entities/utils imports to /v3 module path. |
| internal/factsengine/gatherers/verifypassword_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/systemd.go | Update internal/pkg imports to /v3 module path. |
| internal/factsengine/gatherers/systemd_v2.go | Update internal/pkg imports to /v3 module path. |
| internal/factsengine/gatherers/systemd_v2_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/systemd_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/sysctl.go | Update entities/utils imports to /v3 module path. |
| internal/factsengine/gatherers/sysctl_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/sudoers.go | Update internal/pkg imports to /v3 module path. |
| internal/factsengine/gatherers/sudoers_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/status.go | Update entities/version imports to /v3 module path. |
| internal/factsengine/gatherers/status_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/sbddump.go | Update internal/pkg imports to /v3 module path. |
| internal/factsengine/gatherers/sbddump_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/sbd.go | Update internal/pkg imports to /v3 module path. |
| internal/factsengine/gatherers/sbd_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/saptune.go | Update internal/pkg imports to /v3 module path. |
| internal/factsengine/gatherers/saptune_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/sapservices.go | Update entities import to /v3 module path. |
| internal/factsengine/gatherers/sapservices_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/sapprofiles.go | Update internal/pkg imports to /v3 module path. |
| internal/factsengine/gatherers/sapprofiles_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/sapinstancehostnameresolver.go | Update internal/pkg imports to /v3 module path. |
| internal/factsengine/gatherers/sapinstancehostnameresolver_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/saphostctrl.go | Update entities/utils imports to /v3 module path. |
| internal/factsengine/gatherers/saphostctrl_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/sapcontrol.go | Update internal/pkg imports to /v3 module path. |
| internal/factsengine/gatherers/sapcontrol_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/rpc_plugin.go | Update plugin interface imports to /v3 module path. |
| internal/factsengine/gatherers/registry_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/products.go | Update entities import to /v3 module path. |
| internal/factsengine/gatherers/products_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/plugin_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/passwd.go | Update entities import to /v3 module path. |
| internal/factsengine/gatherers/passwd_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/packageversion.go | Update entities/utils imports to /v3 module path. |
| internal/factsengine/gatherers/packageversion_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/osrelease.go | Update entities import to /v3 module path. |
| internal/factsengine/gatherers/osrelease_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/mountinfo.go | Update entities/utils imports to /v3 module path. |
| internal/factsengine/gatherers/mountinfo_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/mocks/mock_FactGatherer.go | Update generated mock import to /v3 module path. |
| internal/factsengine/gatherers/ini_files.go | Update internal/pkg imports to /v3 module path. |
| internal/factsengine/gatherers/ini_files_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/hostsfile.go | Update entities import to /v3 module path. |
| internal/factsengine/gatherers/hostsfile_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/groups.go | Update entities import to /v3 module path. |
| internal/factsengine/gatherers/groups_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/gatherer.go | Update internal/pkg imports to /v3 module path. |
| internal/factsengine/gatherers/fstab.go | Update entities import to /v3 module path. |
| internal/factsengine/gatherers/fstab_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/fs_usage.go | Update entities/plugininterface/utils imports to /v3 module path. |
| internal/factsengine/gatherers/fs_usage_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/dispwork.go | Update internal/pkg imports to /v3 module path. |
| internal/factsengine/gatherers/dispwork_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/dir_scan.go | Update entities import to /v3 module path. |
| internal/factsengine/gatherers/dir_scan_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/corosyncconf.go | Update entities import to /v3 module path. |
| internal/factsengine/gatherers/corosyncconf_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/corosynccmapctl.go | Update entities/utils imports to /v3 module path. |
| internal/factsengine/gatherers/corosynccmapctl_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/cibadmin.go | Update internal/pkg imports to /v3 module path. |
| internal/factsengine/gatherers/cibadmin_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/ascsers_cluster.go | Update internal/pkg imports to /v3 module path. |
| internal/factsengine/gatherers/ascsers_cluster_test.go | Update test imports to /v3 module path. |
| internal/factsengine/gatherers/_todo/crmmon.go | Update entities import to /v3 module path (in ignored _todo dir). |
| internal/factsengine/gatherers/_todo/crmmon_test.go | Update test imports to /v3 module path (in ignored _todo dir). |
| internal/factsengine/factsengine.go | Update internal imports to /v3 module path. |
| internal/factsengine/factsengine_integration_test.go | Update integration test imports to /v3 module path. |
| internal/factsengine/factscache/cache_test.go | Update test import to /v3 module path. |
| internal/discovery/subscription.go | Update internal/pkg imports to /v3 module path. |
| internal/discovery/saptune.go | Update internal/pkg imports to /v3 module path. |
| internal/discovery/sapsystem.go | Update internal imports to /v3 module path. |
| internal/discovery/policy.go | Update messaging import to /v3 module path. |
| internal/discovery/policy_test.go | Update test imports to /v3 module path. |
| internal/discovery/policy_integration_test.go | Update integration test imports to /v3 module path. |
| internal/discovery/mocks/discovered_subscription_mock.go | Update mock imports to /v3 module path. |
| internal/discovery/mocks/discovered_sap_system_mock.go | Update mock imports to /v3 module path. |
| internal/discovery/mocks/discovered_host_mock.go | Update mock imports to /v3 module path. |
| internal/discovery/mocks/discovered_cluster_mock.go | Update mock imports to /v3 module path. |
| internal/discovery/mocks/discovered_cloud_mock.go | Update mock imports to /v3 module path. |
| internal/discovery/mapper_test.go | Update test import to /v3 module path. |
| internal/discovery/host.go | Update internal/version imports to /v3 module path. |
| internal/discovery/discovery.go | Update collector import to /v3 module path. |
| internal/discovery/collector/publishing_test.go | Update test imports to /v3 module path. |
| internal/discovery/collector/client_test.go | Update test imports to /v3 module path. |
| internal/discovery/cluster.go | Update internal imports to /v3 module path. |
| internal/discovery/cloud.go | Update internal/pkg imports to /v3 module path. |
| internal/core/systemd/systemd.go | Update dbus import to /v3 module path. |
| internal/core/systemd/systemd_test.go | Update test imports to /v3 module path. |
| internal/core/systemd/mocks/mock_Systemd.go | Update generated mock import to /v3 module path. |
| internal/core/systemd/mocks/mock_Loader.go | Update generated mock import to /v3 module path. |
| internal/core/subscription/subscription.go | Update pkg/utils import to /v3 module path. |
| internal/core/subscription/subscription_test.go | Update test imports to /v3 module path. |
| internal/core/saptune/saptune.go | Update pkg/utils import to /v3 module path. |
| internal/core/saptune/saptune_test.go | Update test imports to /v3 module path. |
| internal/core/sapsystem/sapsystem.go | Update internal/pkg imports to /v3 module path. |
| internal/core/sapsystem/sapsystem_test.go | Update test imports to /v3 module path. |
| internal/core/sapsystem/sapinstance.go | Update internal/pkg imports to /v3 module path. |
| internal/core/sapsystem/sapcontrolapi/mocks/mock_WebServiceConnector.go | Update generated mock import to /v3 module path. |
| internal/core/sapsystem/sapcontrolapi/mocks/mock_WebService.go | Update generated mock import to /v3 module path. |
| internal/core/sapsystem/sapcontrol.go | Update sapcontrolapi import to /v3 module path. |
| internal/core/hosts/discovered_host.go | Update systemd import to /v3 module path. |
| internal/core/hosts/discovered_host_test.go | Update test import to /v3 module path. |
| internal/core/cluster/sbd.go | Update pkg/utils import to /v3 module path. |
| internal/core/cluster/sbd_test.go | Update test imports to /v3 module path. |
| internal/core/cluster/crmmon/parser_test.go | Update test imports to /v3 module path. |
| internal/core/cluster/corosync/parser_test.go | Update test imports to /v3 module path. |
| internal/core/cluster/cmdclient.go | Update pkg/utils import to /v3 module path. |
| internal/core/cluster/cmdclient_test.go | Update test imports to /v3 module path. |
| internal/core/cluster/cluster.go | Update internal/pkg imports to /v3 module path. |
| internal/core/cluster/cluster_test.go | Update test imports to /v3 module path. |
| internal/core/cluster/cib/parser_test.go | Update test imports to /v3 module path. |
| internal/core/cloud/metadata.go | Update pkg/utils import to /v3 module path. |
| internal/core/cloud/metadata_test.go | Update test imports to /v3 module path. |
| internal/core/cloud/gcp_test.go | Update test imports to /v3 module path. |
| internal/core/cloud/gcp_dto_test.go | Update test import to /v3 module path. |
| internal/core/cloud/azure_test.go | Update test imports to /v3 module path. |
| internal/core/cloud/aws_test.go | Update test imports to /v3 module path. |
| internal/core/cloud/aws_dto_test.go | Update test import to /v3 module path. |
| internal/agent/config_test.go | Update cmd import to /v3 module path. |
| internal/agent/alloy_test.go | Update internal import to /v3 module path. |
| internal/agent/agent.go | Update internal imports to /v3 module path. |
| internal/agent/agent_test.go | Update test imports to /v3 module path. |
| go.mod | Rename module path to github.com/trento-project/agent/v3. |
| cmd/version.go | Update version import to /v3 module path. |
| cmd/start.go | Update internal/pkg imports to /v3 module path. |
| cmd/operator.go | Update internal/pkg imports to /v3 module path. |
| cmd/id.go | Update identity import to /v3 module path. |
| cmd/generate.go | Update internal/pkg imports to /v3 module path. |
| cmd/facts.go | Update internal/pkg imports to /v3 module path. |
| cmd/config.go | Update internal imports to /v3 module path. |
| cmd/config_test.go | Update test imports to /v3 module path. |
| .mockery.yaml | Update mockery package paths to /v3 module path. |
| .github/workflows/release.yaml | Update module documentation link and MODULE to include /v3 for sum/pkg.go.dev refresh. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
It turns out that the changes in #638 are not enough. Our go module is being rejected by pkg.go.dev, because it is not compliant with the naming policies. If our version is v3.y.z, then the go module has to be named
agent/v3.This PR is simply to rename from
agenttoagent/v3. No side effects are expected, as this package is not being consumed in other internal projects.Related #TRNT-4386
How was this tested?
CI
Documentation changes
No
Additional information
See how https://sum.golang.org/lookup/github.com/trento-project/agent@v3.1.2 yields:
not found: github.com/trento-project/agent@v3.1.2: invalid version: module contains a go.mod file, so module path must match major version ("github.com/trento-project/agent/v3")