簡介:本文的記錄學習GeoServer遇到的問題,若是已有答案將會附上。html
1.GeoServer介紹?,功能?java
GeoServer 是 OpenGIS Web 服務器規範的 J2EE 實現,利用 GeoServer 能夠方便的發佈地圖數據,容許用戶對特徵數據進行更新、刪除、插入操做,經過 GeoServer 能夠比較容易的在用戶之間迅速共享空間地理信息。git
具備一下特徵:
兼容WMS和WFS特性程序員
支持PostGIS、Shapefile、ArcSDE、Oracle、VPF、MySQL、MapInfogithub
支持上百種投影web
可以將網絡地圖輸出爲JPEG、GIF、PNG、SVG、KML等格式sql
可以運行在任何基於J2EE/Servlet容器之上數據庫
2.GeoServer如何部署?跨域
參考下面博客部署,GeoServer的war部署方式相似普通java開發的web服務,可是要注意jdk版本問題。瀏覽器
http://www.javashuo.com/article/p-htsalscr-eh.html
3.GeoServer數據源介紹?
- s矢量數據源
Directory of spatial files (shapefiles) - Takes a directory of shapefiles and exposes it as a data store,文件夾下全部shp文件
GeoPackage - GeoPackage數據庫文件SQLite,文件的擴展名爲「.gpkg」
PostGIS - PostGIS Database
PostGIS (JNDI) - PostGIS Database (JNDI)
Properties - Allows access to Java Property files containing Feature information
Shapefile - ESRI(tm) Shapefiles (*.shp),單個shp文件
Web Feature Server (NG) - Provides access to the Features published a Web Feature Service, and the ability to perform transactions on the server (when supported / allowed). - 柵格數據源
ArcGrid - ARC/INFO ASCII GRID Coverage Format
GeoPackage (mosaic) - GeoPackage mosaic plugin
GeoTIFF - Tagged Image File Format with Geographic information,單個tif文件
ImageMosaic - Image mosaicking plugin,能夠選擇擁有多個tif文件的文件夾,會生成一個shp文件
WorldImage - A raster file accompanied by a spatial data file - 其餘數據源
WMS - 懸掛一個遠程網站地圖服務
WMTS - Cascades a remote Web Map Tile Service
4.three.js介紹?
three.js是一個3D JavaScript 庫,Three.js 封裝了底層的圖形接口,使得程序員可以在無需掌握繁冗的圖形學知識的狀況下,也能用簡單的代碼實現三維場景的渲染。
5.cesium介紹?
Cesium是國外一個基於JavaScript編寫的使用WebGL的地圖引擎。Cesium支持3D,2D,2.5D形式的地圖展現,能夠自行繪製圖形,高亮區域,並提供良好的觸摸支持,且支持絕大多數的瀏覽器和mobile。
6.mapbox介紹?
7.矢量瓦片與柵格瓦片概念?
珊格瓦片是預先在Server端繪製好固定的PNG和JPG圖片集合。
矢量瓦片是將矢量數據經過不一樣的描述文件來組織和定義,在客戶端實時解析數據和完成繪製。
8.openlayers介紹?
OpenLayers 是一個專爲Web GIS 客戶端開發提供的JavaScript 類庫包,用於實現標準格式發佈的地圖數據訪問。2D。
9.使用openlayers調用geoserver的wms服務
參考:http://www.javashuo.com/article/p-htsalscr-eh.html
文章中附有github的連接,運行實例。
工做區設置
再次在Layer Preview查看圖層組的url及其參數
注意url與圖層name
10.WMS服務
柵格
11.WFS服務
矢量
12.WCS服務
?
13.WMFS服務
柵格瓦片
14.如何使用PostgreSQL數據源
15.如何使用Oracle數據源
geoserver安裝oracle數據源插件
https://www.jianshu.com/p/08afbdc63848
查看oracle是否支持空間數據庫
oracle11g默認支持空間數據庫,參考下面博客,用sql測試一下
http://www.javashuo.com/article/p-wevjvsim-hk.html
將shp文件導入oracle數據庫中
http://www.javashuo.com/article/p-tttmizat-kk.html
16.如何使用SQLite數據源
17.shp2sdo使用?
參考15
18.cesium與geoserver有什麼關係?
geoserver提供服務,cesium調用服務。
19.cesium調用geoserver服務存在跨域問題解決方法?
說明:使用tomcat自行構建參考下面博客,直接安裝使用的是jetty解決跨域發送不一樣。
https://www.jianshu.com/p/2585d75acdd5
20.使用oracle數據源出現的問題?
未設置空間索引出現如下問題:ora-13226:在沒有空間索引的狀況下不支持此界面
按照http://www.javashuo.com/article/p-wevjvsim-hk.html寫的內容設置oracle會報錯:
ORA-29855: error occurred in the execution of ODCIINDEXCREATE routine
ORA-13249: internal error in Spatial index: [mdidxrbd]
ORA-13249: Error in Spatial index: index build failed
ORA-13249: Error in spatial index: [mdrcrtxfergm]
ORA-13249: Error in spatial index: [mdpridxtxfergm]
ORA-13200: internal error [ROWID:AAAVwJAAEAAAAJjAAA] in spatial indexing.
ORA-13206: internal error [] while creating the spatial index
ORA-13375: the layer is of type [2003] while geometry inserted has type [2002]
ORA-06512: at "MDSYS.SDO_INDEX_METHOD_10I", line 10
意思是圖層類型不一致,須要將POLYGON換成LINE以下圖:
參考:https://docs.oracle.com/cd/E11882_01/appdev.112/e11830/sdo_index_query.htm#SPATL584
21.如何發佈影像地圖