Skip to content

feat: use new codecs#766

Merged
ngmr merged 18 commits intoOpenLiberty:mainfrom
joe-chacko:feat/744-use-new-codecs
Feb 24, 2026
Merged

feat: use new codecs#766
ngmr merged 18 commits intoOpenLiberty:mainfrom
joe-chacko:feat/744-use-new-codecs

Conversation

@joe-chacko
Copy link
Member

No description provided.

@joe-chacko joe-chacko self-assigned this Feb 2, 2026
@joe-chacko joe-chacko requested a review from ngmr February 2, 2026 12:03
Add octet count calculation methods to CharCodec and WcharCodec interfaces
to support efficient buffer allocation and encoding size prediction.

BREAKING CHANGES:
- Renamed WcharCodec methods for clarity:
  - readCharWithLength() → readLengthAndChar()
  - writeCharWithLength() → writeLengthAndChar()

Changes:
- Add CharCodec.isFixedWidth() to identify fixed-width encodings
- Add CharCodec.charSize() to get octets per char for fixed-width encodings
- Add CharCodec.octetCount(char) to calculate encoding size for a character
- Add WcharCodec.octetCount(String) to calculate encoding size for strings
- Add WcharCodec.octetCountLengthsAndWchars(int) for GIOP 1.2 calculations
- Add CharCodec.NULL_CODEC constant for null codec reference
- Implement octetCount methods in Utf8Codec with surrogate pair handling
- Implement octetCount methods in SimpleWcharCodec (UTF_16 and NULL variants)
- Update Utf8Codec to mark isFixedWidth() as false and throw on charSize()
- Enhance AbstractSimpleCodecTest to verify octetCount accuracy after writeChar
- Add octetCount verification to AbstractLatinCodecTest
- Update test cases to use renamed methods (readLengthAndChar, writeLengthAndChar)
- Remove unused InternalException constructor in Utf8Codec
- Remove obsolete comment from Utf8Test
- Fix code formatting in AbstractSimpleCodecTest (interface declarations)
- Improve code documentation and comments

The new octet count methods enable:
- Pre-calculation of buffer sizes before encoding
- Validation of encoded data sizes
- Better memory allocation strategies
- Support for GIOP 1.2 length-prefixed encoding calculations
@joe-chacko joe-chacko force-pushed the feat/744-use-new-codecs branch 2 times, most recently from 1fc32e4 to c133e79 Compare February 4, 2026 19:03
Replace the legacy CodeConverter architecture with the new CharCodec/WcharCodec
interfaces throughout YokoInputStream and YokoOutputStream, simplifying character
encoding logic and improving maintainability.

BREAKING CHANGES:
- Remove CodeConverterBase, CodeConverterImpl, CodeConverterNone classes
- Remove CodeSetReader and CodeSetWriter interfaces
- Restructure CodeConverters to use CharCodec/WcharCodec instead of converters
- Change CodeConverters.NULL_CONVERTER to CodeConverters.COLLOCATED
- Remove conversion/reader/writer flags from stream classes

Major changes:
- Refactor YokoInputStream to use CharCodec/WcharCodec directly:
  - Simplify read_char() to use codec.readChar()
  - Simplify read_wchar() with codec methods based on GIOP version
  - Simplify read_string() to use codec with proper buffer handling
  - Simplify read_wstring() with separate methods for GIOP versions
  - Remove all character conversion and reader flag logic
  - Simplify array reading methods to use single-char methods

- Refactor YokoOutputStream to use CharCodec/WcharCodec directly:
  - Simplify write_char() to use codec.writeChar() with octetCount
  - Simplify write_wchar() with codec methods based on GIOP version
  - Rewrite write_string() with fixed-width and variable-width paths
  - Rewrite write_wstring() with separate methods for GIOP versions
  - Remove all character conversion and writer flag logic
  - Simplify array writing methods to use single-char methods
  - Remove char bounds checking (now handled by codecs)

- Update CodeConverters class:
  - Replace converter fields with charCodec and wcharCodec
  - Simplify create() method to use CharCodec.forRegistryId()
  - Remove CodeSetDatabase.getConverter() calls
  - Update COLLOCATED constant (formerly NULL_CONVERTER)

- Update CharCodec.forRegistryId():
  - Add null check with descriptive exception
  - Add ISO_LATIN_1 case
  - Delegate to LatinCodec.getLatinCodec() for other cases
  - Remove unreachable throw statement

- Update CodeSetUtil and GIOPConnection:
  - Use CodeConverters.create() with registry IDs directly
  - Remove ORBInstance parameter (no longer needed)

- Update CollocatedClient:
  - Use CodeConverters.COLLOCATED instead of NULL_CONVERTER

- Clean up imports and formatting:
  - Remove unused CodeConverter imports
  - Add CharCodec and WcharCodec imports
  - Use static import for IntStream.range
  - Fix typo: "encapsulaton" → "encapsulation"
  - Improve comment formatting and clarity
  - Remove redundant comments
  - Remove unused import in AbstractSimpleCodecTest

Performance improvements:
- Eliminate redundant conversion checks and flag evaluations
- Use codec octetCount() for accurate buffer allocation
- Reduce temporary buffer allocations in string operations
- Simplify control flow in character encoding/decoding

The refactoring maintains backward compatibility at the protocol level while
significantly simplifying the internal implementation and improving code clarity.
Complete the transition from CodeConverter to CharCodec/WcharCodec by removing
all legacy converter classes and updating remaining references throughout the
codebase. This is the final commit in the codec refactoring series.

BREAKING CHANGES:
- Remove CodeConverterBase, CodeConverterImpl, CodeConverterNone classes
- Remove CodeSetReader, CodeSetWriter, UTF8Reader, UTF8Writer classes
- Remove CharMapInfo enum and character mapping database
- Rename CodeConverters to CodecPair throughout codebase
- Remove CodeSetDatabase.getConverter() method
- Delete org.apache.yoko.orb.CORBA.Any class (1138 lines)
- Remove ConversionWidthsTest and TestCharMapConversions test classes

Core changes:
- Rename CodeConverters class to CodecPair:
  - Replace converter fields with charCodec and wcharCodec
  - Rename NULL_CONVERTER to COLLOCATED
  - Simplify create() to use CharCodec/WcharCodec.forRegistryId()
  - Remove ORBInstance parameter from create() method
  - Update createForWcharWriteOnly() to use WcharCodec.getDefault()

- Add getCodeSetInfo() method to CharCodec interface:
  - Implement in SimpleCharCodec (US_ASCII, ISO_LATIN_1)
  - Implement in SimpleWcharCodec (UTF_16, NULL)
  - Implement in Utf8Codec (UTF_8)
  - Implement in LatinCodec with CodeSetInfo field
  - Returns CodeSetInfo.NONE for NULL codec

- Update Util class documentation and implementation:
  - Fix typo: "multi-byte" → "multibyte"
  - Improve javadoc for expect7bit(), require7bit(), require8bit()
  - Use bit-shift operators for clearer bounds checking
  - Fix comment: "unicode" → "Unicode"

- Update YokoInputStream:
  - Rename _OB_codeConverters() to getCodecs()
  - Update all internal references to use codecs field
  - Update method calls to use CodecPair

- Update YokoOutputStream:
  - Update constructor to use CodecPair
  - Update all internal references to use codecs field

- Update all client code:
  - CollocatedClient: use CodecPair.COLLOCATED
  - GIOPConnection: use CodecPair.create()
  - CodeSetUtil: remove ORBInstance parameter from create() calls
  - Upcall: use getCodecs() instead of _OB_codeConverters()
  - UnresolvedException: use getCodecs() instead of _OB_codeConverters()
  - UtfStringsTest: use CodecPair instead of CodeConverters

Removed legacy code:
- Delete 1138-line Any.java class (replaced by modern implementation)
- Delete CodeConverterBase abstract class and implementations
- Delete CodeSetReader/Writer interfaces and UTF8Reader/Writer
- Delete CharMapInfo enum with character mapping tables
- Delete ConversionWidthsTest (functionality now in codec tests)
- Delete TestCharMapConversions (669 lines of legacy mapping tests)

The refactoring eliminates approximately 3000+ lines of legacy code while
maintaining full protocol compatibility and improving code maintainability.
All character encoding/decoding is now handled consistently through the
CharCodec and WcharCodec interfaces.
Remove the yoko.orb.extended_wchar configuration property and improve default
codeset selection for profiles without codeset components. IIOP 1.0 profiles
now use ISO Latin 1, while IIOP 1.1+ profiles default to UTF-8.

Changes:
- Remove ORBInstance.extendedWchar field and extendedWchar() method
- Remove yoko.orb.extended_wchar property parsing from ORBInstance constructor
- Simplify CodeSetUtil.getCodeSetInfoFromComponents():
  - Remove proprietary ISO Latin 1 / UCS-2 fallback for IIOP 1.0
  - IIOP 1.0 profiles consistently return null (no components)
  - Add clarifying comment about IIOP 1.0 having no components
- Improve CodeSetUtil.getCodeConverters() default behavior:
  - IIOP 1.0 profiles without components: ISO Latin 1 + default wchar
  - IIOP 1.1+ profiles without components: UTF-8 + default wchar
- Set defaultWcs to UTF_16.id instead of 0 in ORB_impl

Rationale:
The extended_wchar configuration was a proprietary extension that allowed
wchar/wstring support for IIOP 1.0 by assuming ISO Latin 1 for char and
UCS-2 for wchar. This is no longer needed.

This change adds a default wchar codeset for 1.0 that is
backwards-compatible with the previous (optional) default wchar codeset.

The default char codeset for 1.1+ is not UTF-8.
This only kicks in if the IOR does not contain a codesets component.
This is so iiop URLs can specify the version number as 1.2 and get a newer
default char codeset for an initial lookup. The 1.1/1.2 protocols allow
the codeset to be explicitly stated in a request.
@joe-chacko joe-chacko force-pushed the feat/744-use-new-codecs branch from c133e79 to 86994a1 Compare February 5, 2026 12:04
Refactor the codec system to better support collocated invocations, add an
unspecified codec for error detection, and improve string marshalling error
handling with better logging.

BREAKING CHANGES:
- Rename SimpleWcharCodec.NULL to COLLOCATED for clarity
- Replace CharCodec constants with static factory methods:
  - NULL_CHAR_CODEC → getCollocatedCharCodec()
  - DEFAULT_CHAR_CODEC → getDefaultCharCodec()
  - Add getUnspecifiedCharCodec() for error detection

Major changes:

Codec architecture improvements:
- Add SimpleWcharCodec.UNSPECIFIED codec that throws UnsupportedOperationException
  on all operations to detect improper codec usage
- Add CharCodec.isStateless() method (default true) to identify stateful codecs
- Add CodeSetInfo.COLLOCATED enum value for collocated invocations
- Rename SimpleWcharCodec.NULL to COLLOCATED for better clarity
- Update Utf8Codec.isStateless() to return false (stateful due to surrogate pairs)

CodecPair improvements:
- Make DEFAULT and COLLOCATED constants private
- Add getCollocatedCodecs() factory method for collocated invocations
- Improve createCopy() to avoid copying stateless codecs
- Update createForWcharWriteOnly() to use UNSPECIFIED char codec instead of null
- Reorder methods for better organization

String marshalling improvements:
- Add stringMarshallingError() helper method in YokoInputStream for consistent
  error reporting with context (string type, length, minor code)
- Improve error messages for string/wstring reading with better context
- Add bounds checking for negative string lengths
- Wrap IndexOutOfBoundsException with proper MARSHAL exceptions
- Improve logging with codec information in read/write operations

Logging improvements:
- Replace generic Logger with DATA_IN_LOG/DATA_OUT_LOG for verbose logging
- Add codec information to string read/write log messages
- Move WriteBuffer.recordLength() logging to use DATA_OUT_LOG
- Remove logger parameter from WriteBuffer.recordLength()
- Improve log message formatting with lambda expressions

Code cleanup:
- Update CollocatedClient to use getCollocatedCodecs() factory method
- Remove unused logger imports
- Improve code organization and readability
- Add detailed javadoc for new methods

The refactoring improves error detection, provides better diagnostic information
for debugging marshalling issues, and makes the codec architecture more explicit
about its intended usage patterns.
Fix collocated invocations to properly initialize output streams with codecs
and GIOP version, and make COLLOCATED CodecPair constant private.

Changes:
- Update CollocatedClient.startDowncall() to create YokoOutputStream with:
  - Proper collocated codecs via CodecPair.getCollocatedCodecs()
  - Correct GIOP version from the profile info
  - Previously used no-arg constructor which defaulted to null codecs
- Make CodecPair.COLLOCATED constant private (was package-private)
  - Forces use of getCollocatedCodecs() factory method
  - Ensures proper codec initialization for collocated calls
- Add GiopVersion import to CollocatedClient
- Remove unnecessary blank lines and comments in:
  - ClientManager (remove empty comment blocks)
  - POAManager_impl (remove extra blank line)

Rationale:
The previous code created YokoOutputStream with the no-arg constructor,
which resulted in null codecs. This caused NullPointerException when
trying to marshal strings in collocated invocations. The fix ensures
that collocated invocations use proper codecs and GIOP version from
the profile information.

This completes the codec refactoring by ensuring all YokoOutputStream
instances are properly initialized with codecs, preventing NPEs during
string marshalling operations.
@joe-chacko joe-chacko force-pushed the feat/744-use-new-codecs branch 2 times, most recently from 91e2530 to dd028c7 Compare February 6, 2026 18:10
@joe-chacko joe-chacko force-pushed the feat/744-use-new-codecs branch from 8bb6bf7 to ac8e008 Compare February 13, 2026 16:56
Move all codec factory methods to new Codex class and rename WcharCodec
methods to clarify GIOP version-specific behavior.

BREAKING CHANGES:
- CharCodec static factory methods moved to Codex class:
  - CharCodec.forName() → Codex.getCharCodec(String)
  - CharCodec.forRegistryId() → Codex.getCharCodec(int)
  - CharCodec.getDefaultCharCodec() → Codex.getDefaultCharCodec()
  - CharCodec.getCollocatedCharCodec() → Codex.getCollocatedCharCodec()
  - CharCodec.getUnspecifiedCharCodec() → removed (use Codex.getUnspecifiedWcharCodec())
- WcharCodec static factory methods moved to Codex class:
  - WcharCodec.forRegistryId() → Codex.getWcharCodec(int)
  - WcharCodec.getDefaultWcharCodec() → Codex.getDefaultWcharCodec()
  - WcharCodec.getCollocatedWcharCodec() → Codex.getCollocatedWcharCodec()
- WcharCodec methods renamed to clarify GIOP version usage:
  - readCharWithEndianFlag() → readWchar_1_0()
  - writeChar() → writeWchar_1_0()
  - readLengthAndChar() → readWchar_1_2()
  - writeLengthAndChar() → writeWchar_1_2()
  - beginToReadString() → beginToReadWstring_1_2()
  - beginToWriteString() → beginToWriteWstring_1_2()
  - octetCount() → octetCountWstring_1_2()
  - octetCountLengthsAndWchars() → octetCountWchars_1_2()
  - charSize() → removed (always 2 bytes for GIOP 1.0/1.1)
- CharCodec.CharReader → WcharCodec.WcharReader
  - readChar() → readWchar()
- CharCodec/WcharCodec.getInstanceOrCopy() → duplicate()
- CharCodec.isStateless() removed (now determined by duplicate() identity check)

Changes:
- Create new Codex class as central factory for all codec instances
  - Consolidates codec creation logic in one place
  - Provides factory methods for both CharCodec and WcharCodec
  - Includes getDefaultCodecs(GiopVersion) for version-specific defaults
- Rename WcharCodec methods to include GIOP version suffixes
  - Makes it explicit which methods are for GIOP 1.0/1.1 vs 1.2
  - Reduces confusion about when to use each method
  - Improves code readability at call sites
- Move CharReader inner interface to WcharCodec as WcharReader
  - More accurate naming since it's only used for wide chars
  - Rename readChar() to readWchar() for consistency
- Rename getInstanceOrCopy() to duplicate() in both interfaces
  - More intuitive name for creating concurrent-safe copies
  - Follows common naming patterns (e.g., ByteBuffer.duplicate())
- Remove isStateless() method from CharCodec
  - Now determined by identity check: codec.duplicate() == codec
  - Simplifies interface and implementation
- Update CodecPair to use new Codex factory methods
  - Add GIOP_1_2_DEFAULT constant (uses UTF-8 for char codec)
  - Replace createForWcharWriteOnly() with getDefaultCodecs(GIOP1_2)
  - Simplify createCopy() using identity check for statefulness
- Update all call sites in YokoInputStream/YokoOutputStream
  - Use renamed wchar methods with version suffixes
  - Remove hardcoded 2-byte size, use literal 2 for clarity
- Update all test classes to use Codex factory methods
  - Replace CharCodec.forName() with Codex.getCharCodec()
  - Update test constructors to pass codec instances directly

Rationale:
The previous design scattered codec factory methods across CharCodec and
WcharCodec interfaces, making it unclear where to find codec creation
logic. The WcharCodec method names didn't indicate which GIOP version
they were for, leading to potential confusion. This refactoring:

1. Centralizes all codec creation in the Codex class
2. Makes GIOP version requirements explicit in method names
3. Simplifies the codec interfaces by removing factory methods
4. Improves code clarity and maintainability
5. Provides version-specific default codec pairs
Improve code readability and maintainability in POA implementation and
servant dispatcher through consistent formatting and simplification.

Changes in POA_impl.java:
- Add static imports for commonly used constants and methods:
  - ObjectKey.ParseObjectKey, SynchronizationPolicyValue constants
  - MinorCodes constants and description methods
- Convert logging statements to use lambda expressions for lazy evaluation
  - find_POA(), create_POA() now use lambda logging
- Simplify conditional statements and remove unnecessary braces:
  - Inline single-statement if blocks where appropriate
  - Remove redundant null checks before throws
- Remove excessive blank lines and comment blocks:
  - Remove "// ----" separator lines
  - Remove empty comment blocks with just "//"
  - Consolidate multi-line comments to single lines where appropriate
- Improve method formatting:
  - Align method parameters consistently
  - Remove unnecessary line breaks in method signatures
- Simplify stream operations:
  - Replace .stream().toArray() with .toArray(new Type[0])
  - Add early break in loop when condition is met
- Remove unused imports:
  - Remove java.util.Enumeration (replaced with Collection.forEach)
  - Remove org.apache.yoko.util.MinorCodes (now using static imports)
- Replace Enumeration iteration with modern forEach:
  - _OB_etherealize() now uses children_.values().forEach()
- Fix typos in comments:
  - "Eterealize" → "Etherealize"
  - "assocatied" → "associated"
  - "might operation" → "might operate"
- Improve error message formatting:
  - Use static imports for MinorCodes description methods
  - Consolidate multi-line exception constructions

Changes in ServantDispatcher.java:
- Rename fields for clarity:
  - upcall_ → upcall
  - servant_ → servant
- Add missing imports for better IDE support
- Simplify dispatchBase() method:
  - Replace binary search with switch statement on operation name
  - Remove unnecessary intermediate variables
  - Make operation name matching more explicit
- Make Abort exception static (no need for outer class reference)
- Improve variable naming:
  - _ob_op → opName
  - Remove Hungarian notation prefixes
- Consolidate variable declarations with usage
- Remove excessive blank lines and comments
- Simplify conditional logic:
  - Remove unnecessary braces for single-statement blocks
  - Inline simple conditions

Changes in GIOPConnection.java:
- Fix grammar: "decision making" → "decision-making"

Rationale:
This refactoring improves code maintainability without changing behavior:
- Lambda logging prevents string formatting when logging is disabled
- Static imports reduce verbosity for frequently used constants
- Modern Java idioms (forEach, enhanced switch) improve readability
- Consistent formatting makes code easier to scan and understand
- Removing excessive comments and blank lines reduces visual clutter
- Better variable names make code self-documenting

No functional changes - purely formatting and style improvements.
…dling

- Refactor LatinCodec to accept CodeSetInfo in constructor
- Replace NAME constants with inline string literals in switch cases
- Rename private interfaces from ISO_8859_X to Iso8859_X for consistency
- Add static imports for CodeSetInfo constants (ISO_8859_5-9, ISO_LATIN_2-4)
- Remove UTF_8 restriction in native_cs validation in ORB_impl
Ensure YokoInputStream has proper codecs before unmarshalling by extracting
and applying codeset information from service contexts in preUnmarshal().

Changes:
- Add codec initialization logic to Upcall.preUnmarshal():
  - Detect collocated invocations (null transportInfo_)
  - Extract GIOP version from profile info
  - For collocated calls: use collocated codecs
  - For remote calls: extract CodeSetContext from service contexts
    - Parse CodeSets service context if present
    - Create CodecPair from negotiated char_data and wchar_data
    - Fall back to GIOP version defaults if no codeset context
  - Call in_.setCodecsAndGiopVersion() with resolved codecs
- Add Optional import for cleaner null handling
- Add CodeSets import for service context ID
- Reorganize imports (move static imports to end)

Rationale:
Previously, the input stream was created without codecs, relying on
lazy initialization or default behavior. This could cause issues when
unmarshalling strings before codecs were properly set. By initializing
codecs in preUnmarshal() based on the negotiated codesets from the
service context, we ensure:

1. Collocated invocations use optimized collocated codecs
2. Remote invocations use negotiated codesets from CodeSetContext
3. Fallback to GIOP version-appropriate defaults when no negotiation
4. Codecs are set before any unmarshalling operations begin

This completes the codec initialization chain:
- Downcall: codecs set when creating output stream
- Upcall: codecs set in preUnmarshal() before reading parameters

This fix prevents potential NullPointerException or incorrect character
encoding when unmarshalling string parameters in upcalls.
- Convert all POAPolicies fields to final for immutability
- Refactor policy parsing from if-else chain to switch statement
- Extract lock acquisition/release logic into separate methods in POA_impl
- Add try-finally block to ensure locks are always released
- Make ServantDispatcher fields final (upcall, servant)
- Make ThreadPolicyValue fields final (value, values array)
- Add POA initialization loggers (INIT_LOG, ORB_INIT_LOG, POA_INIT_LOG)
- Simplify policy recreation using array initializer
- Add warning logging for unsupported policy types
- Clean up imports and remove unnecessary fully-qualified names
- Fix typo in POA_impl comment ("used ensure" → "used to ensure")
Migrate the legacy CodeSets test from old server/client pattern to the
modern testify framework with JUnit 5.

- Create new CodeSetsTest using @ConfigureServer annotation
- Move test files from src/test/java to src/test/java-testify
- Replace separate Server/Client classes with unified test class
- Convert test methods to JUnit 5 @test annotations
- Use Bus for IOR sharing between server and client
- Remove legacy test infrastructure (runtest script, CodeSetsTest.java)
- Simplify test setup with @BeforeServer and @BeforeAll hooks
- Add comprehensive test classes for all ISO-8859-1 through ISO-8859-9 character sets
- Test same character set on both client and server (CodeSet1Test through CodeSet9Test)
- Test different character sets between client and server (CodeSets12Test through CodeSets91Test)
- Test client with Latin charset and server with default UTF-8 (CodeSets1DTest through CodeSets9DTest)
- Test server with Latin charset and client with default UTF-8 (CodeSetsD1Test through CodeSetsD9Test)

The new test maintains the same coverage (char, string, wchar, wstring)
while using modern testing patterns and eliminating boilerplate code.
Add test coverage for both UTF-8 and CESU-8 encoding of supplementary
characters (emoji) in UtfStringsTest.

- Add unicodeSupplementaryTestStrings() test data source with emoji
- Separate emoji tests from BMP character tests
- Add writeUtf8/readUtf8 tests for proper UTF-8 encoding (4-byte)
- Add writeCesu8/readCesu8 tests for CESU-8 encoding (two 3-byte)
- Add writeUtf16/readUtf16 tests for UTF-16 encoding
- Use YasfThreadLocal to control WRITE_UTF8_AS_UTF8 flag in tests
- Reformat existing test data for consistency
- Rename test methods for clarity (remove "String"/"Wstring" suffix)
- Move helper method to end of class

Tests verify that emoji characters (waving hand 👋, globe 🌍) are
correctly encoded in both UTF-8 (f09f918b) and CESU-8 (eda0bded b18b).
Add WRITE_UTF8_AS_UTF8 flag to Yasf enum to enable proper UTF-8 encoding
of surrogate pairs when communicating with newer Yoko versions.

Changes:
- Add WRITE_UTF8_AS_UTF8(2) to Yasf enum for stream format negotiation
- Modify Utf8Codec.writeChar() to conditionally handle surrogate pairs
  based on YASF flag support
- When flag is supported, properly validate and combine surrogate pairs
  into full codepoints before encoding
- When flag is not supported (older Yoko), fall back to CESU-8 behavior
  by encoding surrogates as individual 3-byte UTF-8 sequences

This change maintains backward compatibility with older Yoko versions
while enabling correct UTF-8 encoding for supplementary characters
(codepoints > U+FFFF) when both endpoints support the new flag.

Modified files:
- yoko-core/src/main/java/org/apache/yoko/codecs/Utf8Codec.java
- yoko-util/src/main/java/org/apache/yoko/util/yasf/Yasf.java
- Add file.getFD().sync() calls after writing IOR files to ensure data is flushed to disk
- Apply to Server classes in ORBTest, iiopplugin, local, pi, poa, retry, and tnaming test packages
- Add missing imports (FileOutputStream, PrintWriter) where needed
- Remove fully qualified class names in favor of imports
- Simplify policy array initialization using array initializer syntax
- Remove unnecessary comments and empty statements
- Consolidate multi-line statements for better readability
- Add static import for ParseArgs in TestMultipleOrbsThreadedServer
- Replace FileWriter with FileOutputStream in pi.Server and tnaming.Server for consistency
@joe-chacko joe-chacko force-pushed the feat/744-use-new-codecs branch from 8e353b4 to f6d66c5 Compare February 23, 2026 23:27
@joe-chacko joe-chacko requested a review from ngmr February 23, 2026 23:39
@ngmr ngmr merged commit f820b1c into OpenLiberty:main Feb 24, 2026
2 checks passed
@joe-chacko joe-chacko deleted the feat/744-use-new-codecs branch February 24, 2026 22:04
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.

2 participants