Skip to content

v6 - #92

Open
lmajano wants to merge 20 commits into
developmentfrom
next
Open

v6#92
lmajano wants to merge 20 commits into
developmentfrom
next

Conversation

@lmajano

@lmajano lmajano commented Oct 12, 2026 •

Copy link
Copy Markdown
Contributor

Description

Release PR for cborm 6: merges next into development. It pairs with ortus-boxlang/bx-orm#117 (bx-orm 2, Hibernate 7.4).

cborm 6 is a pure BoxLang module built on bx-orm 2:

  • BoxLang classes only (.bx).
  • newCriteria() returns bx-orm's entityCriteria() builder.
  • Transactions ride BoxLang transaction{}.
  • Native Java streams replace cbstreams, and the resource handler builds its own pagination instead of using cbpaginator.
  • New service methods, typed orm.* errors, and a list of bug fixes.

The full list is in changelog.md under Unreleased, and the migration steps are in UPGRADING.md.

Kept as a draft so it ships together with bx-orm 2.0.0.

Issues

None filed for the release itself.

Type of change

  • Bug Fix
  • Improvement
  • New Feature
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

Checklist

  • My code follows the style guidelines of this project cfformat
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation (README, UPGRADING.md, changelog, cbox-cborm-docs)
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes

🤖 Generated with Claude Code

https://claude.ai/code/session_01SnmFsqBfa9SR4V1rRXw57X

- All module sources are BoxLang classes (.bx), ModuleConfig.bx included.
- BaseORMService, VirtualEntityService and ActiveEntity keep their API and
  delegate to the bx-orm BIFs. newCriteria() returns entityCriteria().
- One EventHandler (BXEventHandler kept as a deprecated alias), with the
  new ORMPostCommit point; ORMPostNew fires once from new().
- CriteriaEventBridge relays bx-orm's criteria events to ColdBox.
- HibernateTransaction aspect rides BoxLang transaction{}.
- DynamicProcessor: HQL cached per entity/method, list params bound as
  lists on every call, bx-orm nonUnique mapped to NonUniqueResultException.
- Removed the Hibernate 5 criteria API (criterion/*), SQLHelper,
  ORMUtil/JavaProxyBuilder and the Adobe engine support.
- CI: BoxLang engines only; temporary step builds bx-orm 2 from its
  migration branch until it is published.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SnmFsqBfa9SR4V1rRXw57X
- Harness runs on BoxLang only with cborm.models.EventHandler; specs for
  the removed criteria API, SQLHelper and ORM utilities are deleted.
- Specs use JPA ?1 parameters and cover newCriteria() on bx-orm
  (restrictions, SQL log, projections), the criteria event bridge,
  ORMPostNew fired once and the new ORMPostCommit point.
- UPGRADING.md lists what stays, what changed and what was removed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SnmFsqBfa9SR4V1rRXw57X
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SnmFsqBfa9SR4V1rRXw57X
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SnmFsqBfa9SR4V1rRXw57X
Hibernate 7 instantiates entities while the ORM starts (to infer unsaved
id values), before ColdBox puts WireBox in the application scope. An
ActiveEntity's init() read application.wirebox and failed the ORM boot.
getWireBox() and getLogger() now resolve them on first use.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SnmFsqBfa9SR4V1rRXw57X
Mementifier (and apps) call getEntityMetadata().getPropertyTypes(),
getPropertyNames(), hasIdentifierProperty(), ... - the Hibernate 5
ClassMetadata API, which the Hibernate 7 entity persister still has.
getKey(), getPropertyNames() and getTableName() read entityGetMetadata().
The VES count spec uses the declared property case (HQL is case-sensitive
in Hibernate 6+).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SnmFsqBfa9SR4V1rRXw57X
Dynamic finders map each sortBy property to its declared case, since HQL
property names are case-sensitive. The ActiveEntity count spec uses the
declared property case.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SnmFsqBfa9SR4V1rRXw57X
bx-orm 2 now resolves HQL entity and property names in any case and
rewrites plain ? positional parameters, so neither is a cborm 6 breaking
change. UPGRADING and the changelog are corrected, and specs use a
lowercase property and plain ? parameters to prove both.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SnmFsqBfa9SR4V1rRXw57X
… service fixes

- asStream returns a Java Stream read from the database (bx-orm asStream);
  cbstreams and cbpaginator are no longer dependencies
- exists/countWhere/deleteWhere/deleteByID/deleteAll/getAll run on bx-orm
  criteria: validated properties, composite ids, bulk deletes flush first,
  no HQL injection through sortOrder or dynamic finder sortBy
- save/delete/saveAll flush every datasource they touch
- New: findWhereOrFail, firstOrNew, firstOrCreate, updateWhere,
  getReference, lock, readOnly, options pass-through; ActiveEntity lock,
  toStruct and entity=this defaults
- ORMPreFlush from bx-orm onFlush/onAutoFlush; entityNew() autowires
- DynamicProcessor: no property-name cache or lock, id properties in the
  grammar, typed orm.* errors, self-healing compile cache, clearCache()
- Fixes: VES deleteAll/evictCollection/signatures, injection include
  matching, DML detection, findWhere consistency, validationResult,
  isValid includeFields, re-entrant new()
- Resource handler builds its own pagination block and falls back to
  entityToStruct() without mementifier
- Transactions rely on BoxLang transaction{} rollback (no request flag)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SnmFsqBfa9SR4V1rRXw57X
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SnmFsqBfa9SR4V1rRXw57X
… no annotations key

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SnmFsqBfa9SR4V1rRXw57X
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SnmFsqBfa9SR4V1rRXw57X
Actions > Pre-Release (next) > Run workflow builds 6.0.0-<label>.<n> (label
alpha, beta or rc; n is the next free number from the existing tags), runs
the tests, uploads to downloads.ortussolutions.com and ForgeBox, tags the
commit and creates a GitHub pre-release. Build.cfc now makes only
development builds snapshots, so a pre-release keeps its version.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SnmFsqBfa9SR4V1rRXw57X
…e-release process

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SnmFsqBfa9SR4V1rRXw57X
@lmajano
lmajano marked this pull request as ready for review October 14, 2026 11:02
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