-
Notifications
You must be signed in to change notification settings - Fork 292
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
feat(sessions): sessions table on project page #5204
Conversation
Looks good! Most of my comments are about optimizations for dataloaders and avoiding pulling from attributes over a connection. Assuming we will address these as follow-ups. Would be good to get a frontend review here as well. |
src/phoenix/db/migrations/versions/4ded9e43755f_create_project_sessions_table.py
Show resolved
Hide resolved
models.Span.attributes[INPUT_VALUE].label("value"), | ||
models.Span.attributes[INPUT_MIME_TYPE].label("mime_type"), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Non-blocking: We might want to think about materializing the input and output as their own columns so we can avoid querying attributes over a connection. Even with a dataloader, this led to performance issues with traces when the attributes are large.
|
||
async def _load_fn(self, keys: List[Key]) -> List[Result]: | ||
stmt = select(models.Trace).where(models.Trace.trace_id.in_(keys)) | ||
async with self._db() as session: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ahh the db sessions plus the product sessions, they have arrived haha
rootSpan { | ||
input { | ||
value | ||
} | ||
output { | ||
value |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah i see your point here, if there isn't a root span, this is gonna get nasty to deal with, can cross that bridge when we come to it i suppose
resolves #4959
resolves #5011
resolves #5014
resolves #5058
resolves #5059
resolves #5066