v3.0.0-rc2
Pre-releaseHyrax 3.0.0 is a substantial release featuring a wide variety of UI improvements, metadata updates, and bugfixes as well as significant internal improvements.
The highlights for this release include:
- Support for Rails 5.2, Ruby 2.6, Ruby 2.7 are added; we now recommend Rails 5.2 for all applications.
- We dropped testing for Ruby 2.4; we now recommend at least Ruby 2.5 for all applications.
- Out-of-the-box metadata schemas are updated to more closely align with the recommendations of the Samvera Metadata Interest Group.
- File versions and transparent PNGs are now supported by our IIIF installation. Universal Viewer's install process is improved to use
yarn
. - Valkyrie is introduced as a production dependency and a custom adapter (
Wings
) is introduced to handle backward-compatible use of Valkyrie within Hyrax. (see more on this below)
Wings/Valkyrie
This release marks a major milestone in the transition from ActiveFedora
to Valkyrie
as Hyrax's persistence middleware. The introduction of Wings has allowed us to transition some portions of the Hyrax codebase to using Valkyrie natively. Likewise it allows adopters to begin the transition to Valkyrie within their own applications in a limited fashion.
At this point, we encourage early-adopters to explore using Wings
through native Valkyrie interfaces and provide feedback about its suitability in Hyrax-based applications. Existing ActiveFedora models can be cast to auto-generated Valkyrie resource classes by using resource = my_object.valkyrie_resource
.
A broader usage guide for Wings and Valkyrie is provided at https://github.com/samvera/hyrax/wiki/Hyrax-Valkyrie-Usage-Guide
Currently, the internal Wings
adapter is the only supported Valkyrie adapter. We expect to support other adapters, and eventually deprecate Wings
in future releases.
CircleCI
In support of development efforts, we migrated our CI builds from Travis to CircleCI. This has allowed us to substantially reduce build times, increasing developer productivity. It has also allowed us to expand Hyrax's build matrix: we now run builds for Ruby 2.5, 2.6 and 2.7 in parallel, helping us ensure comprehensive support for those Ruby versions.
We have moved away from testing CircleCI with sqlite and are now using Postgresql (see @d0b0c2034). We assume that local development will also use Postgresql.
We have worked to improve the stability of our test suite and focused on speed of tests. We're now seeing our test suite regularly complete in less than 15 minutes.
Migration Procedures from Hyrax 2.x to 3.0
The following steps describe the process for migrating to Hyrax 3. The steps should be run in the order presented.
Update gem
Edit Gemfile or gemspec to update the version of hyrax.
gem 'hyrax', '3.0.0.pre.rc2`
and run
bundle update hyrax
Database: Application DB changes are all covered by db:migrate
Run migrations to get database changes...
rails hyrax:install:migrations
rails db:migrate
There is a new migration that will convert a database column from string to integer (see @e9e9f65e1a81f78856afeafdb5bba3b726d070aa). The column type should have always been an integer.
IIIF & Universal Viewer
The Universal Viewer install is now managed by yarn
. Ensure UV is installed correctly by running the provided install rake task:
rake hyrax:universal_viewer:install
The number of arguments needed by the iiif_image_url_builder
lambda changed.
Applications that use the riiif gem for IIIF will need to add format
to the iiif_image_url_builder lambda in config/initializers/hyrax.rb.
config.iiif_image_url_builder = lambda do |file_id, base_url, size, format|
Changes
Incompatible API changes
- Dropped support for Ruby 2.3 (#3566)
- Dropped support for Ruby 2.4 (#4371)
- Show for license has moved from
app/views/hyrax/base/_metadata.html.erb
toapp/views/hyrax/base/_attribute_rows.html.erb
(#3153).- If you have local view overrides for
_attribute_rows.html.erb
but not_metadata.html.erb
, this will orphan the license field in the show view. Fix this by adding<%= presenter.attribute_to_html(:license, render_as: :license, html_dl: true) %>
to your custom_attribute_rows.html.erb
.
- If you have local view overrides for
- Renames two database columns to names to avoid camelCase:
itemId
->item_id
,downloadKey
->download_key
(#3121) - Removes
Solrizer::Common
from theHyrax::WorkBehavior
ancestor tree (#3399) - Deprecated
member_of_collection_ids
interface removed fromCollectionsMembershipActor
; usemember_of_collections_attributes
instead (#3428) - Removes code deprecated during the Hyrax 2.x series (#3401)
- Use
Hydra.config.user_key_field
to determineUser#user_key
(#3480) - Change Solr search builders to use
[* TO *]
for date range searches (#3559) - Solr configuration is now loaded from
./solr/conf
by default, matching the Blacklight approach (#3915) - Drop support for
browse everything
versions older than 0.16, add support for 1.0+ (#3879, #3645) - Drop support for
hydra-head
releases older than 10.6.1(#3495) - Remove deprecated
PresenterFactory.build_presenters
(#4038) - Remove deprecated
CollectionOptionsPresenter
(#4037) - Remove deprecated
WorkForm#collections_for_select
(#4036) - Remove deprecated
human_readable_type
setter (#4035) - The universal viewer install process has changed to use
yarn
/rake assets:precompile
(#3765, #3761, #3696) config.iiif_image_url_builder
's method signature has changed (#3760)- You'll want to review if you've over-written
Hyrax::UsersController#base_query
; We recommend that you useActiveRecord::Base.where
parameter syntax (#4407, #4400)
User Interface
- Improve Generic Work layout and button organization (#3374)
- Use versioned images in IIIF and universal viewer (#3764)
- Support rendering PNGs with alpha channels with IIIF and universal viewer (#3760)
- Improve thumbnail cache behavior (#3764)
- Makes Admin Sets Participants tab consistent with Collections Sharing tab (#3384)
- Fixes punctuation error in help text (#3368)
- Generic Login Form employs Bootstrap conventions (#3362)
- Make thumbnails the same size as thumbnails in Works list view (#3446)
- Ensure dashboard collection list item thumbnails don't overlap with title (#3446)
- Change
description
label from "Abstract or Summary" to "Description" (#3449) - Ensure collection thumbnails show properly in search results (#3291)
- Remove
Hyrax::Actors::TransactionalRequest
from default middleware (#3482) - Backport of #3164 - Collection Thumbnails don't show in search results (#3658)
- Add new option for how to contribute (#3751)
- Relabel the links for private child works from 'File' (#3740)
- When downloading from Box, use label for filename (#3718)
- When tabbing in relationship tab, allow user to reach "Add" buttons. (#3709)
- Avoid silent removal of unsaved form changes when changing tabs in 'Edit Collection' by prompting the user (#3942)
- Improve padding for the navbar on mobile devices (#3944)
- Improve breadcrumbs on work pages (#3914)
- Improve display of collection item lists to avoid overlapping elements (#3913)
- Remove Google+ from sharing buttons (#3894)
- Make Add files and Add folder buttons to work with tab key navigation (#3488)
- Fix display of feature/unfeature buttons (#3776)
- Center headings in work listed in dashboard. (#3759)
- Allow injection of new sections in form progress panel (#4453)
- Stop triggering autocomplete for non-auto complete fields (#4451)
- Create a better label for proxy deposits (#4378)
- Links from Profile page show users collections and works (#4322)
- Add a default health check endpoint at
/healthz
(#4291, #4292) - Remove collection size feature due to negative performance (#4207)
- Add a
ChildTypes
to manage selection display during work attachment (#4181) - Decode filenames for fileset label (#4172)
- Display analytics without having to refresh browser (#4170)
- Broken logo image should not display broken link icon (#4168)
Documentation
- Update work generator usage documentation (#4187)
- Add examples to
Hyrax::AccessControlList
documentation (#4174) - Add documentation on using Postgresql locally as part of test app development build (#4397)
Enhancements
- Format informative errors for workflow schema validation (#4028, #267)
- Provide patterns and infrastructure for assiging remote identifiers (DOI, Handle, etc.) (#4458)
- Delegate IIIF Manifest cache key version to presenter (#4418)
- Open the
ContactFormController
to model subclasses (#4374) - Add a 'object.failed_deposit' event (#4352)
- Allow apps to forgo a custom ModelActor (#4339)
- Support optimistic locking for
ResourceForm
(#4337) - Allow most recent version of file to be downloaded (#4336)
- Extend
MembershipHelper
andResourceForm
formember_ids
(#4321) - Adding Caching to IIIF Manifest Generation (#4275)
- Adds
Hyrax.publisher.subscribe(Hyrax::Listeners::MetadataIndexListener.new)
toconfig/initializers/listeners.rb
(#4218) - Adds publishing an
object.metadata.updated
event to theafter_create_concern
callback. (#4218) - Use a Hyrax configuration option to set the system virus scanner (#4211)
- Make the valkyrie index adapter configurable (#4148)
- Use the
Hyrax::TimeService
for events (#4130) - Turn off Batch Upload features by default (#4129)
Metadata
- Add
rights_notes
metadata toBasicMetadata
(#3550) - Add access rights metadata to a work. (#3749)
- Remove keyword from required fields (#3747)
- Add abstract metadata to work (#3680)
- Change predicate used by keyword (#3748)
- Map
license
todcterms:license
(#3293) - Limit
#title
to single use, introducedc:alternative
for additional titles (#3554) - Add description, citation_keywords, and citation_publisher meta tags for Google Scholar (#4382)
- Pin EBUCore to avoid changed predicates used by Hyrax (#4365)
- Lookup schema from main app and fallback to Hyrax engine (#4346)
- Read form definitions from metadata configuration files (#4311)
- Better tests and documentation for
Hyrax::SimpleSchemaLoader
(#4293) - Implement member->collection directional Collection membership (#4257)
- Support custom URI use/type in
FileSetDescription
(#4235) - Create
FileSetDescription
to find characterization for FileSets (#4215) - Generate metadata yaml with fields passed as arguments to generator (#4347)
- Auto-generate tests for attributes in work resource generator (#4348)
- Add indexer to work_resource generator (#4219)
- Add a
hyrax:work_resource
generator for valkyrie native works (#4188) - Index Visibility when using the valkyrie indexer (#4176)
- Write Metadata and ACL changes to valkyrie index with listeners (#4175)
- Use uploaded_file for new versions (#4165)
- Add aria-label and title tag for SVG icons (#4164)
- Update DC Terms License predicate URI (#4065)
- Data-driven Metadata (#4026)
- Allow for extensions of valkyrie indexer's to_solr that depends on resource custom metadata (#4463)
Note: We are working towards more dynamic metadata and less assumptions about the descriptive metadata of an object. Pull request #4347 talks a bit more about this.
Solr field names
- Replace use of
set_fields
with direct references to literal solr field names (#3831).- If you've been customizing index keys by overriding methods in
ActiveFedora::Indexing::Fieldmapper
or other Solrizer-related functionality, we recommend using a custom indexer or overriding a hyrax indexer instead.
- If you've been customizing index keys by overriding methods in
Bug Fixes
- Split out functionality behind ModelTransformer (#3948, #3639)
- Enlarge area where collection title is displayed on modal. (#3957, #3954)
- Change labels on dashboard for visibility to indicate work or collection (#3955, #3459)
- Remove raw html from batch edit pages. (#3971, #3959)
- Collection Edit Page Thumbnail Fix (#3968, #3930)
- Correct transfer page labels (#3960, #3956)
- Allow embago and leased works to be updated (#4021, #3958)
- Fix depositor summary page flicker when switching tabs (#4058, #3402)
- Fix release date issue in Safari (#4067, #4005)
- Deactivate Embargoes for Selected Fails (#3993, #4068)
- Deactivate Leases for Selected Fails (#4002, #4073)
- Prevents creation of multiple
FileSet
s whenAttachFilesToWorkJob
is retried after an uncaught error (#3407) - Sanitize IIIF manifest output (#3395)
- Fix template url and update rails version (#3755)
- Add mime_type to the Riiif info_service (#3752)
- Increase Google Analytics download limit to 10,000, supporting usage stats from more than 1000 days ago (#3926)
- Fix generator for analytics configuration to use
ENV
variables correctly (#3934) - Remove unauthorized.png from generator (#4044)
- Prevent users from making themselves a proxy depositor (#3909)
- Verifiy the validity of the URL supplied by users for the collection logo (#3789)
- Use the original file's width and height instead of assuming 640x480 (#3772)
- Rescue correct error in
WorkflowRolePresenter
(#4427) - Have sidebar menu behave consistently when switching options (#4404, #1495)
- Restoring check for permissions on JSON document (#4401)
- Adding
.inspect
to anonymousWorkSearchBuilder
(#4395) - Correct accessibility audit from embargo page (#4003, #4386)
- Ensure deleted proxy is deleted even if page is refreshed. (#3542, #4363)
- Display thumbnail in public collection page (#3358, #4360)
- Allow language switching in
FileManager
(#4171, #4327) - Fix changed tab confirmation (#3911, #4320)
- Set checkbox for file within file (#4161, #4319)
- Addressing case where children are added again (#4302)
- Fixing logic around deleting nested membership (#4193, #4278)
- Aligning upload of new versions with uploading of files (#104, #4272)
- Ensuring CSV usage has same namespace consideration (#4238)
- Handle conversion of custom use types for files (#4203, #4225)
- Correct typos (#4214, #4212)
- Fix accessibility issues in works page (#4160, #3966)
- Fix landmark issue in Homepage (#4156, #3961)
- Fix dashboard accessibility issues (#4152, #3964)
- Improve accessibility of collections public view (#4150, #3962)
- Improve accessibility on Contact page (#4147, #3963)
- Make
Skip to content
link focus on main content (#4146, #3774) - Fix bug in date validation in admin_set form (#4145, #4144)
- Improve accessibility on collection show page (#4142, #3962)
- Fix to improve accessibility in home page (#4139, #3961)
- Fix Display bugs on Work form > Sharing tab (#4138, #3972)
- Return empty string if APAFormatter authors_list is empty (#4135)
- Adds missing
payload_concern
parameter to currently-broken link from the single Work creation form (#4080, #3195) - Index digest as a collection, instead of a single value (#4032, #1079)
- Index admin_sets using the configured predicate (#4030, #2405)
Internationalization
- Improve coverage of i18n keys (#3535, #3564, #3898)
- New form hint translation (#3396)
- Email text are moved to locales (#3383)
- Extract and translate strings. (#3708)
- Use explicit utf-8 character for German Guillemets' (#3786)
i18n
-ize "items" on Collection show page (#4438)- Use helpers to i18nize configured permission levels/options (#4298)
- Make permission level configuration defaults use I18n locale. (#4287)
- Support
i18n
for Valkyrie#human_readable_type
(#4088) - v3.0.0-rc1 polish (as in shine, not Poland) google-translate (#4050)
- Rename
Hyrax.collection.browse_view
toedit_view
& update value (#4041)
Refactors
- Remove unneeded module include from
BatchUploadForm
(#4027) - Use a custom Indexer for AdminSets (#4048)
- Homepage layout includes more room for customization and nav pills have been changed to tabs (#3375)
- Extract
VisibilityIntention
class fromInterpretVisibilityActor
(#3462) - Remove unneeded
#save
of embargoes and leases during InterpretVisibilityActor (#3462) - Make
CreateWithRemoteFilesOrderedMembersActor
thread safe (#3477) - Reverted with "Move instance variable out of actor and into environment" (#3703)
- Add
DestroyWork
transaction to experimentalDry::Transactions
actor stack alternative (#3473) - Remove conditional from user partial (#3380)
- Remove internal references to
ActiveFedora::Base.logger
, useHyrax.logger
instead (#3901) - Replace
Hydra::Works::VirusCheck
andHydra::Works::VirusScanner
withHyrax::VirusCheck
andHyrax::VirusScanner
(#3901) - Raise
Hyrax::ObjectNotFoundError
in place ofActiveFedora::ObjectNotFoundError
. Applications should move to catching the former. (#3840) - Don't short-circut actor Environment when interpreting visibility (#3892)
- Support custom dashboard sidebar partials rendered using sidebar_partials class attribute (#3878)
- Refactor
WorkForm#agreement_accepted
toagreement_accepted?
(#3890) - Use
Arel.sql
to wrap a known safe SQL string in PermissionsService (#3888) - Add original_file.id to FileSetIndexer (#3864)
- Remove direct dependency on
ActiveFedora.id_field
(#3809) - Refactor for configurable
ActiveFedora.index_field_mapper
(#3802) - Extract Visibility application to a
Hyrax::VisibilityIntentionApplicator
service for reusability (#3468) - Adds support for
ActiveModel
-safe decoration (#4461) - Move ordered member id querying to a decorator for SolrDocument (#4455)
- Simplify collection metadata rendering (#4439)
- Support Valkyrie query for
CollectionType#collections
(#4435) - Add optimized
#fid_collections_by_type
query for Wings (#4432) - Add a
#find_collections_by_type
query (#4430) - Document and refactor
QuickClassificationQuery
(#4426) - Begin to generalize FixityService API (#4425)
- Test & document
DisplaysImage
fallback behavior (#4424) - Adjusting
UsersController#search
for db-agnosticism (#4407) - Support transactional update via
WorksControllerBehavior
(#4394) - Reworking method call to improve clarity (#4390)
- Refactoring module to reduce redundant calls (#4385)
- Extract hard view dependency on
Hyrax::ContactForm
to a helper (#4375) - Support Valkyrie work creation with Hyrax transactions (#4359)
- Renaming method from whitelisted to registered (#4357)
- Manifest presenter rewrite (#4356)
- Cast
ResourceForm#member_ids
and#member_of_collection_ids
to Array (#4350) - Slight optimization to IIIF Manifest generation (#4344)
- Add some inspect methods for generated classes and modules (#4341)
- Add
DefaultWork.inspect
method for console output on models (#4340) - Count collection items with
SolrService
directly (#4314) - Move
#member_of_collections_json
to a helper (#4312) - Use a
collection_member_sort_fields
helper to manage sort options (#4311) - Expand the
EmbargoManager
interface to handle releasing embargos (#4305) - Use a helper for lease/embargo expiration (#4304)
- Use a decorator for page titles (#4297)
- Start to bridge the gap between HydraEditor forms and ChangeSets (#4295)
- Provide default
REDIS_HOST
in production (#4290) - Copy dist directory instead of uv directory (#4289)
- Set depositor for
WorkCreate
transaction (#4261) - Add resource to collection with create transaction (#4260)
- Reworking OrcidValidator (#4251)
- Improving HTML rendering error tolerance (#4240)
- Use the
FileMetadata#type
notFileSet#original_file_id
(#4236) - Removes configurability for resource indexer in solr indexing adapter (#4222)
- Remove empty
indexer.rb
concern (#4186) - Remove call to dead ActiveFedora code (#4178)
- Replace custom Hyrax callbacks with
dry-events
(#4132) - Rewrite Arel.sql calls to other arel methods (#4126)
- Implement Resource state in a model agnostic way (#4107)
- Refactor
PermissionTemplate#source_model
; deprecate unused methods (#4089) - Make
Hyrax::FileSet
a class (#4086) - Don't filter
member_of_collection_ids
by PCDM type (#4077) - Qualify references to the application's
Collection
class (#4071) - Remove the no-op analytics flipper (#4034)
- If admin, show all groups in sharing tab, ALSO removed html tags from page (#3945, #3534)
Wings/Valkyrie
Many of these changes are internal to Hyrax; Though the changes may introduce deprecations (and guidance to correct). We include these to give a sense of the underlying work to switch data adaptors in a forward focused manner.
- Round trip Valkyrie-native models, even when unregistered (#4317)
- Generate metadata dynamically for fallback AF classes (#4335)
- Test datetime behavior (#4327)
- Support optimistic locking for Valkyrie resources (#4325)
- Better model resolution for wings (#4358)
- Valkyrize attach file to work job (#4273)
- Valkyrize Event Jobs (#4270)
- Use Valkyrie::ID<=>String equality (#4264)
- Support proxy deposit for Valkyrie Work models (#4263)
- Valkyrize inherit_permissions_job (#4227)
- Add Vegan friendly
Wings
alias (#4224) - Implement Valkyrie indexing for Collections (#4223)
- Use the configured storage adapter (#4217)
- Route Valkyrie models registered with Wings to legacy models (#4210)
- Wings/add extracted text (#4206)
- Isolate select ActiveFedora::Base calls (#4205)
- Add a
hyrax:work_resource
generator for valkyrie native works (#4188) - Support
#find_all_by_model
query in Wings (#4183) - Move wings setup to its own file (#4163)
- Automatically convert valkyrie resource to ActiveJobProxy when enqueuing (#4124)
- Valkyrizes job that revokes
:edit permissions
; Valkyrizegrant_read_job
,grant_read_to_members_job
,grant_edit_job
(#4123) - Constantize and catch generated constant names in Registry (#4122)
- Don't filter queries based on class (#4113)
- Add a Valkyrie-based Admin Set model (
AdministrativeSet
) (#4090) - Add base FileSet resource; add find_files custom query (#4084)
- Implement Valkyrie native Collections as
PcdmCollection
(#4076) - Implement a Valkyrie-native
Hyrax::Work
model (#4070) - Avoid special handling for values in
ConverterValueMapper
(#4069) - Implement
#name
for classes generated byOrmConverter
(#4059) - Convert file ids in resource fileset to pcdm files in AF fileset (#4055)
- Provide a Valkyrie changeset factory (#4047)
- Use valkyrie for
BaseActor#create
(#4040) - Save
file_set
using valkyrie and passuse_valkyrie
tofile_actor
(#4039) - Add
find_file_metadata
custom queries (#4023) - Refactor wings overrides of custom queries (#4020)
- Prefer pattern of setting use_valkyrie in the initializer (#4019)
- Define a schema sharing pattern for Hyrax/Valkyrie (#4017)
- Add
file_converter_service
which converts the metadata between AF:File and FileMetadata resource (#4014) - Round trip registered valkyrie native classes (#4012)
- Document and normalize
Hyrax
valkyrie adapter references (#3997) - Remove
#method_missing
(#3952) - Wings wrapper for Hydra:Works:AddFileToFileSet (#3939)
- Add Valkyrie-native permission handling (#3938)
- Replace calls to
ActiveFedora::Base.search_by_id
(#3935) - Remove
convert_class_name_to_valkyrie_resource_class
(#3931) - Fixing the issue in #show when remove
use_valkyrie: false
. (#3906)
Deprecations
- Deprecate
ActiveFedora::SolrService
in favor ofHyrax::SolrService
(#3943) - Deprecate
CollectionType#collections?
in favor ofCollectionType#collections.any?
(#4434) - Deprecate
PowerConverter
in favor ofSipity::<CLASS>()
, which is analogous toArray()
(#4097) - Deprecate
Hyrax::Configuration#whitelisted_ingest_dirs
in favor ofHyrax::Configuration#registered_ingest_dirs
(#4357) - Deprecate
Hyrax.config.callback
(#4157) - Deprecate feature to configure indexing for a property (#4022, #3863)
Dependencies
- Added support for Ruby 2.6 and 2.7; dropped 2.3 and 2.4 (#3565, #3566)
- Add
valkyrie
as a production dependency (#3563) - Bump
valkyrie
requirement to 2.1 (#4180) - Upgrade
riiif
gem to 2.0 (#3390) - Upgrade to
ActiveFedora
12.0 (#3425) - Upgrade
hydra-head
to releases 10.6.1 or later (#3495) - Move internal dependencies into the main Engine body (#3686)
- Drop support for
browse everything
versions older than 0.16, add support for ~> 1.0 (#3879, #3645, #4143) - Add an explicit
draper
dependency (#4413) - Pin reform v2.2.x and under (#4333)
- Allow iiif_manifest 1.x (#4334)
- Updated from deprecated Riiif class name (#4259)
- Removing sepc files from gem distribution (#4245)
- Removing Rails 6.0 deprecation warnings (#4231)
- Upgrade hydra-head to 11.0 (#4230)
- Avoid deprecated
MultiFormatter::[]
method (#4116) - Remove code marked as removable on AF 12.0.0 (#4095)
- Deprecate
Hyrax::WithFileSets
in favor ofVisibilityPropagator
(#4093) - Deprecate unused
#to_sipity_entity
(#4092) - Deprecate
Work#active_workflow
(#4091)