transaction-outbox icon indicating copy to clipboard operation
transaction-outbox copied to clipboard

Lookup bytebuddy strategy for JDK 17+

Open m1c1b opened this issue 9 months ago • 5 comments

Summary

This merge request introduces several enhancements and new features to the library, focusing on improving abstraction, readability, and compatibility with newer JDK versions.

Changes Made

  • AbstractProxyFactory Abstraction:

    • Created an AbstractProxyFactory to provide a more structured and reusable abstraction layer for proxy factories.
  • LookupProxyFactory for JDK 17+:

    • Developed a new version of ProxyFactory named LookupProxyFactory.
    • Utilizes the Lookup ByteBuddy method for class loading, addressing the requirements for JDK 17 and above as per JEP 403.
  • Builder Enhancement:

    • Introduced a new method in the builder, allowing users of the library to conveniently create their own Proxy Factory implementations.
  • Improved Readability:

    • Reordered methods to enhance the readability and maintainability of the code.
  • Static Imports and Refactoring:

    • Added a few static imports to make the code more concise.
    • Reduced the number of return statements in methods to streamline the code flow.
  • Test Coverage:

    • Duplicated the existing ProxyFactory tests for the new LookupProxyFactory to ensure comprehensive test coverage.

Documentation Note

I am currently uncertain whether to update the main documentation with these changes or to assume that developers will study the source code directly, given the highly technical nature of these updates. If it is deemed necessary to update the documentation to reflect these changes, I am more than willing to do so.

m1c1b avatar May 24 '24 06:05 m1c1b