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

feat: Add watermark support (DEV-2993) (DEV-2991) #3003

Merged
merged 28 commits into from
Jan 25, 2024

Conversation

seakayone
Copy link
Collaborator

@seakayone seakayone commented Jan 23, 2024

Pull Request Checklist

Task Description/Number

  • Adds a watermark.tif to knora-sipi container which is used for watermarking.
  • Changes knora-admin:projectRestrictedViewWatermark property to a boolean.
  • Extends the POST admin/projects/[shortcode|iri]/RestrictedViewSettings endpoints with an optional watermark boolean value.
  • Extends the GET admin/files/[shortcode]/filename and GET admin/projects/[shortcode|iri]/RestrictedViewSettings endpoints to return the watermark boolean.
  • Adds lua code to handle the watermark and lets Sipi return watermarked images.
  • Adds documentation.
  • Fixes the urls to the servers in the swagger-ui.
  • Removes zio-mock dependency and related tests.

Depends on dasch-swiss/sipi#405 being released in a new Sipi version.

Updating the knora base version is done in a followup PR #3005

PR Type

  • build/chore: maintenance tasks (no production code change)
  • docs: documentation changes (no production code change)
  • feat: represents new features
  • fix: represents bug fixes
  • perf: performance improvements
  • refactor: represents production code refactoring
  • test: adding or refactoring tests (no production code change)

Basic requirements for bug fixes and features

  • Tests for the changes have been added
  • Docs have been added / updated

Does this PR introduce a breaking change?

  • Yes

Does this PR change client-test-data?

  • Yes

@seakayone seakayone changed the title Feat/add default watermark to sipi feat: Add default watermark.tif to Sipi container Jan 23, 2024
@seakayone seakayone changed the title feat: Add default watermark.tif to Sipi container feat: Add default watermark.tif to knora-sipi container Jan 23, 2024
Copy link

codecov bot commented Jan 23, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (eac5751) 11.74% compared to head (81eadb6) 88.52%.
Report is 27 commits behind head on main.

Additional details and impacted files
@@             Coverage Diff             @@
##             main    #3003       +/-   ##
===========================================
+ Coverage   11.74%   88.52%   +76.77%     
===========================================
  Files         246      259       +13     
  Lines       22907    23097      +190     
===========================================
+ Hits         2690    20446    +17756     
+ Misses      20217     2651    -17566     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@seakayone seakayone changed the title feat: Add default watermark.tif to knora-sipi container feat: Add default watermark.tif to knora-sipi container (DEV-2993) Jan 23, 2024
Copy link

linear bot commented Jan 23, 2024

Copy link
Collaborator

@mpro7 mpro7 left a comment

Choose a reason for hiding this comment

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

Tests are failing and have 2 questions:

@seakayone seakayone changed the title feat: Add default watermark.tif to knora-sipi container (DEV-2993) feat: Add watermark support (DEV-2993) (DEV-2991) Jan 24, 2024
Copy link

linear bot commented Jan 24, 2024

@seakayone seakayone requested a review from mpro7 January 24, 2024 17:26
@seakayone seakayone marked this pull request as ready for review January 24, 2024 18:31
Copy link
Collaborator

@mpro7 mpro7 left a comment

Choose a reason for hiding this comment

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

I think the documentation needs to be updated and final question - what about the knora-ontology change? Should then the version be bumped and plugin created? If so, maybe we shouldn't include this PR to tomorrows release?

@seakayone
Copy link
Collaborator Author

I think the documentation needs to be updated

It is part of this PR … c28e711

@seakayone
Copy link
Collaborator Author

seakayone commented Jan 25, 2024

what about the knora-ontology change?

Either I will create a followup which lets us update the single statement in the db or it will have to be a manual step.

Since we are unsure about if the UpgradePlugins are working I will need more time to find a automated solution.

IMHO, if we update the knora-admin ontology in the db manually it should not keep us from bringing this feature online.

@seakayone seakayone mentioned this pull request Jan 25, 2024
11 tasks
project/Dependencies.scala Outdated Show resolved Hide resolved
Copy link
Collaborator

@subotic subotic left a comment

Choose a reason for hiding this comment

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

LGTM 👍

@seakayone seakayone merged commit 7637cb3 into main Jan 25, 2024
13 checks passed
@seakayone seakayone deleted the feat/add-default-watermark-to-sipi branch January 25, 2024 13:51
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.

None yet

3 participants