Errors in Service Center are also shown in console of browser
Application Type

In one of my Client Actions I ask if the base url is the same as the base url specified in an entity. When this IF is false, an error is logged in Service Center (we do not want to show this error to the user). The users will see the error message in the handler that is in the assign.

Now I see this error can be seen in the console of the browser. Is there a way to not show the notification in the console of the browser (so it is only shown in Service Center)?



Rank: #129

Hi Bart,

I'm reading from your question that it's probably about not disclosing secret information about url's to the client, and also not showing it in the browser console, but still be able to log those details in service center, right?  So you need this only in specific, sensitive, checks, not everywhere in your app ?

So for me, I would probably move the entire check into a server action for security, but supposing you have a compelling reason to do the check itself on the client, you could move only the raising of the error to server side.


option 1

server action "Check_URL", where you do your comparing with the stored url, in case of an error, you raise exceptionX, with all sensitive details that you only want to see logged in service center, but not shared with anybody.  In the same action, you immediately handle exceptionX, and in the handler you raise exceptionY, with a user friendly message, not disclosing anything secret.

option 2

server action "RaiseExceptionX", same as above, but you keep the checking on the client, and in case you want to raise the exception, you call the server action to do that instead of raising directly in client

See attached oml, for option 2, but I think option 1 is better

You can see that doing the same trick (reraising in a handler) will not keep your secret information out of the browser console.

Hope this points you in the right direction,



Rank: #934

Hi Dorine,

Thanks for your detailed answer. I think both options are a solution (one better than the other).

Rank: #460

Hi Bart,

If the only thing you want/need is a log in the Service Center, there is a simple solution for that ! Instead of rasing one exception, there is a Client & server side function provided by the platform called "LogMessage". Simple replace all those exceptions with that action and your custom log message for each case ! 

Hope this helps !

Rank: #934

Hi Romero,

Thanks for your answer! At this moment I also do not load the screen and send a user friendly message to the screen when the exception is raised, so only changing the exception to a LogMessage (on the client side will not do the trick). If i change this on the client side it still shows up in the console (the only change is that it now is a message instead of an error).

But I think as you and Dorine mentioned I need to move the checks to the server side to prevent this from happening.