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

[Task] Move functionality out of api.go and client.go #5481

Closed
Himangini opened this issue Jul 4, 2022 · 0 comments
Closed

[Task] Move functionality out of api.go and client.go #5481

Himangini opened this issue Jul 4, 2022 · 0 comments
Labels
area/tech-debt Leftover improvements in code, testing and building good first issue Good for newcomers priority/important-longterm Important over the long term, but may not be currently staffed and/or may require multiple releases

Comments

@Himangini
Copy link
Collaborator

Description

This ticket is to refactor the functionality mentioned below and here

api.go

Contains:

  • Getters for accessing the AWS APIs, e.g. func (p ProviderServices) EKS() eksiface.EKSAPI { return p.eks }
  • Code for setting up the aws-sdk-go sessions

On the face of it a lot of this isn't really EKS specific but more general AWS related. We should move this out of this package (:heavy_check_mark: added to proposal at the end of the comment)

The rest of file is made up of:

func (c *ClusterProvider) NewStackManager(spec *api.ClusterConfig) manager.StackManager
func (c *ClusterProvider) SetAvailabilityZones(spec *api.ClusterConfig, given []string) error
func ParseConfig(data []byte) (*api.ClusterConfig, error)
func LoadConfigFromFile(configFile string) (*api.ClusterConfig, error)
func ResolveAMI(provider api.ClusterProvider, version string, np api.NodePool) error

None of these functions seem related to EKS specifically, so lets move them.

client.go

Contains code for setting up the aws-sdk-go sessions. Should be moved along side the AWS APIs code.

@Himangini Himangini added the area/tech-debt Leftover improvements in code, testing and building label Jul 4, 2022
@Himangini Himangini added good first issue Good for newcomers priority/important-longterm Important over the long term, but may not be currently staffed and/or may require multiple releases labels Jul 22, 2022
@Himangini Himangini closed this as not planned Won't fix, can't repro, duplicate, stale Nov 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/tech-debt Leftover improvements in code, testing and building good first issue Good for newcomers priority/important-longterm Important over the long term, but may not be currently staffed and/or may require multiple releases
Projects
None yet
Development

No branches or pull requests

1 participant