span8
span4
span8
span4
As announced by Google on December 11,2018, Google Fusion Tables and the Fusion Tables API will be turned off on December 3,2019.Some users may start to see errors in August 2019.Fusion Tables support will be removed from FME after the service has been shut down.For ways to migrate your data out of Google Fusion Tables using FME,see the blog post 7+ Google Fusion Tables Alternatives.
FME Server can respond to database events in real-time by making use of external database functions.This allows you to push out data from your database into applications using FME Server in real-time as features in the database are modified.In this article,we show you how to setup Oracle and FME Server to respond to multiple feature edits in a single call.This bulk insert is useful when you anticipate a large number of edits being made so that FME Server does not get tied up with multiple calls.For smaller numbers of edits,you can setup database triggers to call FME Server after each feature edit,this is described in the following article:Single edits Oracle: Push data from the database to an application in real-time
NOTE: This example was created to demonstrate different interaction possibilities between FME Server and Oracle Spatial.This article contains several code snippets which must be customized for particular environments.
This tutorial was tested with FME Desktop and FME Server 2017.0,and Oracle 11g.
In this example we use a simple web interface that calls FME Server to upload data and log updates in an Oracle database.The sequence of events when a user runs the demo from the web interface is as follows:
This example shows how to enable Oracle to call a workspace on FME Server using an HTTP request.We recommend you read the scripts carefully to you ensure you have fully tailored them to your database environment.
The first step is to configure the UTL_HTTP procedure on the Oracle database and to assign the appropriate permissions to Oracle users who will be running the demo.This can be done by running the Configure_UTL_HTTP.sql file included in the Oracle_Bulk_Demo.zip file attached to this article.The file needs to be run as the "sys" user.This sql creates an entry in the access control list,which allows the database to connect to FME Server using UTL_HTTP.Some modifications need to be made to the script as indicated in comments and in the following image.
We need to create a table in our database to store the feature information,we also need to create the function which sends the feature information to the second workspace on FME Server.We also need to create a procedure that concatenates all information from the temporary table into a string that can be appended to a URL.This can be done by running Create_Table_and_Triggers.sql.Some modifications to the SQL script need to be made as indicated in the comments and in the following images.
...
This demo involves one template and one workspace:oracle_bulk_loader.fmwtandoracle_bulk_logger.fmw,which are included in the zip file attached above.
Open theoracle_bulk_loader.fmwttemplate.
Change the Oracle writer database parameters to your Oracle database parameters.
Once this is done the workspace should be published to the FME Server specified in the Oracle Triggers as a Job Submitter service,in a new repository called ‘trigger'.
Open the workspaceoracle_bulk_logger.fmw.
Change the FeatureReader transformer database parameters to your Oracle database parameters.
Note: Make sure to select the corresponding Oracle user associated with your table - i.e."CLAUDE" in the above example.
Next,we will edit a couple of Private Parameters.In the Navigator window,go to User Parameters > Private Parameters.Right click [GOOGLEFUSIONTABLES_OUT_USER_NAME_GOOGLEFUSIONTABLES] and select Edit Value… In the Edit User Parameter dialog,change the Username to your own Gmail username.Use the same steps to change the password to your Gmail password for the [GOOGLEFUSIONTABLES_OUT_PASSWORD_GOOGLEFUSIONTABLES] private parameter.
This workspace should also be published to FME Server as a Job Submitter service in the ‘trigger' repository.
Make sure the fmeguest role has Read and Run permissions on the trigger repository.This can be set by logging into FME Server as the admin user and clicking Security on the left sidebar under Admin,clicking Roles,and selecting fmeguest.Under Permissions,expand the Repositories section and for the trigger repository select Read and Run if they are not already selected.
Run theoracle_bulk_logger.fmwworkspace once either from FME Server or FME Desktop to create the Google Fusion Table (to view the table,log in to the Gmail account specified and the table should appear under the ‘Drive' Tab) make note of the table's URL for the next step.
Copy the entire contents of the "web" folder,included in the zip file attached to this article,to a web server.Then edit the contents of the index.html by replacing "swisscheese" with the name of your own FME Server,and the URL of the Google Fusion Table at lines 81 and 147 with your own URL.
...
Once this is complete,open index.html in a web browser and run one of the options.This should modify the data in the Oracle database triggering information to be written to the Google Fusion Table.You can click on the link on the web page to open the table and view your changes.
Single edits Oracle: Push data from the database to an application in real-time
Single edits PostgreSQL: Push data from the database to an application in real-time
Notify FME Server when a directories contents change (2013 and earlier only)
Receiving email,Part 3: Using email attachments (2015)
Sending email,Part 5: Sending an email with attachments (2015)
HTTP POST Requests to FME Server from Node.js
Configuring a JMS Publisher or Subscriber with an Oracle Weblogic Server
Streaming features from PostGIS to FME using WebSockets
Sending email,Part 2: Sending an email using the FMEServerNotifier (2015)
Receiving email,Part 1: Setting up a topic and an email address (2015)
© 2019 亚搏在线Safe Software Inc |Legal