[Mapbender_dev] request for comments

Armin Retterath armin.retterath at lvermgeo.rlp.de
Thu Aug 5 06:09:47 EDT 2010


hello list,

we plan to integrate some new features in mapbender trunk. 
1. possibility to register dataurls for resources like newsfeed and kml files
2. a possibility to define some kind of auto update function for the managed 
services and urls 

1) in the next version of mapbender, there will be a possibility to have a 
layertree for georss and kml objects which can be dynamically added to the 
mapbender client (per http-get). in our application we want to give a 
possibility for the decentral organizations to register the urls to those 
resources in the mapbender database. the resources can be searched thru the 
searchinterface and can dynamically integrated in the mapbender application. 
for supporting the search we want to give some classifications and keywords to 
the resources. this is similar to the register process for the wms and wfs and 
is somehow comparable to generating a metadata record with a link to a dataset 
- but easier to understand ;-) . beside of registrating the url, maybe some 
institutions want to upload a kml or gml file cause the have no webserver to 
publish it. the data will be stored in the column datalink_data and mapbender 
will serve it to the web!
here is the draft of the database changes (with a rfc):

-- Table: datalink

-- DROP TABLE datalink;

CREATE TABLE datalink
(
  datalink_id serial NOT NULL,
  datalink_type character varying(50) NOT NULL DEFAULT ''::character varying, 
--georss,kml,gml,geojson
  datalink_type_version character varying(50) NOT NULL DEFAULT ''::character 
varying, --1.0,3.x?
  datalink_url text,
  datalink_owner integer,
  datalink_timestamp integer,
  datalink_timestamp_create integer,
  datalink_timestamp_last_usage integer,
  datalink_abstract text,
  datalink_title character varying(255) NOT NULL DEFAULT ''::character 
varying,
  datalink_data text, --maybe we want a data access for inspire and the data 
should stand on the geoportal cause the institutions have no webserver	
  datalink_network_access integer,
  datalink_owsproxy character varying(50),
  fees character varying(255),
  accessconstraints text,
  CONSTRAINT pk_datalink_id PRIMARY KEY (datalink_id),
--delete orphaned datalinks automatically
  CONSTRAINT datalink_owner_fkey FOREIGN KEY (datalink_owner)
    REFERENCES mb_user (mb_user_id) MATCH SIMPLE
    ON UPDATE CASCADE ON DELETE CASCADE
)
WITH (
  OIDS=FALSE
);
ALTER TABLE datalink OWNER TO postgres;


-- Table: datalink_keyword

-- DROP TABLE datalink_keyword;

CREATE TABLE datalink_keyword
(
  fkey_datalink_id integer NOT NULL,
  fkey_keyword_id integer NOT NULL,
  CONSTRAINT pk_datalink_keyword PRIMARY KEY (fkey_datalink_id, 
fkey_keyword_id),
  CONSTRAINT fkey_keyword_id_fkey_datalink_id FOREIGN KEY (fkey_keyword_id)
      REFERENCES keyword (keyword_id) MATCH SIMPLE
      ON UPDATE CASCADE ON DELETE CASCADE,
  CONSTRAINT fkey_datalink_id_fkey_keyword_id FOREIGN KEY (fkey_datalink_id)
      REFERENCES datalink (datalink_id) MATCH SIMPLE
      ON UPDATE CASCADE ON DELETE CASCADE
)
WITH (
  OIDS=FALSE
);
ALTER TABLE datalink_keyword OWNER TO postgres;

-- Table: datalink_md_topic_category

-- DROP TABLE datalink_md_topic_category;

CREATE TABLE datalink_md_topic_category
(
  fkey_datalink_id integer NOT NULL,
  fkey_md_topic_category_id integer NOT NULL,
  CONSTRAINT datalink_md_topic_category_fkey_datalink_id_fkey FOREIGN KEY 
(fkey_datalink_id)
      REFERENCES datalink (datalink_id) MATCH SIMPLE
      ON UPDATE CASCADE ON DELETE CASCADE,
  CONSTRAINT datalink_md_topic_category_fkey_md_topic_category_id_fkey FOREIGN 
KEY (fkey_md_topic_category_id)
      REFERENCES md_topic_category (md_topic_category_id) MATCH SIMPLE
      ON UPDATE CASCADE ON DELETE CASCADE
)
WITH (
  OIDS=FALSE
);
ALTER TABLE datalink_md_topic_category OWNER TO postgres;

2) another demand in our application is a solution for an automatic update 
process for webservices. many wms are somewhat dynamically - layers go away 
and other layers will newly be generated. in such a case it is too much work 
to update the service by hand! we want ti implement a user interface where the 
owners of the services can define an update interval to steer the update 
process. maybe - daily, weekly or monthly. further they can define if new 
layers/featuretypes should be accessible/searchable direct after the update 
process - or - that the owner should manage this interactively.
draft for a new mapbender database table:

-- Table: auto_update

-- DROP TABLE auto_update;

CREATE TABLE auto_update
(
  auto_update_id serial NOT NULL,
  auto_update_type character varying(50) NOT NULL DEFAULT ''::character 
varying, --wms,wfs,datalink
  fkey_wms_id integer,
  fkey_wfs_id integer,
  fkey_datalink_id integer,
  auto_update_interval character varying(50) NOT NULL DEFAULT ''::character 
varying, --d,w,m
  auto_update_mail boolean,
  auto_update_access integer, --1 - activate access automatically,0 -- don't 
activate access
  auto_update_publish, --1 - publish resource automatically, 0 - hide resource 
first - user has to publish
  auto_update_timestamp integer, -- time when auto_update has been defined or 
last changed
  auto_update_timestamp_last_update integer,
  auto_update_status integer,
  auto_update_status_error_message text,
  CONSTRAINT pk_auto_update_id PRIMARY KEY (auto_update_id),
  CONSTRAINT auto_update_fkey_wms_id_fkey FOREIGN KEY (fkey_wms_id)
      REFERENCES wms (wms_id) MATCH SIMPLE
      ON UPDATE CASCADE ON DELETE CASCADE,
  CONSTRAINT auto_update_fkey_wfs_id_fkey FOREIGN KEY (fkey_wfs_id)
      REFERENCES wfs (wfs_id) MATCH SIMPLE
      ON UPDATE CASCADE ON DELETE CASCADE,
  CONSTRAINT auto_update_fkey_datalink_id_fkey FOREIGN KEY (fkey_datalink_id)
      REFERENCES datalink (datalink_id) MATCH SIMPLE
      ON UPDATE CASCADE ON DELETE CASCADE
)
WITH (
  OIDS=FALSE
);

ALTER TABLE auto_update OWNER TO postgres;

please feel free to answer if you have problems or have some good ideas to 
extent this functions.

regards 
armin
  

-- 
Im Auftrag
--
Armin Retterath

Kompetenz- und Geschäftsstelle Geodateninfrastruktur Rheinland-Pfalz
beim
Landesamt für Vermessung und Geobasisinformation Rheinland-Pfalz

Ferdinand-Sauerbruch-Straße 15
56073 Koblenz
Telefon 0261/492-466
Telefax 0261/492-492
armin.retterath at lvermgeo.rlp.de
http://www.geoportal.rlp.de


More information about the Mapbender_dev mailing list