Skip to content

Support processing multiple HTTP listeners #121

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

Merged
merged 1 commit into from
Jun 23, 2022
Merged

Conversation

pleshakov
Copy link
Contributor

@pleshakov pleshakov commented May 27, 2022

Proposed changes

Problem:
The Gateway needs to process a Gateway resource. Currently, that is
already supported by the 'state' package. However, that support is
limited. For example, the package doesn't allow processing multiple
listeners. More over, the approach used in the 'state' package is hard
to extend to support multiple listeners.
This prompts development of a better solution.

As a first deliverable, we want to support processing multiple HTTP
listeners assuming they all bind to port 80.
We also assume that the Gateway only supports a single Gateway resource
with known namespace and name.

Solution - replace the existing types of the state package with
the new ones:

  • Introduce Configuration, which is an internal representation of the
    Gateway configuration.
  • Introduce Statuses, which holds status-related information about
    processed resources.
  • Introduce ChangeProcessor, which processes changes to Gateway API
    resources and returns new Configuration and Statuses.

@pleshakov pleshakov force-pushed the feature/listeners branch 2 times, most recently from 2b01152 to d51ee8e Compare May 27, 2022 22:50
@pleshakov pleshakov force-pushed the feature/listeners branch from d51ee8e to ac5c0d9 Compare May 31, 2022 19:19
@pleshakov pleshakov force-pushed the feature/listeners branch from ac5c0d9 to cc2fb56 Compare June 2, 2022 21:15
@pleshakov pleshakov requested a review from kate-osborn June 2, 2022 21:22
Copy link
Contributor

@kate-osborn kate-osborn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

I left one small comment but I'll go ahead and approve the changes

Problem:
The Gateway needs to process a Gateway resource. Currently, that is
already supported by the 'state' package. However, that support is
limited. For example, the package doesn't allow processing  multiple
listeners. More over, the approach used in the 'state' package is hard
to extend to support multiple listeners. 
This prompts development of a better solution.

As a first deliverable, we want to support processing multiple HTTP
listeners assuming they all bind to port 80. 
We also assume that the Gateway only supports a single Gateway resource
with known namespace and name.

Solution - replace the existing types of the state package with
the new ones:
- Introduce Configuration, which is an internal representation of the
Gateway configuration. 
- Introduce Statuses, which holds status-related information about
processed resources.
- Introduce ChangeProcessor, which processes changes to Gateway API
resources and returns new Configuration and Statuses.
@pleshakov pleshakov force-pushed the feature/listeners branch from 5f9adae to c91771f Compare June 23, 2022 03:27
@pleshakov pleshakov merged commit 497266d into main Jun 23, 2022
@pleshakov pleshakov deleted the feature/listeners branch June 23, 2022 03:35
@lucacome lucacome added the enhancement New feature or request label Aug 19, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants