Skip to content

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

Open
iemejia wants to merge 1 commit intoapache:mainfrom
iemejia:fix/fastreaderbuilder-use-classutils-forname
Open

AVRO-4189: [Java] Use ClassUtils.forName() in FastReaderBuilder for consistency#3693
iemejia wants to merge 1 commit intoapache:mainfrom
iemejia:fix/fastreaderbuilder-use-classutils-forname

Conversation

@iemejia
Copy link
Member

@iemejia iemejia commented Mar 19, 2026

I noticed that 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)

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.
@github-actions github-actions bot added the Java Pull Requests for Java binding label Mar 19, 2026
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.

1 participant