GeoTools
  1. GeoTools
  2. GEOT-3673

Optimize repeated crops and respect the tile cache hints

    Details

    • Type: Improvement Improvement
    • Status: Resolved Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.7.2
    • Fix Version/s: 2.7.6
    • Component/s: coverage
    • Labels:
      None

      Description

      The code occasionally performs repeated crops, moreover the crop operation used does not honor the tile cache hints, always ends up using the default tile cache.
      The latter is a bug in JAI that can be solved by rewriting the crop operation, which has no native acceleration and is very simple code wise, so that it actually uses the tile cache specified in the hints

        Activity

        Hide
        Michael Bedward added a comment -
        Perhaps this is a candidate for another jaitools operator ?
        Show
        Michael Bedward added a comment - Perhaps this is a candidate for another jaitools operator ?
        Hide
        Andrea Aime added a comment -
        I am about to commit it on GeoTools due to timing reasons (and because the code was developed there, and because I also need it on the stable series, the current stable is unusable in some large scale projects due to the tile cache issues mentioned in the description).
        But sure, if you feel like to taking it, porting it back to jaitools, and update the geotools code to use it, feel free to, I also believe it would be a good idea.
        Show
        Andrea Aime added a comment - I am about to commit it on GeoTools due to timing reasons (and because the code was developed there, and because I also need it on the stable series, the current stable is unusable in some large scale projects due to the tile cache issues mentioned in the description). But sure, if you feel like to taking it, porting it back to jaitools, and update the geotools code to use it, feel free to, I also believe it would be a good idea.
        Hide
        Andrea Aime added a comment -
        Btw, a clarification and a note:
        - not using the specified tile cache causes deadlocks in high concurrency systems that process many jai tile chains in parallel (some operations using a local tile cache, and crop using the global one, in general that happens any time the global tile cache is mixed with per request ones, even if they are both SunTileCache implementations)
        - taking the operation should be easy, just change the jai registration. I believe there are only 2-3 spots in geotools that use GTCropDescriptor directly, so adapting the GT2 code base should be quick
        Show
        Andrea Aime added a comment - Btw, a clarification and a note: - not using the specified tile cache causes deadlocks in high concurrency systems that process many jai tile chains in parallel (some operations using a local tile cache, and crop using the global one, in general that happens any time the global tile cache is mixed with per request ones, even if they are both SunTileCache implementations) - taking the operation should be easy, just change the jai registration. I believe there are only 2-3 spots in geotools that use GTCropDescriptor directly, so adapting the GT2 code base should be quick

          People

          • Assignee:
            Andrea Aime
            Reporter:
            Andrea Aime
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: