Eduard Lebedyuk · Mar 10, 2017 go to post

You can define class storage on ppgs. Can't do that on % variables.

Any kind of implicit kill does not affect ppgs but does affect % variables.

They only case where I use % variables is if I really need some global object (java gateway and CSP global vars). Otherwise I use ppgs.

Eduard Lebedyuk · Mar 3, 2017 go to post
  1. Try setting RenderTimeOut and PrintTimeOut properties for the report.
  2. Check logfile (you can determine directory in which it gets created by instantiating the report and calling GetRootDir method, but usually it's a value of the ^%SYS("TempDir") global, unless you specify ReportDir property or parameter).
Eduard Lebedyuk · Mar 3, 2017 go to post

To add, names of REST arguments in URL should correspond and be in the same order, as method arguments.

Here's a Caché ObjectScript style guidelines.

Eduard Lebedyuk · Mar 3, 2017 go to post

When encountering errors with XSLT I usually try to execute it here to check that it is valid and produces correct result.

As you're trying to use XSLT2 package, have you tried XSLT package?

Have you tried XSLT without callback?

Eduard Lebedyuk · Feb 27, 2017 go to post

You need to convert private key into OpenSSH format using PuttyGen and use that key with Ensemble.

Eduard Lebedyuk · Feb 23, 2017 go to post

Process memory is allocated as required, so decreasing $ZSTORAGE would not decrease actual memory usage.

Eduard Lebedyuk · Feb 23, 2017 go to post

Compare Angular results with REST API debugger, such as Postman and debug proxy, i.e. Charles.

Eduard Lebedyuk · Feb 23, 2017 go to post

Add these lines at the beginning of your REST method if you're on older versions (pre 16.1 I think):

Set %response.CharSet = "utf-8"
Set %response.ContentType="application/json"

If you're on a newer version add class params to your broker class:

Parameter CHARSET = "utf-8";
Parameter CONTENTTYPE = "application/json";
Eduard Lebedyuk · Feb 22, 2017 go to post

For HTML files:

  • Move them to another non-web-app folder
  • Convert them all to utf-8
  • Execute in a terminal: set ^%SYS("CSP","DefaultFileCharset")="utf-8"
  • Move them back

see weird characters on a query to the DB

REST output or input REST params? What locale are you using for server?

Eduard Lebedyuk · Feb 22, 2017 go to post

Reports are a big, separate issue from modern web applications technologies.  Unless you're writing a reports web application.

This can be slow/bad in applications with large data?

Sure. To avoid that make your REST service logically asynchronous (see DeepSee REST API for MDX execution):

  • User sends a query
  • Server immediately returns query key
  • Server executes query into another (jobbed) process
  • Some time later user sends query key
  • Server returns current query status (in progress, done)
  • If query is done send user the data

Also, if you're using pure SQL, scrollable resultset can be used in a similar fashion.

  It's better/recommended to use ZenReports even with ZenMojo applications?

It's just another approach to reports.

  Or Zen Mojo, like any other applications based on HTML, JS and PHP can support this with any problem?

Reports can be done using ZEN Mojo, sure.

The preparation of the JSON is very fast because the use of %DynamicObject and %DynamicArray; ZenReport can be slower than it?

Time to render JSON is negligible compared to time time you need to generate a report. ZenReport calls other software to render report files, so it's slower, sure, but still I think the main timesink here is execution and not rendering.

To sum up, your requirements determine the necessarily approach.