Skip to content

AVRO-4189: [Java] Use ClassUtils.forName() in FastReaderBuilder for consistency (#3693)#3716

Open
iemejia wants to merge 1 commit intoapache:branch-1.12from
iemejia:branch-1.12
Open

AVRO-4189: [Java] Use ClassUtils.forName() in FastReaderBuilder for consistency (#3693)#3716
iemejia wants to merge 1 commit intoapache:branch-1.12from
iemejia:branch-1.12

Conversation

@iemejia
Copy link
Copy Markdown
Member

@iemejia iemejia commented Apr 1, 2026

FastReaderBuilder.findClass() was using data.getClassLoader().loadClass() directly, bypassing ClassUtils.forName() which is used everywhere else in the codebase. This change aligns FastReaderBuilder with the standard class loading path and adds tests for class loading behavior.

What is the purpose of the change

(For example: This pull request improves file read performance by buffering data, fixing AVRO-XXXX.)

Verifying this change

(Please pick one of the following options)

This change is a trivial rework / code cleanup without any test coverage.

(or)

This change is already covered by existing tests, such as (please describe tests).

(or)

This change added tests and can be verified as follows:

(example:)

  • Extended interop tests to verify consistent valid schema names between SDKs
  • Added test that validates that Java throws an AvroRuntimeException on invalid binary data
  • Manually verified the change by building the website and checking the new redirect

Documentation

  • Does this pull request introduce a new feature? (yes / no)
  • If yes, how is the feature documented? (not applicable / docs / JavaDocs / not documented)

…onsistency (apache#3693)

FastReaderBuilder.findClass() was using data.getClassLoader().loadClass()
directly, bypassing ClassUtils.forName() which is used everywhere else in
the codebase. This change aligns FastReaderBuilder with the standard class
loading path and adds tests for class loading behavior.
@iemejia iemejia requested a review from gszadovszky April 1, 2026 10:07
@github-actions github-actions bot added the Java Pull Requests for Java binding label Apr 1, 2026
@iemejia
Copy link
Copy Markdown
Member Author

iemejia commented Apr 1, 2026

Cherry-picks #3716 into the 1.12 branch

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

Labels

Java Pull Requests for Java binding

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants