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

Add SLD styles to image mosaics #160

Merged
merged 4 commits into from
Nov 8, 2021

Conversation

JakobMiksch
Copy link
Contributor

@JakobMiksch JakobMiksch commented Oct 13, 2021

references #145

  • adds styles for the raster layers of the GeoServer from inside geoserver_init
  • assigns styles to the newly created image mosaics and also to image mosaics that do not have a style yet
  • the respective style (no, no2, pm10) is chosen depending on the layer name
  • it also applies styles to existing layers if they do not have a style yet

@JakobMiksch JakobMiksch changed the title Init sld raster Add SLD styles to image mosaics Oct 14, 2021
@JakobMiksch JakobMiksch marked this pull request as ready for review October 14, 2021 07:04
@JakobMiksch
Copy link
Contributor Author

JakobMiksch commented Oct 14, 2021

@jdk24 I tested the PR in my mocked environment. However it would be useful to test it in a more real environment before merging.

Copy link
Collaborator

@jdk24 jdk24 left a comment

Choose a reason for hiding this comment

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

Thank you! Works as expected when tested on incoming raster with existing style until #145.

For our setup this is great. Can there be cases where searching for "_no_" in the layer name is too generic? Otherwise it's a yes from me.

@JakobMiksch
Copy link
Contributor Author

JakobMiksch commented Oct 14, 2021

@jdk24 Thanks for testing!!

the filtering for pollutants happens here: https://github.com/meggsimum/sauber-sdi-docker/pull/160/files#diff-ca92621faca806ac3b80fe78d54e869f91ea735480602d00a3e730e33cddc7ebR250-R256

it always searches for _no_ and not no. (Note the underscores _)

Therefore it should not confuse no2 and no. Does this make sense to you?

@jdk24
Copy link
Collaborator

jdk24 commented Oct 14, 2021

It would've helped if I had escaped the underscores :)
My idea was to broaden the matching to _no_am1h_, etc. in case anyone names a layer ..._no_changes_... or the like.

Then again, this would make it just as project-specific, so I'm going to leave it with the approval.

Copy link
Collaborator

@chrismayer chrismayer left a comment

Choose a reason for hiding this comment

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

Code looks good to me.

As discussed: Once the final SLDs are put into this, it can be merged.

@JakobMiksch
Copy link
Contributor Author

@jdk24 I updated the SLD and added the ones for SIM. If this is fine for you we can merge.

@JakobMiksch JakobMiksch merged commit f1aaee9 into meggsimum:master Nov 8, 2021
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.

3 participants