case 4632

This commit is contained in:
2025-04-03 21:05:18 +00:00
parent ff1ce4d483
commit 15933c0b1c
2 changed files with 37 additions and 3 deletions

4
.vscode/launch.json vendored
View File

@@ -65,8 +65,8 @@
"AYANOVA_USE_URLS": "http://*:7575;", "AYANOVA_USE_URLS": "http://*:7575;",
//"AYANOVA_PERMANENTLY_ERASE_DATABASE":"true", //"AYANOVA_PERMANENTLY_ERASE_DATABASE":"true",
//"AYANOVA_REMOVE_LICENSE_FROM_DB":"true", //"AYANOVA_REMOVE_LICENSE_FROM_DB":"true",
"AYANOVA_REPORT_RENDERING_TIMEOUT":"60", "AYANOVA_REPORT_RENDERING_TIMEOUT":"60",
//"AYANOVA_REPORT_RENDER_API_URL_OVERRIDE": "http://localhost:7575", // "AYANOVA_REPORT_RENDER_API_URL_OVERRIDE": "http://localhost:7575",
"AYANOVA_BACKUP_PG_DUMP_PATH": "C:\\data\\code\\postgres_15\\bin" "AYANOVA_BACKUP_PG_DUMP_PATH": "C:\\data\\code\\postgres_15\\bin"
}, },
"sourceFileMap": { "sourceFileMap": {

View File

@@ -532,6 +532,40 @@ namespace AyaNova.Biz
//Is reporting api url overridden in CORS issue scenario (case 4398) //Is reporting api url overridden in CORS issue scenario (case 4398)
if (!string.IsNullOrWhiteSpace(ServerBootConfig.AYANOVA_REPORT_RENDER_API_URL_OVERRIDE)) if (!string.IsNullOrWhiteSpace(ServerBootConfig.AYANOVA_REPORT_RENDER_API_URL_OVERRIDE))
{ {
/*
Plan of action:
Testing here my fix should work as I was able to reproduce the issue exactly so maybe he did something wrong at his end, in any case we need more infor and verification of the fix tested properly so:
Send him the diagnostic report with his patched version and have him run the report via notification both overridden and not overridden should show a difference
I need to know he made the correct setting in the config as that might be what is the issue here
He must first login as superuser and gather support information from the menu item "copy support information", THEN run the test with either override set or not set as a customer notification witht he diagnostic report. Send me the attached support infor and the generated diga report pdf
Then make the opposite override setting, reboot teh server, copy the support info again run the test again with override set the opposite way to before and send me the report with the support info at attachments
If nothing actionable there then rebuild with the patch code commented out and only put into a NEXT folder for download, send him the direct url to install and then he needs to repeat the above exactly as before but with my patch code now removed so it should replicate is first discovery that notify worked when he removed the override and I should get the atual working url and can back figure it out from there
2025-02-20 Ok, confirmed he correctly set the override and in both overriden or not overriden the api call failed the same way and in both cases it was using the special 127 localhost address for the customer notification generated report
so I will build a reversion build and get him to try it again...actually, scratch that he can just install the old one from the old folder. Or can he? Hmm...
https://ayanova.com/download/old/2025-02-18-v8.2.3/ayanova-windows-x64-lan-setup.exe
Here is a programming problem I would like suggestions on resolving:
This is an API web server application for the back end with the API server coded in C# and using the Microsoft dotnet v8 runtime and it is running under IIS.
Part of the API server's duties is to render pdf reports from an html and Javascript template and in order to do this it uses the PuppeteerSharp library to spawn a
instance of the chrome browser, provide it with html and javascript in order to generate a report and then render it to a pdf file.
The problem arises when the API server is set up under TLS security and the javascript running locally at that API server needs to call an API method on it's own API server to get some information.
IIS seems to reject the call as not allowed regardless if the url used to access the local api server is set to localhost or the registered domain.
What could be the issue here?
*/
//case 4632, override breaks special api url when processing customer notification //case 4632, override breaks special api url when processing customer notification
//in order to minimize side effects will go by special user name used here //in order to minimize side effects will go by special user name used here
if ( if (
@@ -775,7 +809,7 @@ namespace AyaNova.Biz
//Keep for debugging headfully //Keep for debugging headfully
// var DefaultArgs = "--no-sandbox"; // var DefaultArgs = "--no-sandbox";
var DefaultArgs = "--headless --no-sandbox"; var DefaultArgs = "--headless --no-sandbox "; // --ignore-certificate-errors (potential proposal, not implemented yet for case 4632 saving here in case want to try it)
if (!string.IsNullOrWhiteSpace(ServerBootConfig.AYANOVA_REPORT_RENDER_BROWSER_PARAMS)) if (!string.IsNullOrWhiteSpace(ServerBootConfig.AYANOVA_REPORT_RENDER_BROWSER_PARAMS))
{ {