Islandora / documentation

Contains islandora's documentation and main issue queue.
MIT License
103 stars 71 forks source link

"isNewVersion" is in the wrong spot in event messages #1610

Open dannylamb opened 4 years ago

dannylamb commented 4 years ago

Right now, we're stuffing the isNewVersion boolean under the object heading in AS2 messages that get emitted: https://github.com/Islandora/islandora/blob/8.x-1.x/src/EventGenerator/EventGenerator.php#L114

This should be down in the attachment section under content here: https://github.com/Islandora/islandora/blob/8.x-1.x/src/EventGenerator/EventGenerator.php#L155 That section is allowed to be freeform json and doesn't have to comply with https://www.w3.org/TR/activitystreams-core/

After changing that, there'll have to be some updates to Alpaca to pull out that boolean from the new location in the message. For example, here: https://github.com/Islandora/Alpaca/blob/dev/islandora-indexing-fcrepo/src/main/java/ca/islandora/alpaca/indexing/fcrepo/FcrepoIndexer.java#L167

elizoller commented 4 years ago

so instead of attaching 'isNewVersion' to the $event["object"], attach it to the $data?

dannylamb commented 4 years ago

yep. Set the boolean as $data["isNewVersion"] and it should all work out.