Golang项目结构域模型包

I have a question about the Golang project structure. Assume that this is my project structure in high level:

enter image description here

The project fzr defines yaml structure, which I need to parse and provide functions, to get data on top of this yaml file content.

  • the model contains all the structs
  • the provider contains the yaml.Unmarshal to parse the structs and provide objects which contain all the yaml file data

Assume that I need to provide functions on top of the structs data, such as:

  • getUserApps
  • getServices
  • getUserServices
  • getApps
  • getUserByIde
  • etc..

Where should these functions be placed? Maybe in a new created package under fzr? I don't want to use the flat option.

Of course, I can place some files under the provider package, which contains all the function there, but not sure if this would be clean? Go package structure is quite confusing me.