Hope I was able to tame my IDE now. I analyzed many usages of Resource.in() to find a possible example for the docs. Instead I found another example for which I'm in doubt if it works this way:
LoggingUtilsDelegate.java#L385<https://github.com/geoserver/geoserver/blob/ab25ebc6526ea6e0539beadea4d8e983ddbf21cb/src/main/src/main/java/org/geoserver/logging/LoggingUtilsDelegate.java#L385> In general, beneath the try/resource blocks many exception handing code can be found filling lines and lines of code. Turning the IOException into a UncheckedIOException (as I proposed in optionalRead()) may be a first step. But many read functions throw a bunch of mixed Exceptions besides IOException like for example: org.geotools.xsd.Parser:parse(InputStream)<https://github.com/geotools/geotools/blob/e278e5250608d3bef1f2cd31923df5bfa07b1595/modules/extension/xsd/xsd-core/src/main/java/org/geotools/xsd/Parser.java#L123> These are often turned into a throws Exception clause (I made bad experience with). Finally these are either converted into a RuntimeException or it is simply logged. So, a solution may be to introduce some additional exception handler (?Consumer<Throwable>) to the read (and possible write) method. This can either be a logging statement or something turning the Exception(s) into a RuntimeException. All together this turns into a more extensive concept. For [GEOS-10705 ] I'm happy, if no more empty files are created accidentally. Btw: I still observe problems with [GEOS-10683] on Windows. Is this unrelated to GSIP-215? Dieter. Von: Andrea Aime <notificati...@github.com> Gesendet: Montag, 31. Oktober 2022 12:28 An: geoserver/geoserver <geoser...@noreply.github.com> Cc: Dieter Stüken - con terra GmbH <d.stue...@conterra.de>; Author <aut...@noreply.github.com> Betreff: Re: [geoserver/geoserver] [GEOS-10723] params.extractor Resource (PR #6304) One legit QA failure: 2022-10-28T14:25:43.0874191Z 14:25:43,087 [INFO] PMD Failure: org.geoserver.platform.resource.Resource:8 Rule:wildcards Priority:3 No Wildcard Imports. (wildcard imports are disallowed by the Google Java coding convention we adopted). Besides that, the changes to the params-extractor module look good to me, but I'd like to have @jodygarnett<https://eur04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fjodygarnett&data=05%7C01%7C%7Cc1b7c2c43fbc40fd257d08dabb32ebe4%7C6e0bfede3fcb4518a16565dc14fe5620%7C0%7C0%7C638028124624166419%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=mkFbjIlaE65ed%2BbhwVskZrraFYaW8eA6Nhq3gn%2BEUKE%3D&reserved=0> review the changes to Resource. Thinking out loud, it looks like a good addition, but it's also asymmetric, probably the same methods should be offered on the write side? Anyways, let's hear from @jodygarnett<https://eur04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fjodygarnett&data=05%7C01%7C%7Cc1b7c2c43fbc40fd257d08dabb32ebe4%7C6e0bfede3fcb4518a16565dc14fe5620%7C0%7C0%7C638028124624322646%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=j7GdhSXsKsnkAsq7gMr8rEHMvEgomRqjDjrK8leZRTw%3D&reserved=0> - Reply to this email directly, view it on GitHub<https://eur04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fgeoserver%2Fgeoserver%2Fpull%2F6304%23issuecomment-1296951523&data=05%7C01%7C%7Cc1b7c2c43fbc40fd257d08dabb32ebe4%7C6e0bfede3fcb4518a16565dc14fe5620%7C0%7C0%7C638028124624322646%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=732gbI7%2BbXRXQY1iWqZ2JvqzmMhpjEPairjInpyaAX4%3D&reserved=0>, or unsubscribe<https://eur04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAB3RARRCG77J3YCEG66UTH3WF6UKXANCNFSM6AAAAAARPXYWOI&data=05%7C01%7C%7Cc1b7c2c43fbc40fd257d08dabb32ebe4%7C6e0bfede3fcb4518a16565dc14fe5620%7C0%7C0%7C638028124624322646%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=nhQPoE7cDBy3hmwNk%2BVQ2SEBF53UL6CaKRtv2DPW33M%3D&reserved=0>. You are receiving this because you authored the thread.Message ID: <geoserver/geoserver/pull/6304/c1296951...@github.com<mailto:geoserver/geoserver/pull/6304/c1296951...@github.com>>
_______________________________________________ Geoserver-devel mailing list Geoserver-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-devel