Re: [Arches] Re: add_tileserver_layer is not available in Arches v5

2020-06-05 Thread Harri Kiiskinen
 Thanks for help, that helped me to the right direction; instead of dealing
with CORS settings, I set up a Proxy with Apache to redirect the connection
so it looks like everything takes place on the same server and now the maps
appear perfectly. (The layer definitions were quite ok already).

But where do you get the error messages? I probably could have figured out
this myself if I had seen the error message somewhere, but the arches.log
is empty, and I'm running the test server with Debug=True which does not
give any meaningful messages either.

Thanks for the help, though,

Harri K.

to 4. kesäk. 2020 klo 18.49 Dennis Wuthrich (dwuthr...@fargeo.com)
kirjoitti:

> Hi Harri,
>
> You should confirm that you are referencing your geoserver layer
> properly.  Check to confirm that you have a map layer definition that looks
> something like so:
>
> [{"id": "test-raster", "type": "raster", "source": "test-raster"}]
>
> where test-raster is the name you gave your map source.  Assuming you've
> done this, you should confirm that you've set your CORS policy properly.  I
> get the following error when trying to access your Geoserver layer in Arches
>
> Access to fetch at '
> http://vps815520.ovh.net:8080/geoserver/hk/wms?service=WMS=1.1.1=GetMap=1565430.3392804079,5948635.289265558,1878516.4071364924,6261721.357121639=image/png=EPSG%3A3857=256=256=hk:ostia'
> from origin 'http://localhost:8000' has been blocked by CORS policy: No
> 'Access-Control-Allow-Origin' header is present on the requested resource.
> If an opaque response serves your needs, set the request's mode to
> 'no-cors' to fetch the resource with CORS disabled.
>
>
>
> Hope this points you in the proper direction.
>
> -Dennis
>
>
>
>
>
> On Thursday, June 4, 2020 at 8:31:59 AM UTC-7, Harri Kiiskinen wrote:
>>
>> Hi all,
>>
>> (if it would be better to start a new subject for this, let me know)
>>
>> I've been trying to get the following layer visible in Arches:
>>
>>
>> http://vps815520.ovh.net:8080/geoserver/hk/wms?service=WMS=1.1.0=GetMap=hk%3Aostia=1367121.2720044549%2C5123218.583961782%2C1369226.8194238057%2C5125090.037473778=768=682=EPSG%3A3857=application/openlayers
>>
>> The map source definition is like this:
>>
>> {"type": "raster", "tiles": ["
>> http://vps815520.ovh.net:8080/geoserver/hk/wms?service=WMS=1.1.1=GetMap={bbox-epsg-3857}=image/png=EPSG%3A3857=256=256=hk:ostia
>> <http://vps815520.ovh.net:8080/geoserver/hk/wms?service=WMS=1.1.1=GetMap=%7Bbbox-epsg-3857%7D=image/png=EPSG%3A3857=256=256=hk:ostia>"],
>> "tileSize": 256}
>>
>> which to me looks very much like it should be according to the examples
>> in this thread. Also
>> - the map is visible as overlay
>> - the geoserver log files actually show the requests coming to the server
>> from arches, and there are no error messages
>> - the bbox in the request covers the bbox of the map in the geoserver
>> layer definitions.
>>
>> And I still cannot see anything in Arches.
>>
>> Any suggestions on where to look? My installation is very recent, like
>> this week monday, and "pip list" shows arches version 5.0.
>>
>> Otherwise things seem to work as they should.
>>
>> Best,
>>
>> Harri Kiiskinen
>>
>>
>> torstai 16. huhtikuuta 2020 21.57.53 UTC+3 Dennis Wuthrich kirjoitti:
>>>
>>> Hi Robin,
>>>
>>> You should check your geoserver configuration to see why the tiff
>>> disappears at certain zoom levels.
>>>
>>> As to your second question: Arches automatically zooms reports to the
>>> instance geometry (if it exists).  If your instance is represented by a
>>> point geometry, then the map does get zoomed in pretty close.  You could
>>> write an ticket requesting an enhancement to Arches at the github
>>> repository that summarizes this issue.
>>>
>>> Cheers,
>>>
>>> Dennis
>>>
>>> On Wednesday, April 15, 2020 at 2:53:27 AM UTC-7, Robin Rönnlund wrote:
>>>>
>>>> Dear Dennis,
>>>>
>>>> Thank you so much for this! Yes, it did work (almost), and I am very
>>>> much relieved!
>>>>
>>>> What is still weird, though, is that at certain zoom levels, the map
>>>> partially or wholly disappears:
>>>>
>>>> [image: Screenshot from 2020-04-15 12-46-28.png]
>>>>
>>>> Here it is visible.
>>>>
>>>>
>>>> [image: Screenshot from 2020-04-15 12

[Arches] Re: add_tileserver_layer is not available in Arches v5

2020-06-04 Thread Harri Kiiskinen
Hi all,

(if it would be better to start a new subject for this, let me know)

I've been trying to get the following layer visible in Arches:

http://vps815520.ovh.net:8080/geoserver/hk/wms?service=WMS=1.1.0=GetMap=hk%3Aostia=1367121.2720044549%2C5123218.583961782%2C1369226.8194238057%2C5125090.037473778=768=682=EPSG%3A3857=application/openlayers

The map source definition is like this:

{"type": "raster", "tiles": 
["http://vps815520.ovh.net:8080/geoserver/hk/wms?service=WMS=1.1.1=GetMap={bbox-epsg-3857}=image/png=EPSG%3A3857=256=256=hk:ostia;],
 
"tileSize": 256}

which to me looks very much like it should be according to the examples in 
this thread. Also
- the map is visible as overlay
- the geoserver log files actually show the requests coming to the server 
from arches, and there are no error messages
- the bbox in the request covers the bbox of the map in the geoserver layer 
definitions.

And I still cannot see anything in Arches.

Any suggestions on where to look? My installation is very recent, like this 
week monday, and "pip list" shows arches version 5.0.

Otherwise things seem to work as they should.

Best,

Harri Kiiskinen


torstai 16. huhtikuuta 2020 21.57.53 UTC+3 Dennis Wuthrich kirjoitti:
>
> Hi Robin,
>
> You should check your geoserver configuration to see why the tiff 
> disappears at certain zoom levels.
>
> As to your second question: Arches automatically zooms reports to the 
> instance geometry (if it exists).  If your instance is represented by a 
> point geometry, then the map does get zoomed in pretty close.  You could 
> write an ticket requesting an enhancement to Arches at the github 
> repository that summarizes this issue.
>
> Cheers,
>
> Dennis
>
> On Wednesday, April 15, 2020 at 2:53:27 AM UTC-7, Robin Rönnlund wrote:
>>
>> Dear Dennis,
>>
>> Thank you so much for this! Yes, it did work (almost), and I am very much 
>> relieved!
>>
>> What is still weird, though, is that at certain zoom levels, the map 
>> partially or wholly disappears:
>>
>> [image: Screenshot from 2020-04-15 12-46-28.png]
>>
>> Here it is visible.
>>
>>
>> [image: Screenshot from 2020-04-15 12-46-33.png]
>> But at a closer level, the middle disappears.
>>
>> [image: Screenshot from 2020-04-15 12-46-39.png]
>> Even closer, more disappears...
>>
>>
>> Is there something I should do?
>>
>>
>> Also, additional question! :) Is there a way of setting the default zoom 
>> level for individual resource models? Right now, the default is that you 
>> start on a ridiculously close level:
>>
>> [image: Screenshot from 2020-04-15 12-46-48.png]
>> ...and nothing can be seen...
>>
>>
>>
>> All my very best from Athens, Greece
>> Robin
>>
>>
>> Den onsdag 15 april 2020 kl. 01:08:12 UTC+3 skrev Dennis Wuthrich:
>>>
>>> Robin,
>>>
>>> Set the map source name to "kalaureia-plan" (this is what you reference 
>>> in the map layers json).  Also, you may want to add =true to 
>>> the URL in the map source (this will make your overlay transparent in areas 
>>> outside of the tif).  I made these small changes and can view your 
>>> geoserver service in Arches:
>>>
>>>
>>>
>>>
>>>
>>> On Tuesday, April 14, 2020 at 1:34:34 AM UTC-7, Robin Rönnlund wrote:
>>>>
>>>> Dear Dennis and Adam,
>>>>
>>>> I followed these instructions to the letter, all very nice, thank you! 
>>>> I did everything, there were no protests from geoserver, nor when I added 
>>>> the layers etc. The map layer turned up in Arches, I could modify it as I 
>>>> liked, but... The map does not actually turn up. What do I do wrong?
>>>>
>>>> My geotiff is in EPSG:3857 and I did the following:
>>>>
>>>> 1. Uploaded the tiff to the geoserver directory.
>>>> 2. Added the tiff through Add stores/GeoTiff
>>>> 3. Went to /admin/ and added the tiff through "Map sources"
>>>>
>>>> {"type": "raster", "tiles": ["
>>>> https://pragmata2.sia.uu.se/geoserver/Pragmata/wms?bbox={bbox-epsg-3857}=image/png=WMS=1.1.1=GetMap=EPSG:3857=256=256=Pragmata:kalaureia-plan;],
>>>>  
>>>> "tileSize": 256}
>>>>
>>>> Saved etc.
>>>>
>>>> 4. Added it as a map layer
>>>>
>>>> [{"id": "kalaureia-plan", "type": "raster", "source": "kala