Solved

Problem with WFS Creation with FME Server


Badge +4

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.

icon

Best answer by hollyatsafe 30 July 2021, 21:56

View original

11 replies

Badge +4

If it can help : Here is attached the log file

I see an error here :

bug_wfs_3Thank you

Badge +4

I tried to change Target_URI but no changes

Badge +4

Here is another log

Badge +4

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.

 

Badge +2

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.

Badge +4

@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

Badge +4

@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) :

Badge +2

@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.

Badge +4

@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.

Badge +4

@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 !

 

Badge +4

@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