Skip to main content
Solved

Problem with WFS Creation with FME Server


arxit
Contributor
Forum|alt.badge.img+5
  • Contributor

Hello,

 

I followed steps of this tutorial (using generic workspace) : https://community.safe.com/s/article/how-to-create-a-wfs-service-using-fme-server but i Have a problem :

bug_wfsI followed all steps.

I just have a doubt on Target_URI :

bug_wfs_2 

Is it OK ?

Thank you.

Best answer by hollyatsafe

arxit wrote:

I tried to change path "/Users/hcoxon/Downloads/useParameters.xml" for using a local path (on FME Server machine) : "C:\\FmeServerShare\\resources\\data\\downloads\\useParameters2.xml".

 

And, good news : I have no error for opening XML file (it seems to be an grant error).

 

However, there is another error :

fme_server_118:52:01 | Expected data attribute 'text_line_data' is missing. The file 'C:\\FmeServerShare\\resources\\system\\temp\\engineresults\\FME_07627F72_1627577519194_23420\\TEXTLINE_1\\return.xml' will be written empty

 

Any idea ?

 

Thank you.

 

@arxit​ ,

The Text File Writer will only write contents stored in the attribute text_line_data. It looks like there is a mistake in the workspace 'generic-wfs-20180.fmw' attached to the article that means this attribute is not being created. To fix this:

1. Open the workspace in FME Workbench

2. Open the Parameter Editor for the XMLFormatter transformer

3. Under the XML Output section, update the 'Attribute to contain XML output' from _xml_output to text_line_data

4. Save and re-publish the workspace

 

I will look at getting that file updated on the article.

View original
Did this help you find an answer to your question?

11 replies

arxit
Contributor
Forum|alt.badge.img+5
  • Author
  • Contributor
  • July 28, 2021

If it can help : Here is attached the log file

I see an error here :

bug_wfs_3Thank you


arxit
Contributor
Forum|alt.badge.img+5
  • Author
  • Contributor
  • July 29, 2021

I tried to change Target_URI but no changes


arxit
Contributor
Forum|alt.badge.img+5
  • Author
  • Contributor
  • July 29, 2021

Here is another log


arxit
Contributor
Forum|alt.badge.img+5
  • Author
  • Contributor
  • July 29, 2021

I tried to change path "/Users/hcoxon/Downloads/useParameters.xml" for using a local path (on FME Server machine) : "C:\\FmeServerShare\\resources\\data\\downloads\\useParameters2.xml".

 

And, good news : I have no error for opening XML file (it seems to be an grant error).

 

However, there is another error :

fme_server_118:52:01 | Expected data attribute 'text_line_data' is missing. The file 'C:\\FmeServerShare\\resources\\system\\temp\\engineresults\\FME_07627F72_1627577519194_23420\\TEXTLINE_1\\return.xml' will be written empty

 

Any idea ?

 

Thank you.

 


Forum|alt.badge.img+2
  • Best Answer
  • July 30, 2021
arxit wrote:

I tried to change path "/Users/hcoxon/Downloads/useParameters.xml" for using a local path (on FME Server machine) : "C:\\FmeServerShare\\resources\\data\\downloads\\useParameters2.xml".

 

And, good news : I have no error for opening XML file (it seems to be an grant error).

 

However, there is another error :

fme_server_118:52:01 | Expected data attribute 'text_line_data' is missing. The file 'C:\\FmeServerShare\\resources\\system\\temp\\engineresults\\FME_07627F72_1627577519194_23420\\TEXTLINE_1\\return.xml' will be written empty

 

Any idea ?

 

Thank you.

 

@arxit​ ,

The Text File Writer will only write contents stored in the attribute text_line_data. It looks like there is a mistake in the workspace 'generic-wfs-20180.fmw' attached to the article that means this attribute is not being created. To fix this:

1. Open the workspace in FME Workbench

2. Open the Parameter Editor for the XMLFormatter transformer

3. Under the XML Output section, update the 'Attribute to contain XML output' from _xml_output to text_line_data

4. Save and re-publish the workspace

 

I will look at getting that file updated on the article.


arxit
Contributor
Forum|alt.badge.img+5
  • Author
  • Contributor
  • August 2, 2021
hollyatsafe wrote:

@arxit​ ,

The Text File Writer will only write contents stored in the attribute text_line_data. It looks like there is a mistake in the workspace 'generic-wfs-20180.fmw' attached to the article that means this attribute is not being created. To fix this:

1. Open the workspace in FME Workbench

2. Open the Parameter Editor for the XMLFormatter transformer

3. Under the XML Output section, update the 'Attribute to contain XML output' from _xml_output to text_line_data

4. Save and re-publish the workspace

 

I will look at getting that file updated on the article.

Thank you very much Holly.

The WFS structure is OK (i can see it in Google Chrome).

However i cannot open entities ; there is no layer / geometry in the WFS :

wfs_fme_server 

Maybe it is because of my data sources (Spatialite Database) ?

When i published on FME Server, i selected "Upload data files".

But it seems that the FeatureReader is not read : I attach the log file and my workbench file, because i followed all steps (and i think that all it's okay).

 

I tried to change "Schema/ Data Features" parameter to "Data Features", but there are no changes :

wfs_fme_server_3 

Thank you


arxit
Contributor
Forum|alt.badge.img+5
  • Author
  • Contributor
  • August 2, 2021
hollyatsafe wrote:

@arxit​ ,

The Text File Writer will only write contents stored in the attribute text_line_data. It looks like there is a mistake in the workspace 'generic-wfs-20180.fmw' attached to the article that means this attribute is not being created. To fix this:

1. Open the workspace in FME Workbench

2. Open the Parameter Editor for the XMLFormatter transformer

3. Under the XML Output section, update the 'Attribute to contain XML output' from _xml_output to text_line_data

4. Save and re-publish the workspace

 

I will look at getting that file updated on the article.

(Here is th log , because i can't attach 2 files) :


Forum|alt.badge.img+2
hollyatsafe wrote:

@arxit​ ,

The Text File Writer will only write contents stored in the attribute text_line_data. It looks like there is a mistake in the workspace 'generic-wfs-20180.fmw' attached to the article that means this attribute is not being created. To fix this:

1. Open the workspace in FME Workbench

2. Open the Parameter Editor for the XMLFormatter transformer

3. Under the XML Output section, update the 'Attribute to contain XML output' from _xml_output to text_line_data

4. Save and re-publish the workspace

 

I will look at getting that file updated on the article.

Hi @arxit​ ,

 

In the FeatureReader the Features To Read Parameter points to the _read_type attribute. It looks like there is a typo in the AttributeCreator_3 that means this attribute is not being created, this causes the FeatureReader to fail, so no features are actually being defined in the output XML file.

 

To fix this, in the AttributeCreator_3 update '_read_types' to '_read_type'.

 

I've removed the generic-wfs-20180.fmw from the article because of these errors. The original workspace generic-wfs.fmw created in 2018 is correct and worked in my tests with 2021.


arxit
Contributor
Forum|alt.badge.img+5
  • Author
  • Contributor
  • August 4, 2021
hollyatsafe wrote:

@arxit​ ,

The Text File Writer will only write contents stored in the attribute text_line_data. It looks like there is a mistake in the workspace 'generic-wfs-20180.fmw' attached to the article that means this attribute is not being created. To fix this:

1. Open the workspace in FME Workbench

2. Open the Parameter Editor for the XMLFormatter transformer

3. Under the XML Output section, update the 'Attribute to contain XML output' from _xml_output to text_line_data

4. Save and re-publish the workspace

 

I will look at getting that file updated on the article.

Hi Holly,

 

Thank you very much, the WFS works. I can see it with Data Inspector 🙂

However I have a problem to read it into QGIS and ArcGIS Pro.

  • In QGIS, I can see my two layers, but when i drag and drop them into the map, QGIS crash
  • In ArcGIS Pro, I have this message :

 fme_server_safeIs there a problem ?

I attach the XML corresponding to the WFS generated by FME Server.

 

Thank you.


arxit
Contributor
Forum|alt.badge.img+5
  • Author
  • Contributor
  • August 4, 2021
hollyatsafe wrote:

@arxit​ ,

The Text File Writer will only write contents stored in the attribute text_line_data. It looks like there is a mistake in the workspace 'generic-wfs-20180.fmw' attached to the article that means this attribute is not being created. To fix this:

1. Open the workspace in FME Workbench

2. Open the Parameter Editor for the XMLFormatter transformer

3. Under the XML Output section, update the 'Attribute to contain XML output' from _xml_output to text_line_data

4. Save and re-publish the workspace

 

I will look at getting that file updated on the article.

Re Holly,

 

I succeeded to open my data into QGIS !

But it only works one time in a hundred : sometimes it is very slow and sometimes it opens the data in 10 sec ! It is very strange, because requests (in FME Server jobs) stop after 10-20 sec.

 

I will be in on holiday for 2 weeks (from tomorrow), so I could do some more tests after 17 august.

 

Thank you for your help !

 


arxit
Contributor
Forum|alt.badge.img+5
  • Author
  • Contributor
  • August 23, 2021
hollyatsafe wrote:

@arxit​ ,

The Text File Writer will only write contents stored in the attribute text_line_data. It looks like there is a mistake in the workspace 'generic-wfs-20180.fmw' attached to the article that means this attribute is not being created. To fix this:

1. Open the workspace in FME Workbench

2. Open the Parameter Editor for the XMLFormatter transformer

3. Under the XML Output section, update the 'Attribute to contain XML output' from _xml_output to text_line_data

4. Save and re-publish the workspace

 

I will look at getting that file updated on the article.

Hi Holly, it works fine !

The slowness was due to the use of a VPN.

Thank you very much


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings