Skip to content

Move logic to set a specific pack namespace to its own method.#23

Merged
gap777 merged 1 commit intoFlytedesk:mainfrom
vaot:automatic-namespaces-on-demand
Nov 13, 2024
Merged

Move logic to set a specific pack namespace to its own method.#23
gap777 merged 1 commit intoFlytedesk:mainfrom
vaot:automatic-namespaces-on-demand

Conversation

@vaot
Copy link
Contributor

@vaot vaot commented Nov 12, 2024

Context

Applications might want to enforce automatic namespaces based on certain criteria specific to their package.yml, let's say, version: v2, or any other application-specific property. By exposing a public method to do the namespacing, applications can call this method rather than duplicating the code from this gem.

Changes

  • Extract loop logic into its own method where we can define a namespace per pack/metadata
  • Renaming set namespacing method for clarity given the new changes

This allows applications to hook into this public method to do
any on-demand custom namespacing without duplicating the logic
defined in this gem.
@vaot
Copy link
Contributor Author

vaot commented Nov 12, 2024

Hey @gap777, would love to hear your thoughts on this one.

@gap777 gap777 merged commit 3159275 into Flytedesk:main Nov 13, 2024
@vaot
Copy link
Contributor Author

vaot commented Nov 13, 2024

@gap777 Thank you. One thing that I was hoping to get your take on is: Autoloader is currently private, do you think we can make it public or expose the logic to define the namespace via a different interface?

@gap777
Copy link
Collaborator

gap777 commented Nov 13, 2024

I just merged your PR, as I thought it satisfied your use case.... please open a new one with the changes you're proposing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants