René's URL Explorer Experiment


Title: feat(session): configure DataFusion's built-in CacheManager from Java by LantaoJin · Pull Request #78 · apache/datafusion-java · GitHub

Open Graph Title: feat(session): configure DataFusion's built-in CacheManager from Java by LantaoJin · Pull Request #78 · apache/datafusion-java

X Title: feat(session): configure DataFusion's built-in CacheManager from Java by LantaoJin · Pull Request #78 · apache/datafusion-java

Description: Which issue does this PR close? Closes #74 . Rationale for this change DataFusion's RuntimeEnv accepts a CacheManagerConfig with three independent caches: the file-embedded metadata cache (parquet footers / page metadata), the list-files cache (object-store LIST results), and the file-statistics cache (per-file row counts and column stats used by the planner). The Rust API is RuntimeEnvBuilder::with_cache_manager(CacheManagerConfig). The Java binding has no surface for any of it — every SessionContext ends up with the no-op upstream defaults today, so a parquet workload reading the same footer thousands of times across queries goes back to the object store every single time, and statistics-driven planners can't persist their stats across queries. This PR adds a typed cacheManager(CacheManagerOptions) setter on SessionContextBuilder that exposes the three caches independently: SessionContext ctx = SessionContext.builder() .cacheManager(CacheManagerOptions.builder() .fileMetadataCache(64L << 20) // 64 MiB cap .listFilesCache(8L << 20, Duration.ofMinutes(5)) // 8 MiB cap, 5min TTL .fileStatisticsCache(true) .build()) .build(); Semantics, all matching upstream (datafusion). Three independent toggles, all matching upstream: Field Java unset → Rust behaviour fileMetadataCache(maxBytes) leave metadata_cache_limit at upstream default listFilesCache(maxBytes,ttl) leave list_files_cache = None (disabled) fileStatisticsCache(enabled) leave table_files_statistics_cache = None What changes are included in this PR? Proto: proto/cache_manager_options.proto. Java API: org.apache.datafusion.CacheManagerOptions Native: native/src/cache_manager.rs Build wiring: proto/cache_manager_options.proto Are these changes tested? Yes, 18 new tests cross CacheManagerOptionsTest and SessionContextCacheManagerTest. Are there any user-facing changes? Yes, but additive only — no breaking changes: New public class org.apache.datafusion.CacheManagerOptions with a static builder() and three setters. New SessionContextBuilder.cacheManager(CacheManagerOptions) setter. No behavior change for callers that do not invoke the new setter — the cache_manager field is absent on the wire and the native side leaves upstream's RuntimeEnvBuilder defaults in place.

Open Graph Description: Which issue does this PR close? Closes #74 . Rationale for this change DataFusion's RuntimeEnv accepts a CacheManagerConfig with three independent caches: the file-embedded metadata cache (pa...

X Description: Which issue does this PR close? Closes #74 . Rationale for this change DataFusion&#39;s RuntimeEnv accepts a CacheManagerConfig with three independent caches: the file-embedded metadata cache...

Opengraph URL: https://github.com/apache/datafusion-java/pull/78

X: @github

direct link

Domain: github.com

IPv4 address: 140.82.112.3

react-profiling0
react-import-mapreact,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322
route-pattern/:user_id/:repository/pull/:id/files(.:format)
route-controllerpull_requests
route-actionfiles
fetch-noncev2:bb7b25bf-a030-2a47-0ab5-61d82c9fc692
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-idE9E4:2009FB:2ACE34:3C7372:6B046A5F
html-safe-nonce3a35132bad16fbe5ad9a4d9ad84d13ea2434bd87bc352391e4ff7ba46ca04566
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFOUU0OjIwMDlGQjoyQUNFMzQ6M0M3MzcyOjZCMDQ2QTVGIiwidmlzaXRvcl9pZCI6IjIzMjYzMzYyNDEzMDM1NzkyMzEiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ==
visitor-hmacfc9608fb5dca74e805dc29cdf7b8bdbdc9fa11dad3b29f9b80247200d437abbc
hovercard-subject-tagpull_request:3720798663
github-keyboard-shortcutsrepository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///pull_requests/show/files
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/apache/datafusion-java/pull/78/files
twitter:imagehttps://avatars.githubusercontent.com/u/1853780?s=400&v=4
twitter:cardsummary_large_image
og:imagehttps://avatars.githubusercontent.com/u/1853780?s=400&v=4
og:image:altWhich issue does this PR close? Closes #74 . Rationale for this change DataFusion's RuntimeEnv accepts a CacheManagerConfig with three independent caches: the file-embedded metadata cache (pa...
og:site_nameGitHub
og:typeobject
hostnamegithub.com
expected-hostnamegithub.com
None83e4c0e58c5162177f3c161c5fbad38527ae04c11ac14980f9f9d85ae2027b1f
turbo-cache-controlno-preview
diff-viewunified
go-importgithub.com/apache/datafusion-java git https://github.com/apache/datafusion-java.git
octolytics-dimension-user_id47359
octolytics-dimension-user_loginapache
octolytics-dimension-repository_id1237105117
octolytics-dimension-repository_nwoapache/datafusion-java
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id1237105117
octolytics-dimension-repository_network_root_nwoapache/datafusion-java
turbo-body-classeslogged-out env-production page-responsive full-width
disable-turbotrue
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
releaseca4d07a7cef4e4b75f821dc25e7300d80c1450a9
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/apache/datafusion-java/pull/78/files#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fapache%2Fdatafusion-java%2Fpull%2F78%2Ffiles
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fapache%2Fdatafusion-java%2Fpull%2F78%2Ffiles
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fpull_requests%2Fshow%2Ffiles&source=header-repo&source_repo=apache%2Fdatafusion-java
Reloadhttps://github.com/apache/datafusion-java/pull/78/files
Reloadhttps://github.com/apache/datafusion-java/pull/78/files
Reloadhttps://github.com/apache/datafusion-java/pull/78/files
apachehttps://github.com/apache
datafusion-javahttps://github.com/apache/datafusion-java
Codehttps://github.com/apache/datafusion-java
Issues10 (10)https://github.com/apache/datafusion-java/issues
Pull requests10 (10)https://github.com/apache/datafusion-java/pulls
Discussionshttps://github.com/apache/datafusion-java/discussions
Actionshttps://github.com/apache/datafusion-java/actions
Security and qualityhttps://github.com/apache/datafusion-java/security
Insightshttps://github.com/apache/datafusion-java/insights
Sign up for GitHub https://github.com/signup?return_to=%2Fapache%2Fdatafusion-java%2Fissues%2Fnew%2Fchoose
terms of servicehttps://docs.github.com/terms
privacy statementhttps://docs.github.com/privacy
Sign inhttps://github.com/login?return_to=%2Fapache%2Fdatafusion-java%2Fissues%2Fnew%2Fchoose
andygrovehttps://github.com/andygrove
apache:mainhttps://github.com/apache/datafusion-java/tree/main
LantaoJin:feat/cache-managerhttps://github.com/LantaoJin/datafusion-java/tree/feat/cache-manager
Conversation 0 https://github.com/apache/datafusion-java/pull/78
Commits 2 https://github.com/apache/datafusion-java/pull/78/commits
Checks 1 https://github.com/apache/datafusion-java/pull/78/checks
Files changed https://github.com/apache/datafusion-java/pull/78/files
Please reload this pagehttps://github.com/apache/datafusion-java/pull/78/files
feat(session): configure DataFusion's built-in CacheManager from Java https://github.com/apache/datafusion-java/pull/78/files#top
Show all changes 2 commits https://github.com/apache/datafusion-java/pull/78/files
7ad5db5 feat(session): configure DataFusion's built-in CacheManager from Java LantaoJin May 21, 2026 https://github.com/apache/datafusion-java/pull/78/commits/7ad5db5176c868413719492011ccfdb0f0d81d27
ecbc58f Merge remote-tracking branch 'upstream/main' into feat/cache-manager LantaoJin May 21, 2026 https://github.com/apache/datafusion-java/pull/78/commits/ecbc58f84bcc1e4654b7145da80f6dfa7661c23d
Clear filters https://github.com/apache/datafusion-java/pull/78/files
Please reload this pagehttps://github.com/apache/datafusion-java/pull/78/files
Please reload this pagehttps://github.com/apache/datafusion-java/pull/78/files
CacheManagerOptions.java https://github.com/apache/datafusion-java/pull/78/files#diff-d1c1f1c1d0fb75b05e6757fb9346603d4b1360891a18191622baedf77d10832b
SessionContextBuilder.java https://github.com/apache/datafusion-java/pull/78/files#diff-d94f9dc56a90ad2e3f99a7814d387f3c924307f9632b0ea8fe5f4ac2b08a2532
CacheManagerOptionsTest.java https://github.com/apache/datafusion-java/pull/78/files#diff-df34e90135df0910567fbe8b70b7e0dbb920828028086753836245516e19abbe
SessionContextCacheManagerTest.java https://github.com/apache/datafusion-java/pull/78/files#diff-1df919311b69ddf2426a7193eb107e4415c28b074435129abc3f449d40160bd1
build.rs https://github.com/apache/datafusion-java/pull/78/files#diff-358ae2245aa2cd99768b0c568a07648d4c26c8cdd84b15cd6f0af2680ec85240
cache_manager.rs https://github.com/apache/datafusion-java/pull/78/files#diff-89096735e20cade76f6d36b7c80d8e6a4629ef086abec44a76a352e34b3d2310
lib.rs https://github.com/apache/datafusion-java/pull/78/files#diff-697685fba8d3d4a3a8a287bad6e1369e50e1c98bd878823415758c2a642cbb6e
cache_manager_options.proto https://github.com/apache/datafusion-java/pull/78/files#diff-7c683cb4003eb12bafe15b21a2f9bca4aa5f1e5c16013afee88963e27cc33b2c
session_options.proto https://github.com/apache/datafusion-java/pull/78/files#diff-0b48e973a751cd44663289ad7c1db4671e9262f89545cf6d4a518d774c1bd904
core/src/main/java/org/apache/datafusion/CacheManagerOptions.javahttps://github.com/apache/datafusion-java/pull/78/files#diff-d1c1f1c1d0fb75b05e6757fb9346603d4b1360891a18191622baedf77d10832b
View file https://github.com/LantaoJin/datafusion-java/blob/ecbc58f84bcc1e4654b7145da80f6dfa7661c23d/core/src/main/java/org/apache/datafusion/CacheManagerOptions.java
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/apache/datafusion-java/pull/78/{{ revealButtonHref }}
core/src/main/java/org/apache/datafusion/SessionContextBuilder.javahttps://github.com/apache/datafusion-java/pull/78/files#diff-d94f9dc56a90ad2e3f99a7814d387f3c924307f9632b0ea8fe5f4ac2b08a2532
View file https://github.com/LantaoJin/datafusion-java/blob/ecbc58f84bcc1e4654b7145da80f6dfa7661c23d/core/src/main/java/org/apache/datafusion/SessionContextBuilder.java
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/apache/datafusion-java/pull/78/{{ revealButtonHref }}
https://github.com/apache/datafusion-java/pull/78/files#diff-d94f9dc56a90ad2e3f99a7814d387f3c924307f9632b0ea8fe5f4ac2b08a2532
https://github.com/apache/datafusion-java/pull/78/files#diff-d94f9dc56a90ad2e3f99a7814d387f3c924307f9632b0ea8fe5f4ac2b08a2532
https://github.com/apache/datafusion-java/pull/78/files#diff-d94f9dc56a90ad2e3f99a7814d387f3c924307f9632b0ea8fe5f4ac2b08a2532
https://github.com/apache/datafusion-java/pull/78/files#diff-d94f9dc56a90ad2e3f99a7814d387f3c924307f9632b0ea8fe5f4ac2b08a2532
https://github.com/apache/datafusion-java/pull/78/files#diff-d94f9dc56a90ad2e3f99a7814d387f3c924307f9632b0ea8fe5f4ac2b08a2532
https://github.com/apache/datafusion-java/pull/78/files#diff-d94f9dc56a90ad2e3f99a7814d387f3c924307f9632b0ea8fe5f4ac2b08a2532
core/src/test/java/org/apache/datafusion/CacheManagerOptionsTest.javahttps://github.com/apache/datafusion-java/pull/78/files#diff-df34e90135df0910567fbe8b70b7e0dbb920828028086753836245516e19abbe
View file https://github.com/LantaoJin/datafusion-java/blob/ecbc58f84bcc1e4654b7145da80f6dfa7661c23d/core/src/test/java/org/apache/datafusion/CacheManagerOptionsTest.java
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/apache/datafusion-java/pull/78/{{ revealButtonHref }}
Please reload this pagehttps://github.com/apache/datafusion-java/pull/78/files
Please reload this pagehttps://github.com/apache/datafusion-java/pull/78/files
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Response headers:
Servergithub.com
Content-Typetext/html; charset=utf-8
Cache-Controlno-cache

Viewport: width=device-width


URLs of crawlers that visited me.