Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename RailsEventStoreActiveRecord into RubyEventStore::ActiveRecord #1439

Open
swistak35 opened this issue Nov 4, 2022 · 3 comments
Open
Assignees
Milestone

Comments

@swistak35
Copy link
Contributor

Creating an issue for something to track before 3.0. I'm not sure it makes sense to start working on the code before we decide we want to finally go into 3.x :)

@swistak35 swistak35 added this to the v3.0.0 milestone Nov 4, 2022
@mostlyobvious
Copy link
Member

#1147

@lukaszreszke lukaszreszke self-assigned this Nov 28, 2022
@mostlyobvious
Copy link
Member

Correct me if I'm wrong. As of now:

  • rails_event_store-2.6.0 depends on rails_event_store-2.6.0
  • rails_event_store-master depends on ruby_event_store-active_record-master

We did it because we control this dependency and replaced internally all invocations of RailsEventStoreActiveRecord with RubyEventStore::ActiveRecord.

We're also providing rails_event_store_active_record gem that:

  • has dependency to ruby_event_store-active_record
  • aliases RubyEventStore::ActiveRecord as RailsEventStoreActiveRecord
  • warns about rename in post-install message and when requiring rails_event_store_active_record

The only reason this aliased gem exists is for someone directly depending on it (which we don't control).

There's also the case of documentation pointing to RailsEventStoreActiveRecord, which we don't want to change in 2.x. Also someone might have customized RailsEventStoreActiveRecord so this const being stil present is fair expectation.

Should we then keep rails_event_store to depend on rails_event_store_active_record, being a wrapper on ruby_event_store-active_record? Do we hide deprecation warnings? Do we need to mention this deprecation in the docs?

@swistak35 @lukaszreszke

@swistak35
Copy link
Contributor Author

Well, if we want to provide backwards compatibility, as far as I understand:

  1. we should still have a dependency on rails_event_store_active_record
  2. we should remove deprecation warnings
  3. with 3.0 release, we change the dependency to ruby_event_store-active_record. It would be nice (but not mandatory) to also release 3.0 for both ruby_event_store-active_record and rails_event_store_active_record (and 3.0 being the last version of this one). Then people not using rails_event_store could make gradual change (since they have to explicitly specify rails_event_store_active_record if they use it)

I don't see other reason since we can't say "either that gem or this gem" in gemspec, or "if we have ruby_event_store-active_record, then we rails_event_store_active_record is no longer dependency".

I don't see value in deprecation warnings in 2.x, even if it would be last version of 2.x. Unless people can actually solve the deprecation (by using newer version), but they can't (they can only do that when being on 3.0, without rails_event_store).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
3 participants