Kimblis
Explore posts from serversNew versions doesn't fit the docs?
I just updated versions of my packages and now I get typescript errors that the my query doesn't fit with the types. It says that I'm missing
initialData and queryKey
for .useQuery() however docs says that the queryKey should be auto generated. No?
My package versions:
Query example:
```5 replies
Trpc in monorepo with microservices
Hello, so I have monorepo with multiple services. Each client currently has 1 backend for it so it was working well so far, however now I'm building new services (backend only) and I want to either contact them as well through my client (means 1 client should have multiple trpc clients) or my trpc servers should be able to communicate between themselves. What would be the preferable approach and are there any best practices developed on this front yet?
2 replies
PPrisma
•Created by Kimblis on 3/22/2024 in #help-and-questions
Connecting relations misunderstanding
1 replies
Subscriptions between different services
How do you make subscriptions to work between different services? For example if we have two different services- teacher and student, both have separate backend and frontend. Can we use redis or something similar so they would communicate correctly? Also it wouldn't work for multi instances for the same instances as well, right? If we save everything in the instance memory, or am I wrong?
2 replies
Sentry integration
Hello. I'm using trpc + fastify approach. I need a proper error loggin so I added fastify sentry, which works fine and logs the errors, however i'm missing some context- trpc data sent for the query/mutation, user information and etc. I would like to add that. Anyone had to deal with this before? So far can't find a decent solution for this, especially for retrieving the input.
5 replies
trpc/react-query batching
Hi. How do you deal with batching? If I don't put any maxURLLength then I get an error 404 since it cuts of some of the requests urls... If I put url length then some requests just does not get executed since url is getting too long. I was thinking about max batching size however react-query does not have that... Any ideas on how to best deal with this?
5 replies
Prisma+TRPC monorepo
Hey, so we have a monorepo with 3 backend services and 3 frontend services. It looks like the following:
- Content frontend
- Content backend
- Teacher backend
- Teacher frontend
....
The problem we are facing: If we want from frontend to interact with 2 backends or from 1 backend to another backend. The easier example would be the second one. For example I try to communicate with content backend from my teacher backend. I get the errors when I try to build teacher backend since it knows only about the schema it has and the prisma client is being generated from that schema, so when it imports router from content backend- it goes through all routers and their imports, where they import things from content-backend prisma client (which looks different than teachers client :/ )
1 replies