Re: [MapServer-users] Mapcache second level dimensions

2023-02-16 Thread Johannes Paul
Coming back on a semi-working 2nd level dimension use case, if I use the
below conf:
```

/nfs_tiles/test/{dim:product}.sqlite3


PNG
worldwind
test_cache

  
/nfs_tiles/test/mosa.db
select product from mosa where
sensor=:dim
select product from mosa
  


```
Then the *dim_product *is passed to the cache '*test_cache*' with the
sub-dimension result using parameters '
*=spot-img2_product=spot-img2*', only if the result returns
only 1 sud-dimension value ... if it returns X sub-dimensions values I
still get an error : `*dimension (product) for tileset (mosa_test) returned
invalid number (X) of subdimensions (1 expected)*`

It seems the mechanism is not working the way it should be, isn't it ?
Johannes

On Thu, 16 Feb 2023 at 09:54, Johannes Paul 
wrote:

> Hello,
>
> I'm trying to implement second level SQLite dimension as explained in the
> doc
> https://mapserver.org/mapcache/dimensions.html#second-level-dimensions
>
> Following that exemple on mapcache v1.12, I'm expecting that the below
> conf, with WMS request on 'mosa_test' tileset with 'dim_sensor=phr', shall
> use the “product” sub-dimension values to query the data source
> 'mosa_source' on tileset 'test_primary' with 'dim_product' for each product
> returned by the 2nd level dimension request (cache 'test_cache' is
> pre-existing) ...
>
> ```
> 
> /nfs_tiles/test/{dim:product}.sqlite3
> 
> 
> test_cache
> worldwind
> 
>
>  .*
>
> 
> PNG
> 
> 
> /nfs_tiles/test/mosa_{dim:sensor}.sqlite3
> 
> 
> PNG
> worldwind
> mosa_cache
> mosa_source
> 
>   
> /nfs_tiles/test/mosa.db
> select product from mosa where
> sensor=:dim
> select product from mosa
>   
> 
> 
> 
> 
>http://server/mapcache/
> 
> 
> 
> PNG
> test_primary
> true
> 
> 
> 
> ```
>
> However all I get is a mapcache error in the httpd log, as follows :
> `dimension (sensor) for tileset (mosa_test) returned invalid number (X) of
> subdimensions (1 expected)`
> If my 'sensor' dimension returns X products (which is the use case), I get
> the error above, and if my 'sensor' dimension returns 1 product (let say
> spot-img2), I get an error on the mapcache generated WMS request to the
> source 'mosa_source' on tileset 'test_primary' with parameters
> '=spot-img2_sensor=spot-img2' ... which can obviously not work !
> Why is mapcache not using 'dim_product' in the WMS request ?
>
> Have I missed something ?
> Thanks,
> Johannes
>
___
MapServer-users mailing list
MapServer-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users


[MapServer-users] Mapcache second level dimensions

2023-02-16 Thread Johannes Paul
Hello,

I'm trying to implement second level SQLite dimension as explained in the
doc
https://mapserver.org/mapcache/dimensions.html#second-level-dimensions

Following that exemple on mapcache v1.12, I'm expecting that the below
conf, with WMS request on 'mosa_test' tileset with 'dim_sensor=phr', shall
use the “product” sub-dimension values to query the data source
'mosa_source' on tileset 'test_primary' with 'dim_product' for each product
returned by the 2nd level dimension request (cache 'test_cache' is
pre-existing) ...

```

/nfs_tiles/test/{dim:product}.sqlite3


test_cache
worldwind

   
 .*
   

PNG


/nfs_tiles/test/mosa_{dim:sensor}.sqlite3


PNG
worldwind
mosa_cache
mosa_source

  
/nfs_tiles/test/mosa.db
select product from mosa where
sensor=:dim
select product from mosa
  




   http://server/mapcache/



PNG
test_primary
true



```

However all I get is a mapcache error in the httpd log, as follows :
`dimension (sensor) for tileset (mosa_test) returned invalid number (X) of
subdimensions (1 expected)`
If my 'sensor' dimension returns X products (which is the use case), I get
the error above, and if my 'sensor' dimension returns 1 product (let say
spot-img2), I get an error on the mapcache generated WMS request to the
source 'mosa_source' on tileset 'test_primary' with parameters
'=spot-img2_sensor=spot-img2' ... which can obviously not work !
Why is mapcache not using 'dim_product' in the WMS request ?

Have I missed something ?
Thanks,
Johannes
___
MapServer-users mailing list
MapServer-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users