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

tileindex can't reach to jsonb - "Could not find attribute location->>'20m' in tileindex" #6979

Open
MathewNWSH opened this issue Nov 30, 2023 · 0 comments

Comments

@MathewNWSH
Copy link

Expected behavior and actual behavior.

Hello,
I have created a JSONB table in my PostgreSQL database that looks like this:

{
  "10m": "/vsicurl/...",
  "20m": "/vsicurl/...",
  "30m": "/vsicurl/..."
}

Then, in my map file, for an existing tile index definition, I changed the tile item to the following:

TILEITEM "location->>'10m'"

Unfortunately, what was returned is:

 [warn] [pid 16] mod_fcgid: stderr: msDrawRasterLayerLow(S2 Masking_03): entering.
 [warn] [pid 16] mod_fcgid: stderr: msPostGISLayerOpen called: geometry from (select * from jsonb_test2 where maxcc <= 100 AND (pid  = '-1' OR '-1' = '-1') AND (tile  = '-1' OR '-1' = '-1') order by maxcc desc) as subquerry using unique unique_id using srid=3857
 [warn] [pid 16] mod_fcgid: stderr: msPostGISLayerOpen: No connection in pool, creating a fresh one.
 [warn] [pid 16] mod_fcgid: stderr: msConnPoolRegister(time_idx,user=postgres password=***********************************************************************************************************msPostG
 [warn] [pid 16] mod_fcgid: stderr: ISLayerOpen: Got PostGIS version 30400.
 [warn] [pid 16] mod_fcgid: stderr: msPostGISLayerOpen: Forcing 2D geometries: no.
 [warn] [pid 16] mod_fcgid: stderr: msPostGISLayerFreeItemInfo called.
 [warn] [pid 16] mod_fcgid: stderr: msPostGISLayerFreeItemInfo called.
 [warn] [pid 16] mod_fcgid: stderr: msPostGISLayerGetItems called.
 [warn] [pid 16] mod_fcgid: stderr: msPostGISParseData called.
 [warn] [pid 16] mod_fcgid: stderr: msPostGISParseData: unique_column=unique_id, srid=3857, geom_column_name=geometry, table_name=(select * from jsonb_test2 where maxcc <= 100 AND (pid  = '-1' OR '-1' = '-1') AND (tile  = '-1' OR '-1' = '-1') order by maxcc desc) as subquerry
 [warn] [pid 16] mod_fcgid: stderr: msPostGISReplaceBoxToken called.
 [warn] [pid 16] mod_fcgid: stderr: msPostGISLayerG
malloc_consolidate(): invalid chunk size
 [warn] [pid 16] mod_fcgid: stderr: etItems executing SQL: select * from (select * from jsonb_test2 where maxcc <= 100 AND (pid  = '-1' OR '-1' = '-1') AND (tile  = '-1' OR '-1' = '-1') order by maxcc desc) as subquerry where false limit 0
 [warn] [pid 16] mod_fcgid: stderr: msPostGISLayerInitItemInfo called.
 [warn] [pid 16] mod_fcgid: stderr: msPostGISLayerInitItemInfo called.
 [warn] [pid 16] mod_fcgid: stderr: msDrawRasterLayerLow(): Memory allocation error. Could not find attribute location->>'20m' in tileindex.
 [warn] [pid 16] mod_fcgid: stderr: msPostGISLayerFreeItemInfo called.
 [warn] [pid 16] mod_fcgid: stderr: msPostGISLayerClose called: geometry from (select * from jsonb_test2 where maxcc <= 100 AN
 [warn] [pid 16] mod_fcgid: error reading data, FastCGI server closed connection
 [error] [pid 16] End of script output before headers: mapserv_wrapper
427862 - 10.100.224.192 - - [30/Nov/2023:15:12:58 +0000] "GET /?map=/etc/mapserver/jsonb.map&SERVICE=WMS&VERSION=1.3.0&REQUEST=GetMap&BBOX=3028150.602318660822,6242919.002070402727,3033777.2594449264,6248489.279866745695&CRS=EPSG:3857&WIDTH=999&HEIGHT=988&LAYERS=Cloudless%20Mozaik&STYLES=&FORMAT=image/png&DPI=157&MAP_RESOLUTION=157&FORMAT_OPTIONS=dpi:157&TRANSPARENT=TRUE HTTP/1.1" 500 810 "-" "Mozilla/5.0 QGIS/32207"
 [error] [pid 15] mod_fcgid: process /usr/local/bin/mapserv_wrapper(76) exit(communication error), get signal 6, possible coredump generated

MapServer version and installation method

Docker Mapserver 8 camp2camp image

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

No branches or pull requests

1 participant