1. David Motty
  2. PowerServer
  3. Friday, 6 October 2023 16:48 PM UTC

Hi,

      I am experience an issue that I cannot figure out (hence this post).  Basically we are in the final stages of converting some of our PowerBuilder 2022 applications to be PowerServer 2022 cloud apps.  We have one application that is set up and working on our Dev web server just fine.  This simple application was our proff of Concept that we used to get the permission to move forward with other applications...  Now, we have a second application that we are working on, and have set up basically exactly the same way, but it does not run.  Basically, it looks like it is about to run (even get the application icon showing up in the task bar) but we see an error instead of the main application window opening up.  The error (shown below) is a "Session creation Failed" error with a Status code 404.

Can someone please give me some ideas as to what it might be?  Just to repeat, we used the first application as a template to setting up the second one, but it does not work and I am a PowerBuilder guy not a web guy (so this is all new to me).  One thing I ask my colleague was "Is it ok that the first and the second application are both using port 443 and he did some tests and it appears that it is ok. 

So, would someone please help me with some things I should be checking for to see if I can find the source of this error?  I have searched the community but did not find a solution as of yet :(.

Thanks in advance for your time :)

Dave Motty

 

Accepted Answer
Francisco Martinez @Appeon Accepted Answer Pending Moderation
  1. Friday, 6 October 2023 17:17 PM UTC
  2. PowerServer
  3. # Permalink

Hi Dave,

HTTP 404 simply means the requested URL could not be found by the server. Make sure that the URL is correct, it corresponds to the URL for the site on which you're hosting the Web APIs, and make sure the Web APIs are actually running.
To make sure they're running you should be able to go to https://<website>/FMCSIS/mars_mc/health-ui and see a response. If you run into a HTTP 404 again it means you probably didn't correctly publish the Web APIs to the server or the URL/directory is mistaken.

Regards,
Francisco

 

Edit for more specific solution:

One issue was that IIS did not support the static serving of .JSON files, so it was necessary to do as this guide: https://docs.appeon.com/ps2022/Failed_to_access_the_json_file.html

Comment
  1. David Motty
  2. Tuesday, 21 November 2023 20:32 PM UTC
Thanks Francisco for your assistance. The Application now works :).



To recap for other reading this looking for a similar solution, We had a couple of issues that others should check if they run into similar issues:



1) On the deploy tab of the PowerServer target, I was using the "URL" of the site for the application when I should have been using the "URL_api". This is a little different from PB2022R1.

2) Once that mistake was sorted out, we also had an "Failed to download config file" error. Turns out this was due to the IIS server have not having all folders with the json mime type added. So we had to have that added manually on our server.



Hope this info might help others trouble shot there PowerServer Apps...
  1. Helpful
  1. Armeen Mazda @Appeon
  2. Wednesday, 22 November 2023 00:26 AM UTC
Thanks for the recap!
  1. Helpful
There are no comments made yet.
Armeen Mazda @Appeon Accepted Answer Pending Moderation
  1. Friday, 6 October 2023 17:23 PM UTC
  2. PowerServer
  3. # 1

404 error means the HTTP resource not found.  That is usually because your Web API URL is incorrect or you didn't deploy the Web API to that server you are accessing at that URL.

If you are using PowerServer 2022, each Web API needs to be deployed to its own distinct port # and it cannot be the same port # that is used by the client app.  For example, if the URL for the client app is www.mydomain.com:80/myapp, WebAPI01 should be www.mydomain.com:5000, WebAPI02 should be www.mydomain.com:5001, etc.  Here is documentation about this: https://docs.appeon.com/ps2022/Deploying_multiple_Web_APIs_to_IIS.html

If you upgrade to PowerServer 2022 R2, you can run multiple Web APIs on a single port # and differentiate them by subfolders, and it can be even on same port # as the client app.  For example, if your client app is www.mydomain.com:80/myapp, WebAPI01 should be www.mydomain.com:80/WebAPI01/, WebAPI02 should be www.mydomain.com:80/WebAPI02/, etc.  Here is documentation about this: https://docs.appeon.com/ps2022r2/manual_deploy.html

Comment
There are no comments made yet.
  • Page :
  • 1


There are no replies made for this question yet.
However, you are not allowed to reply to this question.