Updated POC
Combined uploader and downloader into a single screen to streamline gui
Removed search filters since we don't currently have this functionality in the rest services
Able to connect to the aois endpoint when the List button is clicked and populate the grid with a list of the aois in the database; We can use this list to warn the user if they try to upload a duplicate aoi
Figure 1: AOI upload/download menu
Items in yellow indicate areas requiring further discussion/testing. POC = Proof of Concept
AOI Downloader is launched by a button on the BAGIS Tools toolbar which is installed with BAGIS-H.
Add-In contacts the repository to get a list of available AOI's. See figure 1 for sample screen. A default alias (http://webservices.geog.pdx.edu/) will be compiled with the source code but the user will have the option to update. See step 3.
Button to update the server connection information: server url, user name, password; Cache server name and token.Specify default server name in BAGIS config; At that point we go and use the token before anything else; OAUTH 1.0A; Twitter XAuth model. Basic Http request. Need to design this form for changing the server connection. Also where to store default server name in a config file.
The default is to download the whole most recent copy of the AOI but user can define specific layers (hrus). (Need GUI sample and spec for query page)
Add-in contacts the repository to request an AOI; Warn user that an existing local copy of AOI with same name will be overwritten (if applicable).
Repository converts .shp and .img files to FGDB format. Repository adds BAGIS metadata tags to xml file for each layer file. Have working POC that tags are maintained through file conversion and unzipping process. (Need spec for XML tags)
Repository creates an xml metadata file containing the names and date(s) created for all layers that can be updated. (Need spec for XML file, need list of required and editable layers)
Repository adds all layers to a single .zip file. File can be downloaded all at once or in chunks. BAGIS Toolbar downloads all at once.
Add-in downloads the zip file(s) from the repository
Add-in unzips the AOI in the location specified by the user in step 3.
Cancel task button can cancel uploads/downloads in some cases where the UI is not locked by Windows
Update status button queries the REST service to determine the status of each task. The statuses are not automatically updated while the server is processing
View task log opens a window with the local history of a selected AOI. BAGIS Tools maintains a log file at the root of an AOI for AOIs that are uploaded and downloaded. This could be replaced by a server query if desired which would be more robust. In the current design, the log will be deleted if the AOI is deleted or overwritten
Need POC that date created/modified in a FeatureClass matches the XML metadata generated in step 5 if the FeatureClass is not touched. Plan to use the IDatasetNameFileStat for feature classes because it is so much faster than looking at the layer metadata from step 4.
Figure 2: Old download AOI screen for add-in
Additional task:
Open port 8000 on server