Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

On new major release, rename function to be more clear #38

Closed
Tracked by #495 ...
smuu opened this issue May 19, 2023 · 7 comments · Fixed by #539
Closed
Tracked by #495 ...

On new major release, rename function to be more clear #38

smuu opened this issue May 19, 2023 · 7 comments · Fixed by #539
Assignees
Milestone

Comments

@smuu
Copy link
Member

smuu commented May 19, 2023

Do not work on this, only a new major release is planned

@smuu smuu added enhancement New feature or request good first issue Good for newcomers labels May 19, 2023
@smuu
Copy link
Member Author

smuu commented Jul 1, 2024

@smuu will go through the functions and create a proposal

@smuu smuu added the knuu label Jul 5, 2024
@smuu smuu added refactor Refactoring and removed enhancement New feature or request labels Jul 5, 2024
@smuu smuu added breaking and removed good first issue Good for newcomers labels Jul 5, 2024
@smuu smuu self-assigned this Jul 22, 2024
@smuu
Copy link
Member Author

smuu commented Jul 22, 2024

Current list with all functions, the parameters, and the return type.

Function Name Parameters Return
AddCapabilities capabilities []string error
AddCapability capability string error
AddFile src string, dest string, chown string error
AddFileBytes bytes []byte, dest string, chown string error
AddFolder src string, dest string, chown string error
AddHost ctx context.Context, port int host string, err error
AddHostWithReadyCheck ctx context.Context, port int, checkFunc func(host string) (bool, error) host string, err error
AddPolicyRule rule rbacv1.PolicyRule error
AddPortTCP port int error
AddPortUDP port int error
AddSidecar sidecar *Instance error
AddVolume path string, size resource.Quantity error
AddVolumeWithOwner path string, size resource.Quantity, owner int64 error
Clone *Instance, error
CloneWithName name string *Instance, error
Commit error
CreateCustomResource ctx context.Context, gvr *schema.GroupVersionResource, ... error
CustomResourceDefinitionExists ctx context.Context, gvr *schema.GroupVersionResource bool, error
Destroy ctx context.Context error
DisableBitTwister error
DisableNetwork ctx context.Context error
EnableBitTwister error
EnableNetwork ctx context.Context error
EnableTsharkCollector conf TsharkCollectorConfig error
ExecuteCommand ctx context.Context, command ...string string, error
GetFileBytes ctx context.Context, file string []byte, error
GetIP ctx context.Context string, error
IsInState states ...InstanceState bool
IsRunning ctx context.Context bool, error
IsState state InstanceState bool
K8sName string
Labels map[string]string
Name string
NetworkIsDisabled ctx context.Context bool, error
NewPool amount int *InstancePool, error
PortForwardTCP ctx context.Context, port int int, error
ReadFileFromRunningInstance ctx context.Context, filePath string io.ReadCloser, error
SetArgs args ...string error
SetBandwidthLimit limit int64 error
SetCPU request resource.Quantity error
SetCommand command ...string error
SetEnvironmentVariable key, value string error
SetGitRepo ctx context.Context, gitContext builder.GitContext error
SetImage ctx context.Context, image string error
SetImageInstant ctx context.Context, image string error
SetInstanceType instanceType InstanceType
SetJaegerEndpoint grpcPort, thriftCompactPort, thriftHttpPort int error
SetJaegerExporter endpoint string error
SetLatencyAndJitter latency, jitter int64 error
SetLivenessProbe livenessProbe *v1.Probe error
SetMemory request, limit resource.Quantity error
SetOtelCollectorVersion version string error
SetOtelEndpoint port int error
SetOtlpExporter endpoint, username, password string error
SetPacketLoss packetLoss int32 error
SetPrivileged privileged bool error
SetPrometheusEndpoint port int, jobName, scapeInterval string error
SetPrometheusExporter endpoint string error
SetPrometheusRemoteWriteExporter endpoint string error
SetReadinessProbe readinessProbe *v1.Probe error
SetStartupProbe startupProbe *v1.Probe error
SetState state InstanceState
SetUser user string error
Start ctx context.Context error
StartAsync ctx context.Context error
StartWithCallback ctx context.Context, callback func() error
Stop ctx context.Context error
TsharkCollectorEnabled bool
WaitInstanceIsRunning ctx context.Context error
WaitInstanceIsStopped ctx context.Context error

@smuu
Copy link
Member Author

smuu commented Jul 22, 2024

My proposal to rename functions:

EnableBitTwister -> EnableNetworkShaping
DisableBitTwister -> DisableNetworkShaping
K8sName -> UniqueName
NetworkIsDisabled -> IsNetworkDisabled
SetBandwidthLimit -> SetBandwidth
SetCommand -> SetStartCommand

Happy to discuss these @mojtaba-esk @tty47

@smuu smuu added this to the v0.15.0 milestone Jul 22, 2024
@mojtaba-esk
Copy link
Member

Good job. thanks for preparing that list, it helps to have a better look at them.

@smuu
Copy link
Member Author

smuu commented Jul 23, 2024

AddCapabilities -> AddKubernetesCapabilities
AddCapability -> AddKubernetesCapability

@smuu smuu removed their assignment Jul 23, 2024
@mojtaba-esk
Copy link
Member

Let's work on this once the sidecar PR is merged so we know what functions left to be renamed.

@mojtaba-esk mojtaba-esk self-assigned this Jul 26, 2024
@mojtaba-esk mojtaba-esk moved this to Needs Review in Celestia DevOps/Testing Jul 26, 2024
@mojtaba-esk mojtaba-esk moved this from Needs Review to In Progress in Celestia DevOps/Testing Jul 26, 2024
@mojtaba-esk
Copy link
Member

PR #533 by default does some renaming as it groups different functions, let's have a look at the new structure (grouping) that is proposed by that PR and then see which one left to be renamed.
Also many of the functions listed above are moved to their own sidecar package so there might be none or just a few of them left to be renamed.

@smuu smuu closed this as completed in #539 Aug 8, 2024
@github-project-automation github-project-automation bot moved this from In Progress to Done in Celestia DevOps/Testing Aug 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

2 participants