Quantcast
Channel: SCN: Message List - Data not getting fetched from demo gateway system

Data not getting fetched from demo gateway system

0
0

Hi Experts,

 

I have implemented the blog article Consume NetWeaver Gateway services via SAPUI5 - Part 1 given at http://scn.sap.com/community/developer-center/front-end/blog/2012/10/15/consume-netweaver-gateway-services-via-sapui5 by Ivan Fermia.

 

I am working on NWDS 7.3 SP08 PAT0003 and I have installed SAPUI5 toolkit (version 1.8.4) within my NWDS.

 

As suggested by Raul Romero in the comments section, I added a prefix into the Gateway Service URL and wrote '/proxy/http://gw.esworkplace.sap.com/sap/opu/odata/IWBEP/RMTSAMPLEFLIGHT_2'

instead of 'http://gw.esworkplace.sap.com/sap/opu/odata/IWBEP/RMTSAMPLEFLIGHT_2'

 

Also according to Kaloyan Raev's suggestion in the comments section, I replaced the line

oTable.bindRows('FlightCollection');

with oTable.bindRows('/FlightCollection'); by writing a leading slash before FlightCollection.

 

I am running this application from NWDS by right clicking on my SAPUI5 Application Project and selecting Run As -> Web App Preview as shown below.

 

RunAs.png

 

On doing this it opens up web browser within NWDS, but it des not show any data in the table, just a blank table as shown below.

 

BlankTable.png

 

I am seeing the same result (blank table with no data) even if I copy-paste the URL in Internet Explorer 8 and Mozilla Firefox 18.

 

Can anyone please guide me in knowing why I am not able to fetch any data from the online demo gateway system? Is it that I cannot run this application from NWDS and have to do it from Eclipse IDE only?

 

Any suggestions will be highly appreciated.

 

Thanks & Regards,

Saurabh


Re: Data not getting fetched from demo gateway system

0
0

Your browser's console logging will probably give some clues as to what's going on. Can you paste here what you find there so we can examine the situation?

 

dj

Re: Data not getting fetched from demo gateway system

0
0

Hi DJ,

 

Thank you so much for your response.

 

I am running the application in Mozilla Firefox and below is what I found in the Error Console of Firefox:

----------------------------------------------------------------------------------------------------------------------------                Timestamp: 1/31/2013 9:53:07 AM

Error: not well-formed

Source File: http://localhost:53845/SITMIL/resources/sap/ui/core/library-preload.json

Line: 1, Column: 1

Source Code:
{


Timestamp: 1/31/2013 9:53:07 AM

Error: not well-formed

Source File: http://localhost:53845/SITMIL/resources/sap/ui/commons/library-preload.json

Line: 1, Column: 1

Source Code:
{


Timestamp: 1/31/2013 9:53:08 AM

Error: not well-formed
Source File: http://localhost:53845/SITMIL/resources/sap/ui/ux3/library-preload.json

Line: 1, Column: 1

Source Code:
{


Timestamp: 1/31/2013 9:53:08 AM

Error: not well-formed
Source File: http://localhost:53845/SITMIL/resources/sap/ui/table/library-preload.json

Line: 1, Column: 1

Source Code:
{


Timestamp: 1/31/2013 9:53:09 AM

Error: not well-formed
Source File: http://localhost:53845/SITMIL/resources/sap/ui/core/cldr/en_US.json

Line: 1, Column: 1

Source Code:
{


Timestamp: 1/31/2013 9:53:09 AM

Error: The character encoding of the HTML document was not declared. The document will render with garbled text in some browser configurations if the document contains characters from outside the US-ASCII range. The character encoding of the page must be declared in the document or in the transfer protocol.
Source File: http://localhost:53845/SITMIL/index.html

Line: 0

----------------------------------------------------------------------------------------------------------------------------

 

Regards,

Saurabh

Re: Data not getting fetched from demo gateway system

0
0

Those are strange errors, given the circumstances. Perhaps your web server is sending the wrong content-type headers for the JSON files, causing Firefox to think they're HTML or XML?

Re: Data not getting fetched from demo gateway system

0
0

Hi DJ,

 

When I run the application subsequently after observing these error in the Error Console in Firefox, I am still seeing a blank table with no data, but this time the Error Console does not record any errors at all.

 

Even when I open the application URL in Internet Explorer 8, I am seeing just the blank table and there are no JavaScript errors reported by IE.

 

I am not sure what I can try and do to make this application work out and fetch the data.

 

Regards,

Saurabh

Re: Data not getting fetched from demo gateway system

0
0

Hi Saurabh

 

Next step would be to check that the HTTP calls are actually being made to retrieve the data. You can do that either by checking the network part of your developer tools in your browser, or the backend SAP system. Are the calls being made?

 

cheers

dj    

Re: Data not getting fetched from demo gateway system

0
0

Thanks for the heads up DJ.

 

Can I use something like HTTPWatch to check out if the HTTP calls are actually made to retrieve the data?

 

Regards,

Saurabh

Re: Data not getting fetched from demo gateway system

0
0

Possibly (I've not used that myself, altho I've used something probably similar: Fiddler). I was thinking more of looking at the SAP ICF back in SAP, and the network traffic monitor in the browser. But perhaps HTTP watch will give some clues too.         


Re: Data not getting fetched from demo gateway system

0
0

Hi DJ,

 

We do not yet have an AS ABAP system with the SAP NetWeaver Gateway 2.0 installed in it, hence I am trying to use the SAP NetWeaver Gateway Demo system (http://scn.sap.com/docs/DOC-31221).

So currently I am not in a position to check the SAP ICF.

 

I will try to check the HTTPWatch trace and see if the calls to retrieve the data are happening at all and update this thread.

 

Also I am suspecting that the call to the gateway demo system are not happening from within my company's network. I will also try to run this application from an external network.

 

Thanks a lot for your patience in bearing with me.

 

Regards,

Saurabh

Re: Data not getting fetched from demo gateway system





Latest Images