Skip to content

Rename the PolarisEvent entity class to EventEntity#4731

Open
adutra wants to merge 1 commit into
apache:mainfrom
adutra:event-entity
Open

Rename the PolarisEvent entity class to EventEntity#4731
adutra wants to merge 1 commit into
apache:mainfrom
adutra:event-entity

Conversation

@adutra

@adutra adutra commented Jun 12, 2026

Copy link
Copy Markdown
Contributor

The org.apache.polaris.core.entity.PolarisEvent class has a confusing name since it clashes with org.apache.polaris.service.events.PolarisEvent and does not bear the Entity suffix that other entity classes sport. This change fixes that.

Checklist

  • 🛡️ Don't disclose security issues! (contact security@apache.org)
  • 🔗 Clearly explained why the changes are needed, or linked related issues: Fixes #
  • 🧪 Added/updated tests with good coverage, or manually tested (and explained how)
  • 💡 Added comments for complex logic
  • 🧾 Updated CHANGELOG.md (if needed)
  • 📚 Updated documentation in site/content/in-dev/unreleased (if needed)

The `org.apache.polaris.core.entity.PolarisEvent` class has a confusing name since it clashes with `org.apache.polaris.service.events.PolarisEvent` and does not bear the `Entity` suffix that other entity classes sport. This change fixes that.
Copilot AI review requested due to automatic review settings June 12, 2026 17:19
@github-project-automation github-project-automation Bot moved this to PRs In Progress in Basic Kanban Board Jun 12, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR resolves a naming collision between the service-layer org.apache.polaris.service.events.PolarisEvent and the core entity currently named org.apache.polaris.core.entity.PolarisEvent by renaming the core entity to EventEntity (aligning with other *Entity types).

Changes:

  • Rename the core persistence entity class PolarisEvent to EventEntity.
  • Update event persistence/listener plumbing to use EventEntity throughout (PolarisPersistenceEventListener, in-memory buffer listener).
  • Update JDBC model conversion and related tests to use EventEntity.

Reviewed changes

Copilot reviewed 16 out of 16 changed files in this pull request and generated no comments.

Show a summary per file
File Description
runtime/service/src/test/java/org/apache/polaris/service/events/listeners/PolarisPersistenceEventListenerTest.java Updates listener tests to assert against EventEntity instead of the old entity name.
runtime/service/src/test/java/org/apache/polaris/service/events/listeners/inmemory/InMemoryBufferEventListenerTestBase.java Updates test helper to construct EventEntity and use its ResourceType.
runtime/service/src/test/java/org/apache/polaris/service/events/listeners/inmemory/InMemoryBufferEventListenerIntegrationTest.java Updates integration assertions and result conversion types to EventEntity.
runtime/service/src/main/java/org/apache/polaris/service/events/listeners/PolarisPersistenceEventListener.java Updates the persisted event object created from service events to EventEntity.
runtime/service/src/main/java/org/apache/polaris/service/events/listeners/inmemory/InMemoryBufferEventListener.java Updates the in-memory buffering/persistence pipeline generics and method signatures to EventEntity.
polaris-core/src/main/java/org/apache/polaris/core/persistence/TransactionWorkspaceMetaStoreManager.java Updates the writeEvents API surface to accept List<EventEntity>.
polaris-core/src/main/java/org/apache/polaris/core/persistence/transactional/AbstractTransactionalPersistence.java Updates the writeEvents signature to List<EventEntity>.
polaris-core/src/main/java/org/apache/polaris/core/persistence/BasePersistence.java Updates the writeEvents SPI signature to List<EventEntity>.
polaris-core/src/main/java/org/apache/polaris/core/entity/PolarisEventManager.java Updates the default writeEvents delegation signature to List<EventEntity>.
polaris-core/src/main/java/org/apache/polaris/core/entity/EventEntity.java Renames the core entity class and constructor to EventEntity.
persistence/relational-jdbc/src/test/java/org/apache/polaris/persistence/relational/jdbc/models/ModelEventTest.java Updates JDBC model conversion tests to use EventEntity.
persistence/relational-jdbc/src/test/java/org/apache/polaris/persistence/relational/jdbc/DatasourceOperationsTest.java Updates JDBC batch write test data to use EventEntity.ResourceType.
persistence/relational-jdbc/src/main/java/org/apache/polaris/persistence/relational/jdbc/models/ModelEvent.java Updates model converter interface and conversion helpers to/from EventEntity.
persistence/relational-jdbc/src/main/java/org/apache/polaris/persistence/relational/jdbc/JdbcBasePersistenceImpl.java Updates JDBC persistence implementation to accept List<EventEntity>.
persistence/nosql/persistence/metastore/src/main/java/org/apache/polaris/persistence/nosql/metastore/NoSqlMetaStoreManager.java Updates writeEvents signature to List<EventEntity> (still unsupported for NoSQL).
persistence/nosql/persistence/metastore/src/main/java/org/apache/polaris/persistence/nosql/metastore/NonFunctionalBasePersistence.java Updates writeEvents signature to List<EventEntity>.

@github-project-automation github-project-automation Bot moved this from PRs In Progress to Ready to merge in Basic Kanban Board Jun 12, 2026
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.

4 participants