surrealdb.go
surrealdb.go copied to clipboard
[WIP] Resolver and Serialisation
The idea/solution i mentioned in #20
- Implemented RPCRawResponse/Serialisation changes
- Implemented the query resolver solution
- Started tests for resolver/serialisation
Only handled the regular Query() function so far It's pretty hacky in some places, was a quick put together as POC
TODO: Need to clean up the panics and find better solutions to them
Sorry for any spam 😅
I will see if i can work through these changes tomorrow and clear some bits up + add the go build tags for 18+
@Keitio what would we do with this panic here?
We wouldn't want to cancel the context/close the ws right? 🤔

Yeah, logging the error and then a continue would be more appropriate
F, I thought ready for review, would request another one, my bad...
Yeah I agree, it's quite large, but it's more of an optional/additional layer the dev can opt into to keep things a bit more simplified, for example, using .Query() and getting your individual item out of the result each time, gets boring fast, and then you write a wrapper to do it.... then every person does the same thing, it makes sense to have an option for that being handled
Things that you think shouldn't be exposed like that, can be sorted, it's just a WIP, on my personal code, i don't usually care too much about things not being exported 😅
Yep, no problems with that ! Was just stating my personal opinion on the current state of your branch just for you to get some (albeit very opinionated) feedback
Hey @iDevelopThings 👋 Thanks for opening this! Do you want to continue trying to merge this or can we close this PR? Will assign @timpratim if we do decide to continue. It would be good to resolve the merge conflicts to make it easier to review.