Skip to content

Conversation

@killzoner
Copy link
Contributor

Which issue does this PR close?

Closes #1395 (partially if we want to expand on future configurable cache later).

Rationale for this change

Disable explicitly cache() method with good user level error rather than relying on current panic

What changes are included in this PR?

Add cache factory to properly error the unsupported feature (links to apache/datafusion#18893)

Are there any user-facing changes?

User level error instead of panic

@killzoner killzoner marked this pull request as ready for review January 28, 2026 19:01
Copy link
Contributor

@milenkovicm milenkovicm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks @killzoner
I have one suggestion

}
}

impl CacheFactory for BallistaCacheFactory {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we make cache factory return a logical plan extension, something like https://github.com/apache/datafusion/blob/20d5f06a554f39407e52dd1d4848267dbc1467ce/datafusion-examples/examples/dataframe/cache_factory.rs#L103

but with two additional properties, session_id and cache_id (populated from random id), we can then serialize it and send it to scheduler. Scheduler will then fail as there is no implementation. So when users want to implement cache they just need to add new query planner

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah i see the link clearer with #1395 (comment) now.
Didn't know about this behaviour with the scheduler, will look into this, thanks !

@killzoner killzoner marked this pull request as draft January 28, 2026 19:38
@milenkovicm
Copy link
Contributor

no need to implement anything on scheduler side at the moment

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

bug: Disable DataFrame.cache() for ballista

2 participants