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

CASSGO-29 refactor packages to separate frontend api to backend internal api #465

Open
Zariel opened this issue Aug 30, 2015 · 7 comments · May be fixed by #1847
Open

CASSGO-29 refactor packages to separate frontend api to backend internal api #465

Zariel opened this issue Aug 30, 2015 · 7 comments · May be fixed by #1847

Comments

@Zariel
Copy link
Contributor

Zariel commented Aug 30, 2015

Currently everything exists within the gocql package, as the driver functionality expands the package gets more and more complicated.

We should maintain the current API in the gocql package, but move much of the internal things out into sub packages.

@Zariel
Copy link
Contributor Author

Zariel commented Sep 1, 2015

A good starting point would be to move the unexported marshalling code into an internal package and export just the Marshall / Unmarshall functions from the gocql package

@joao-r-reis joao-r-reis changed the title refactor packages to separate frontend api to backend internal api CASSGO-29 refactor packages to separate frontend api to backend internal api Nov 5, 2024
@OleksiienkoMykyta
Copy link
Contributor

@joao-r-reis I can handle it, but there are a few tricky moments:

  1. It would be nice to split gocql by multiple packages, but it will cause issues with backward compatibility, we can use type aliases like in the following PR or merge it to gocql v2.
  2. Also, we should decide what exactly we want to move to separate Go packages and what kind of architecture we want. Something could be changed during implementation, but there is a lot of work, so it would be great to have more details on this issue. In my opinion, it would be better to split the project into small packages like the marshal, framer, session, etc. to provide more flexibility and scalability, also it will make it easier to navigate through the project.

What do you think?

@joao-r-reis
Copy link
Contributor

joao-r-reis commented Nov 21, 2024

I think the project is not that big that it needs a lot of packages, the main purpose of this ticket should be to at least keep the public API stuff on the current gocql package and move everything else to an internal package in ./internal/.... After this then we can think of splitting the internal package into multiple internal packages but I'd focus on just having the gocql package for the public API and a single internal package to start with.

@joao-r-reis
Copy link
Contributor

joao-r-reis commented Nov 21, 2024

Maybe we could add an internal protocol package for framer and marshal code right away too (maybe a "native protocol package")

@joao-r-reis
Copy link
Contributor

Oh keep in mind that since this will change a lot of files it will be hard to keep the PR in sync with all other PRs that are waiting to be merged atm. There will be a lot of work involved in resolving git conflicts.

@OleksiienkoMykyta
Copy link
Contributor

Ok, I'll start with the framer, and then we can check it as an example

@joao-r-reis
Copy link
Contributor

Ok, I'll start with the framer, and then we can check it as an example

It might make more sense to group framer and native protocol stuff in a single package but I'm not sure

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

Successfully merging a pull request may close this issue.

3 participants