Please check here
https://playground.jsreport.net/w/anon/QLkuZ0EP
Posts made by admin
-
RE: Custom Font rendered smaller than system font
I'm not an expert on fonts, but maybe the following trick will solve your problem
<style> body { zoom: 1.5; } </style>
Note that the font handling is processed fully by Chrome and jsreport does not influence it.
-
RE: Regarding License Key Duplication
This needs to work... Are you configuring that newer 4.6 jsreport? Are you sure your config file is properly applied? Have you restarted jsreport?
-
RE: chrome processes always running ?
I've tried the following...
- Windows 11 OS
- Download 4.8.0 jsreport.exe binary https://github.com/jsreport/jsreport/releases/tag/4.8.0
- Download nssm 2.24 x64 exe binary
- Place both to the same dir
- run
nssm install jsreport
- in the form I fill path to the dir and add
start
argument - I open the studio localhost:5488 and let it create sample reports
- Then I render in the loop 1000 reports
const client = require('@jsreport/nodejs-client')('http://localhost:5488') async function run () { for (let i = 0; i < 1000; i++) { await client.render({ template: { name: 'invoice-main' } }) console.log('rendered', i) } } run().then(() => console.log('done')).catch(err => console.error(err))
In the taskmanager I see ~ constant number of chrome processes
The default number of worker threads jsreport uses is 2. Therefore, I see 2 main chrome processes and several nested chrome processes which chrome uses. If you use the same approach, do you get different observations?
Note if you want to let jsreport close the chrome processes after every render, you can create file
jsreport.config.json
and add the following{ "chrome": { "strategy": "dedicated-process" } }
-
RE: Latency
I don't think this could have anything to do with jsreport configuration.
Doesn't your report do remote calls? Let's say you are fetching some remote data or images? -
RE: Regarding License Key Duplication
For the development environment, you can use the following configuration. This will allow you to use the same license key as you have in prod without warnings.
{ "license": { "development": true } }
Every other production instance needs a new license key. Or you can purchase the more expensive scale license, which provides a license key that can be used on infinite instances.
-
RE: Upgrading node.js version
Yes, we will try to update it with the next release, it shouldn't be problem.
Only the compiled jsreport binary could be a problem so it may take more time. -
RE: Global function
That is task for the jsreport asset.
In jsreport script, you can require the function from asset like this
https://jsreport.net/learn/assets#require-asset -
RE: Regarding License Key Duplication
I don't understand the question...
If you have a single instance license key, you can use it just in the single jsreport app. -
RE: Docx eq helper is not working
Please share a minimal playground demo replicating the issue.
https://playground.jsreport.net/ -
RE: Regarding License Key Duplication
So, if I get it right, you have now two instances of jsreport which are using the same single instance license key. Thus the warning in the log.
-
RE: highcharts formatter assistance
JSON.stringify
doesn't serialize functions.
What is the reason for putting the highcharts definition into helpers function?
Do you wan't to reuse it in multiple charts in the same template?
You can put such function directly in the<script>
tags. -
RE: Data Sanitization
What sanitization do you mean? To avoid handlebars escaping, use tripple brackets
{{{prop}}}
-
RE: Error Starting JSREPORT on K8S
I've tried google cloud run and I have it running in a minute with just "defaults".
Google Cloud console -> Google Cloud Run -> Deploy Container -> Create Service
container image url : jsreport/jsreport:4.8.0-full
Allow unauthenticated invocations
Container Port: 5488This works for you as well? The problem is the custom image with templates?
I'm not sure if this is relevant to the original question, so maybe you'd better move to the new topic.
-
RE: chrome processes always running ?
jsreport by default keeps a pool of running Chrome processes. If you want to close the chrome processes after the rendering, you can use
dedicated-process
strategy.In every case, all chrome processes should be closed after the jsreport is closed.
This doesn't happen? What OS and jsreport installation do you use? -
RE: Error Starting JSREPORT on K8S
The default is
30s
and can be configured using configworkers.initTimeout
.
Have you tried running on a better HW?
I will try the google cloud run in the next days to see what is the problem. -
RE: Chinese/Korean Letters not supporting in PDF
Please try the latest jsreport so we can isolate if it's a problem with the older Chrome binary or not.
-
RE: Chinese/Korean Letters not supporting in PDF
It works in the playground, right?
If this is the case, try installing the same fonts as those in the playground on your server.
https://github.com/jsreport/playground-worker/blob/master/Dockerfile#L9
If you use the same, I am afraid the problem can be with the old Chrome in the jsreport 2.10.0 and you may need to update. -
RE: Error Starting JSREPORT on K8S
What kind of container do you deploy there? An official jsreport image? Or something custom? Can you try the default and full jsreport images?
Note we have a dedicated tutorial for using serverless google cloud functions here
https://jsreport.net/learn/gcloud-functions-serverless -
RE: Performance Optimization Request for DOCX to PDF Conversion Using LibreOffice/Unoconv
I'm afraid you'll have better luck at a LibreOffice forum as this is directly related to it...
But maybe someone else has a solution to improve LibreOffice perf when converting on Windows and poor HW specs?