Hi Justin,
Thanks for reply. We want to make use of multiple WFS sources to fetch
data and reduce the total time for downloading the feature instances.
(When number of feature instances are in hundreds-thousands.)
My different regions here belongs to different WFS sources so
region 1 (WFS1) : http://10.129.13.8/geoserver/wfs
region 2 (WFS2) : http://10.112.117.29/geoserver/wfs
So I'll fetch some instances from one WFS and some instances from other. I
don't know how much it will be useful to reduce the total time. But still
a try.
1) One thing I would like to know how getFeature within BB works. So does
it returns instances which are completely inside given BB or instances
which are completely as well as partially inside given BB ?
So in your solution,
<ogc:And>
<ogc:BBOX>
<BBOX filter for region 1>
</ogc:BBOX>
</ogc:BBOX>
<BBOX filter for region 2>
</ogc:BBOX>
</ogc:And>
This will work only if getfeature also returns instaces which are
partially inside BB.
If your solution returns the instaces overlapping in both regions, then
I'll do parallel fetch from 2 WFS as:
First getFeature POST request to WFS1 = Fetch all instances within BB of
region 1+ Fetch instances overlapping in region 1 and region 2
Second getfeature POST request to WFS2 = Fetch all instances within BB of
region 2
Merge both results.
2) Also about spatial join of two GML, It's OK even if geoserver doesn't
provide any support for joining two GML files. I will write code for
spatial join, but I'm not getting any idea about how to proceed for it.
Couldn't get much information on web :(.
Thanks,
Sanket Patle.
Hi Sanket,
Responses inline. Out of curiosity what are the motivations for setting
up such a scheme?
Sanket Chandulal Patle wrote:
Hi,
I've set up 3 geoserver WFS. Each containing same feature data. I want
to
fetch data from all 3 sources at the same time. So I'm partitioning data
based on bouding box. So if (minx,miny) and (maxx,maxy) are bounding box
coordinates, I'm doing horizontal partitioning of bouding box in 3
regions
as
Interval = (maxy-miny) / 3.
Region 1 BB: (minx,miny) , (maxx, miny+ Interval)
Region 2 BB: (minx,miny+Interval), (maxx, miny+2*Interval)
Region 3 BB: (minx,miny+2*Interval), (maxx,miny+3*interval)
Horizontal partition like this
|-------------------------------|
| |
| Region 1 |
| |
|-------------------------------|
| |
| Region 2 |
| |
|-------------------------------|
| |
| Region 3 |
| |
|-------------------------------|
Problems that I'm facing
1) I'm using get feature request within particular bounding box to fetch
data from each region. But there are some features whose geometry
overlaps
with both regions. So they are not included in getfeature requests of
any
of the region. (Since they are not within bounding box of any region) >
Can anyone tell me how can I fetch such instances which overlaps with
more
than one region?
THere is probably more than one way to do this, but could you just And
two of the filters together. Something like:
<ogc:And>
<ogc:BBOX>
<BBOX filter for region 1>
</ogc:BBOX>
</ogc:BBOX>
<BBOX filter for region 2>
</ogc:BBOX>
</ogc:And>
If you wanted to all three regions in one query you would wrap them in
an Or like:
<ogc:Or>
</ogc:Or>
<ogc:And>
<AND fitler for regions 1 and 2>
</ogc:And>
</ogc:And>
<AND fitler for regions 2 and 3>
</ogc:And>
</ogc:And>
2) I get response to each of the getfeature request as some GML data.
Can
I perform spatial join on this GML data to merge the results? Is yes,
then
how it can be done?
Unfortunately not, geoserver does not really support joins in this
manner. I can't think of an easy way to do this either.
Thanks,
Sanket Patle.
------------------------------------------------------------------------------
SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas,
Nevada.
The future of the web can't happen without you. Join us at MIX09 to
help
pave the way to the Next Web now. Learn more and register at
http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/
_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users
--
Justin Deoliveira
OpenGeo - http://opengeo.org
Enterprise support for open source geospatial.