Skip to content

Port Time::Moment or provide a Java-backed implementation #1112

Description

@fglock

Summary

Port or provide a Java-backed implementation for Time::Moment so PerlOnJava can run its upstream test suite.

Evidence

  • Distribution: Time-Moment v0.46
  • Archived CPAN run: 20260824-171428-41866
  • PerlOnJava result: 36/37 subtests failed across 25/29 test programs because Time::Moment has native XS/C code and no Java XS implementation is available.
  • System Perl result: the upstream suite passed all runnable tests: 29 files and 34,995 tests. Optional tests for unavailable modules such as DateTime, CBOR::XS, Sereal, and Params::Coerce were skipped.
  • Reverse dependencies: 60 runtime dependant distributions, including 17 released within the recent dependency window.
  • Example dependants: Cron::Toolkit, DBIx::Wizard, Net::Async-Slack, Parse::Syslog-Line, and Web-Async.

Proposed scope

  1. Determine whether the existing Java time APIs can implement the Time::Moment value, parsing, arithmetic, calendar, formatting, and serialization behavior.
  2. Choose a provider strategy: a Java-backed module provider, a compatible pure-Perl implementation, or a narrowly scoped XS shim.
  3. Preserve the upstream API and document unsupported edge cases explicitly.
  4. Add focused PerlOnJava regression coverage for provider loading and representative Time::Moment operations.
  5. Run the unmodified upstream suite under both PerlOnJava backends and verify that the bundled provider cannot be shadowed by an upstream XS build.

The dependency count makes this a meaningful native-port candidate, but the implementation should be scoped by upstream API conformance rather than by the dependant count alone.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions