Skip to main content
Question

Create web service

  • November 26, 2020
  • 3 replies
  • 31 views

Forum|alt.badge.img+1

Hi all;

 

I just started learning fme server. I want to create a web service using the rest api. I want to show the data in my database as json.

Is there a sample application? What are the fme server settings?

 

Thank you.

 

This post is closed to further activity.
It may be an old question, an answered question, an implemented idea, or a notification-only post.
Please check post dates before relying on any information in a question or answer.
For follow-up or related questions, please post a new question or idea.
If there is a genuine update to be made, please contact us and request that the post is reopened.

3 replies

david_r
Celebrity
  • 8394 replies
  • November 26, 2020

You may want to look into the fmedatastreaming service, it will allow you to return the output of a webservice as e.g. JSON.

There are some examples here, based on the sample workspaces that are installed with FME Server, and that you can inspect in detail: https://docs.safe.com/fme/html/FME_Server_Documentation/ReferenceManual/Examples_data_streaming.htm

 


Forum|alt.badge.img+1
  • Author
  • 11 replies
  • December 2, 2020

Hi David;

Thank you for your help.

Some of my data is too much and I don't want to create them all at the same time for performance. I want to filter by giving parameters and bring in maximum 15 pieces of data each time. Can i do that What kind of path should I follow?

 

Thank you

 


david_r
Celebrity
  • 8394 replies
  • December 2, 2020

Hi David;

Thank you for your help.

Some of my data is too much and I don't want to create them all at the same time for performance. I want to filter by giving parameters and bring in maximum 15 pieces of data each time. Can i do that What kind of path should I follow?

 

Thank you

 

You would typically use a published parameter for the consumer to send e.g. the starting feature number (like a paging function), this can be send as a parameter in the URL.

In the workspace you can then filter the features based on this starting feature number, either using a WHERE-clause in the database or by using a combination of Sampler/Counter/Tester transformers.

The WHERE-clause is going to be much faster if there is a lot of data, however.