Re: [Geoserver-users] How to get the bounding box only for a GetFeature request?

2011-07-27 Thread Adam Ratcliffe
Thanks Andrea, I've tried with WPS and that's exactly what I was looking for.

Cheers
Adam

From: andrea.a...@gmail.com [andrea.a...@gmail.com] On Behalf Of Andrea Aime 
[andrea.a...@geo-solutions.it]
Sent: 27 July 2011 20:11
To: Adam Ratcliffe
Cc: geoserver-users@lists.sourceforge.net
Subject: Re: [Geoserver-users] How to get the bounding box only for a 
GetFeature request?

On Wed, Jul 27, 2011 at 5:24 AM, Adam Ratcliffe
 wrote:
> Hi,
>
> Is it possible to do this with GeoServer?
>
> My use case is that I have an OpenLayers client which uses a WMS layer for 
> data display.  The user can set an OGC filter on the layer to restrict the 
> features displayed.  I would like to provide a function to allow the user to 
> zoom the map to the extent of the currently filtered layer.

WFS does not have such functionality, in order to have the bbox you
still have to get the features with at least one property in

> If not possible in GeoServer, I'm thinking of implementing a standalone web 
> service to calculate the bounding box.  While not familiar with GeoTools I'm 
> wondering if it would make sense to use it as it appears to have support for 
> parsing OGC filters etc.

Yeah, you'd have to also setup filter parsing. You can find the code in the
WFS module, Filter_1_0_0_KvpParser and Filter_1_1_0_KvpParser.

Or, you can use WPS, there is a process that just returns the bounds
of a given feature collection.
The attached process will hit the internal WFS as the source of the
collection, skipping al GML handling and going directly into the
data souce, meaning that if your data source is a postgis db
it will actually run a select for bounds in SQL.

The process can be run against a vanilla GeoServer + WPS
extension with the following:

 curl -XPOST  -H 'Content-type: text/xml'   -d @/tmp/box.xml
"http://localhost:8080/geoserver/wps";

and should result in:


http://www.opengis.net/ows/1.1";>-79.763466
40.505898-71.870476
45.0061http://www.geo-solutions.it
http://geo-solutions.blogspot.com/
http://www.youtube.com/user/GeoSolutionsIT
http://www.linkedin.com/in/andreaaime
http://twitter.com/geowolf

---

--
Got Input?   Slashdot Needs You.
Take our quick survey online.  Come on, we don't ask for help often.
Plus, you'll get a chance to win $100 to spend on ThinkGeek.
http://p.sf.net/sfu/slashdot-survey
___
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users


Re: [Geoserver-users] More on installing GDAL on RHEL5

2011-07-27 Thread Garey Mills

Daniele -

Thank you kindly for this information. As a first step towards 
solving my problems I am going to upgrade the operating system to RHEL6. 
Looking at the libraries that it provides, the versions that GDAL is 
asking for look to be there. Once the libraries are there I'll deal with 
any other issues that arise.


Again, thanks;

Garey Mills

On 7/27/2011 2:43 AM, Daniele Romagnoli wrote:

Hi Garey,
we have sometime encountered a similar issue when testing the linux 
libraries on some particular distro due to the underlying base libs 
being not available/being differents on that distro.
In those cases, after some quick attempts we have concluded to build 
GDAL on the specific machine to make sure to solve this kind of issue 
with the internal libraries.
If you need to build the base GDAL 1.4.5 by yourself, you can follow 
some steps provided in the ImageIO-Ext Setup guide [1].


To be more specific, the chapters/paragraphs you should be interested 
in are:

3.2
3.6.1
3.7.2
3.7.3 (all subchapters)

For more specific info on external libraries (such as MrSID as an 
instance) you can take a look on the related paragraph.


Hope this helps.
Let me know if you have any issue.

Best Regards,
Daniele


[1]:
http://java.net/projects/imageio-ext/downloads/download/Documentation/ImageioExt-SetupGuide.pdf



On Tue, Jul 26, 2011 at 8:14 PM, Garey Mills 
mailto:gmi...@library.berkeley.edu>> wrote:


Hi -

I am having the following problem installing the GDAL plugins in
GeoServer 2.1.1 on RHEL5:

Jul 22, 2011 10:43:50 AM
it.geosolutions.imageio.gdalframework.GDALUtilities loadGDAL
WARNING: Failed to load the GDAL native libs. This is not a problem
unless you need to use the GDAL plugins: they won't be
enabled.java.lang.UnsatisfiedLinkError:
/opt/jdk1.6.0_23/jre/lib/i386/libgdaljni.so: /usr/lib/libstdc++.so.6:
version `GLIBCXX_3.4.9' not found (required by
/opt/jdk1.6.0_23/jre/lib/i386/libgdal.so.1)


I found information about downloading a later version of libstdc++ and
putting it into a separate directory on the net, so I tried that.
I set LD_LIBRARY_PATH to include the new libstdc++. No luck.

I edited catalina.sh and added the argument
'-Djava.library.path="/path/to/new/libstdc++.so" to the invocation of
tomcat. Still no luck.

Anyone have any ideas?

Garey Mills
Library Systems Office
UC Berkeley


--
Magic Quadrant for Content-Aware Data Loss Prevention
Research study explores the data loss prevention market. Includes
in-depth
analysis on the changes within the DLP market, and the criteria
used to
evaluate the strengths and weaknesses of these DLP solutions.
http://www.accelacomm.com/jaw/sfnl/114/51385063/
___
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net

https://lists.sourceforge.net/lists/listinfo/geoserver-users




--
---
Ing. Daniele Romagnoli
GeoSolutions S.A.S.
Software Engineer

Via Poggio alle Viti 1187
55054  Massarosa (LU)
Italy

phone: +39 0584 962313
fax:  +39 0584 962313

http://www.geo-solutions.it 
http://geo-solutions.blogspot.com/
http://www.youtube.com/user/GeoSolutionsIT
http://it.linkedin.com/in/danieleromagnoli


---

--
Got Input?   Slashdot Needs You.
Take our quick survey online.  Come on, we don't ask for help often.
Plus, you'll get a chance to win $100 to spend on ThinkGeek.
http://p.sf.net/sfu/slashdot-survey___
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users


Re: [Geoserver-users] WCS SupportedCRSs

2011-07-27 Thread Ramzi Oueslati
2011/7/26 Andrea Aime :
> On Tue, Jul 26, 2011 at 5:21 PM, Ramzi Oueslati
>  wrote:
>> Hello list,
>>
>> I have been playing with GeoServer for a while and it works great.
>> Thanks and keep up the nice work.
>>
>> I have a question regarding the SupportedCRSs though. I would like to
>> allow reprojection of all my coverages from their native projection to
>> a full list of possible CRSs. However, when I add a coverage,
>> GeoServer only stores the native CRS as supported. I know how to use
>> the REST interface to change this for each coverage but would it be
>> possible to provide a default list of CRSs supported for each added
>> coverage ?
>
> We don't have this ability. It's something that could be added in the
> WCS global configuration and apply automatically on newly created
> coverages.
> If anyone is willing to make such a patch please attach the results
> on jira.codehaus.org as a "improvement" ticket. Should not be too hard to 
> make.

Thank you Andrea for your quick reply. If I find some time in the next
few weeks then I can probably handle this.
As for our current server (2.0.2), I will then continue to change the
SupportedCRSs through REST after each coverage addition.

Best regards,
Ramzi OUESLATI

--
Got Input?   Slashdot Needs You.
Take our quick survey online.  Come on, we don't ask for help often.
Plus, you'll get a chance to win $100 to spend on ThinkGeek.
http://p.sf.net/sfu/slashdot-survey
___
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users


Re: [Geoserver-users] FW: Unable to add MrSID as a layer

2011-07-27 Thread Daniele Romagnoli
Hi Ralph.
Thanks for the feedback on this topic.
Please, read below for a few more feedbacks on that.

On Tue, Jul 26, 2011 at 6:15 PM, Ralph Dell wrote:

>  As the subject says I was unable to add a MrSid layer which confused me
> for a while.
>
> The following  configuration worked. We use windows servers, in this case
> 2008 R2 Standard, but I suspect it will work in most windows environments*
> ***
>
> ** **
>
> Java 1.6.0_21-b07
>
> Tomcat 6.0.18
>
> Geoserver 2.11
>
> Image-io ext 1.08, (windows32-imageio-ext-installer-gdal-mrsid-1.0.8), GDAL
> data and native libraries 1.4.5
>
> ** **
>
> When I used a later version of Java, Tomcat or image-io-ext I had issues
> displaying and/or adding any raster data.
>
Newer imageio-ext versions (1.1.x) which leverage on GDAL 1.7.3 are actually
only supported by GeoServer 2.2.x. There are a few differences between
imageio-ext 1.0.8 and 1.1.x which will result in Geoserver not properly
working if you use depends on the wrong ImageIO-ext version (as an instance
ImageIO-Ext 1.1.1-GDAL1.7.3 on GeoServer 2.0.X won't properly work).

Finally, when using Tomcat > 6.0.2x you should consider this workaround in
case you have any issue in configuring coverages:
http://geo-solutions.blogspot.com/2010/05/fix-geotools-and-geoserver-not-able-to.html

Hope this helps.
Best Regards,
Daniele



> 
>
> I believe Geoserver 2.12 will support GDAL data and native libraries 1.7.3
> 
>
> ** **
>
> Ralph Dell
>
> ** **
>
> *From:* Ralph Dell [mailto:rd...@catawbacountync.gov]
> *Sent:* Monday, July 18, 2011 9:14 AM
> *To:* Andrea Aime
> *Cc:* geoserver-users@lists.sourceforge.net
> *Subject:* Re: [Geoserver-users] Unable to add MrSID as a layer
>
> ** **
>
> Thank You for that answer. I have been away and just saw your response. I
> will upgrade to 2.11 soon and try again. If that does not work I will share
> a sample file.
>
> ** **
>
> Ralph Dell
>
> ** **
>
> *From:* andrea.a...@gmail.com [mailto:andrea.a...@gmail.com] *On Behalf Of
> *Andrea Aime
> *Sent:* Saturday, July 09, 2011 3:02 AM
> *To:* Ralph Dell
> *Cc:* geoserver-users@lists.sourceforge.net
> *Subject:* Re: [Geoserver-users] Unable to add MrSID as a layer
>
> ** **
>
> On Thu, Jul 7, 2011 at 7:38 PM, Ralph Dell 
> wrote:
>
> This is my first post to this list.
>
> I am running geoserver 2.0.3, jetty, as a windows service. I have installed
> GDAL 1.7.3. GDAL_DATA is set up, and the gdal native libraries are in
> GEOSERVER_HOME/wrapper/lib. I have copied a MrSID to
> GEOSERVER_DATA/data/MrSID folder which I created.
>
>  
>
> When adding a new store MrSID is one of my Raster Data Sources, I set the
> connection parameter to file:data/MrSID/Catawba_West.sid and are able to add
> the store. I assume the next step is adding the mrsid as a layer, and here
> is the problem no layer shows up for that store, I’m confused. The
> coveragestore.xml  looks like this
>
>  
>
> 
>
>   CoverageStoreInfoImpl--7f647ee3:13104b2adf6:-7fff
>
>   raster3
>
>   MrSID
>
>   true
>
>   
>
> WorkspaceInfoImpl--4c6ad18e:12f2b013b45:-8000
>
>   
>
>   file:data/MrSID/Catawba_West.sid
>
> 
>
>  
>
> I suspect the coveragestore.xml should contain a lot more information?
>
> ** **
>
> Actually no, that's all is needed. Can you share the sample file?
>
> Btw, try it out with GeoServer 2.1.1, the 2.0.x series is no longer
> supported
>
> by the developer community
>
> ** **
>
> Cheers
>
> Andrea
>
>  
>
>
> --
> ---
> Ing. Andrea Aime
> GeoSolutions S.A.S.
> Tech lead
>
> Via Poggio alle Viti 1187
> 55054  Massarosa (LU)
> Italy
>
> phone: +39 0584 962313
> fax:  +39 0584 962313
>
> http://www.geo-solutions.it
> http://geo-solutions.blogspot.com/
> http://www.youtube.com/user/GeoSolutionsIT
> http://www.linkedin.com/in/andreaaime
> http://twitter.com/geowolf
>
> ---
>
>
> --
> Magic Quadrant for Content-Aware Data Loss Prevention
> Research study explores the data loss prevention market. Includes in-depth
> analysis on the changes within the DLP market, and the criteria used to
> evaluate the strengths and weaknesses of these DLP solutions.
> http://www.accelacomm.com/jaw/sfnl/114/51385063/
> ___
> Geoserver-users mailing list
> Geoserver-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/geoserver-users
>
>


-- 
---
Ing. Daniele Romagnoli
GeoSolutions S.A.S.
Software Engineer

Via Poggio alle Viti 1187
55054  Massarosa (LU)
Italy

phone: +39 0584 962313
fax:  +39 0584 962313

http://www.geo-solutions.it
http://geo-solutions.blogspot.com/
http://www.youtube.com/user/GeoSolutionsIT
http://it.linkedin.com

Re: [Geoserver-users] More on installing GDAL on RHEL5

2011-07-27 Thread Daniele Romagnoli
Hi Garey,
we have sometime encountered a similar issue when testing the linux
libraries on some particular distro due to the underlying base libs being
not available/being differents on that distro.
In those cases, after some quick attempts we have concluded to build GDAL on
the specific machine to make sure to solve this kind of issue with the
internal libraries.
If you need to build the base GDAL 1.4.5 by yourself, you can follow some
steps provided in the ImageIO-Ext Setup guide [1].

To be more specific, the chapters/paragraphs you should be interested in
are:
3.2
3.6.1
3.7.2
3.7.3 (all subchapters)

For more specific info on external libraries (such as MrSID as an instance)
you can take a look on the related paragraph.

Hope this helps.
Let me know if you have any issue.

Best Regards,
Daniele


[1]:
http://java.net/projects/imageio-ext/downloads/download/Documentation/ImageioExt-SetupGuide.pdf



On Tue, Jul 26, 2011 at 8:14 PM, Garey Mills wrote:

> Hi -
>
> I am having the following problem installing the GDAL plugins in
> GeoServer 2.1.1 on RHEL5:
>
> Jul 22, 2011 10:43:50 AM
> it.geosolutions.imageio.gdalframework.GDALUtilities loadGDAL
> WARNING: Failed to load the GDAL native libs. This is not a problem
> unless you need to use the GDAL plugins: they won't be
> enabled.java.lang.UnsatisfiedLinkError:
> /opt/jdk1.6.0_23/jre/lib/i386/libgdaljni.so: /usr/lib/libstdc++.so.6:
> version `GLIBCXX_3.4.9' not found (required by
> /opt/jdk1.6.0_23/jre/lib/i386/libgdal.so.1)
>
>
> I found information about downloading a later version of libstdc++ and
> putting it into a separate directory on the net, so I tried that.
> I set LD_LIBRARY_PATH to include the new libstdc++. No luck.
>
> I edited catalina.sh and added the argument
> '-Djava.library.path="/path/to/new/libstdc++.so" to the invocation of
> tomcat. Still no luck.
>
> Anyone have any ideas?
>
> Garey Mills
> Library Systems Office
> UC Berkeley
>
>
> --
> Magic Quadrant for Content-Aware Data Loss Prevention
> Research study explores the data loss prevention market. Includes in-depth
> analysis on the changes within the DLP market, and the criteria used to
> evaluate the strengths and weaknesses of these DLP solutions.
> http://www.accelacomm.com/jaw/sfnl/114/51385063/
> ___
> Geoserver-users mailing list
> Geoserver-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/geoserver-users
>
>


-- 
---
Ing. Daniele Romagnoli
GeoSolutions S.A.S.
Software Engineer

Via Poggio alle Viti 1187
55054  Massarosa (LU)
Italy

phone: +39 0584 962313
fax:  +39 0584 962313

http://www.geo-solutions.it
http://geo-solutions.blogspot.com/
http://www.youtube.com/user/GeoSolutionsIT
http://it.linkedin.com/in/danieleromagnoli


---
--
Got Input?   Slashdot Needs You.
Take our quick survey online.  Come on, we don't ask for help often.
Plus, you'll get a chance to win $100 to spend on ThinkGeek.
http://p.sf.net/sfu/slashdot-survey___
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users


Re: [Geoserver-users] How to get the bounding box only for a GetFeature request?

2011-07-27 Thread Andrea Aime
On Wed, Jul 27, 2011 at 5:24 AM, Adam Ratcliffe
 wrote:
> Hi,
>
> Is it possible to do this with GeoServer?
>
> My use case is that I have an OpenLayers client which uses a WMS layer for 
> data display.  The user can set an OGC filter on the layer to restrict the 
> features displayed.  I would like to provide a function to allow the user to 
> zoom the map to the extent of the currently filtered layer.

WFS does not have such functionality, in order to have the bbox you
still have to get the features with at least one property in

> If not possible in GeoServer, I'm thinking of implementing a standalone web 
> service to calculate the bounding box.  While not familiar with GeoTools I'm 
> wondering if it would make sense to use it as it appears to have support for 
> parsing OGC filters etc.

Yeah, you'd have to also setup filter parsing. You can find the code in the
WFS module, Filter_1_0_0_KvpParser and Filter_1_1_0_KvpParser.

Or, you can use WPS, there is a process that just returns the bounds
of a given feature collection.
The attached process will hit the internal WFS as the source of the
collection, skipping al GML handling and going directly into the
data souce, meaning that if your data source is a postgis db
it will actually run a select for bounds in SQL.

The process can be run against a vanilla GeoServer + WPS
extension with the following:

 curl -XPOST  -H 'Content-type: text/xml'   -d @/tmp/box.xml
"http://localhost:8080/geoserver/wps";

and should result in:


http://www.opengis.net/ows/1.1";>-79.763466
40.505898-71.870476
45.0061http://www.geo-solutions.it
http://geo-solutions.blogspot.com/
http://www.youtube.com/user/GeoSolutionsIT
http://www.linkedin.com/in/andreaaime
http://twitter.com/geowolf

---

http://www.w3.org/2001/XMLSchema-instance"; xmlns="http://www.opengis.net/wps/1.0.0"; xmlns:wfs="http://www.opengis.net/wfs"; xmlns:wps="http://www.opengis.net/wps/1.0.0"; xmlns:ows="http://www.opengis.net/ows/1.1"; xmlns:gml="http://www.opengis.net/gml"; xmlns:ogc="http://www.opengis.net/ogc"; xmlns:wcs="http://www.opengis.net/wcs/1.1.1"; xmlns:xlink="http://www.w3.org/1999/xlink"; xsi:schemaLocation="http://www.opengis.net/wps/1.0.0 http://schemas.opengis.net/wps/1.0.0/wpsAll.xsd";>
  gs:Bounds
  

  features
  http://geoserver/wfs"; method="POST">

  

  
 
 STATE_NAME
 New York
 
  

  

  

  
  

  bounds

  

--
Got Input?   Slashdot Needs You.
Take our quick survey online.  Come on, we don't ask for help often.
Plus, you'll get a chance to win $100 to spend on ThinkGeek.
http://p.sf.net/sfu/slashdot-survey___
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users