Problem of multiple sending reports from the same shedule in less than two minutes



  • Hello,
    I have a problem with the jsreport schedules. I am currently using jsreport version 2.8 and the shedules are firing and generating the same report multiple times, it is as if the shedules were firing multiple times in a row.

    I hope you can help me



  • Hi,

    do you have just a single instance of jsreport looking at the same data?
    Could you please share the jsreport logs from the particular timeframe?

    Thank you



  • Yes, I have a single instance of jsreport for that data, but I have noticed that there are occasions in which the shedule fires and generates a single report and there are others in which it generates it several times, and when it does that it is because it enters several times to beforeRender.

    is there any way to fix this?



  • Please provide the logs, maybe there will be something interesting.
    Please make sure it includes the debug level.

     "logger": {
        "console": {
          "transport": "console",
          "level": "debug"
        },
        "file": {
          "transport": "file",
          "level": "debug",
          "filename": "logs/reporter.log"
        },
        "error": {
          "transport": "file",
          "level": "error",
          "filename": "logs/error.log"
        }
      },
    


  • I am new to jsreport and I don't know how to access the logs



  • No problem... You should find them in the file logs/reporter.log. That is the default location.



  • but i am working with jsrepor on docker and azure





  • This post is deleted!


  • 2021-12-15T14:04:55.208511073Z 2021-12-15T14:04:55.207Z - debug: Page request: GET (image) data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAJYAAABWCAYAAAAt6W9WAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbW...
    2021-12-15T14:04:55.213742347Z 2021-12-15T14:04:55.210Z - debug: Page request finished: GET (image) 200 data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAJYAAABWCAYAAAAt6W9WAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbW...
    2021-12-15T14:04:55.215582943Z 2021-12-15T14:04:55.214Z - debug: Page request: GET (font) https://fonts.gstatic.com/s/poppins/v15/pxiDyp8kv8JHgFVrJJLmg1hVF9eO.woff2
    2021-12-15T14:04:55.215612145Z 2021-12-15T14:04:55.214Z - debug: Page request: GET (font) https://fonts.gstatic.com/s/poppins/v15/pxiEyp8kv8JHgFVrJJfecg.woff2
    2021-12-15T14:04:55.774777336Z 2021-12-15T14:04:55.774Z - debug: Page request finished: GET (font) 200 https://fonts.gstatic.com/s/poppins/v15/pxiEyp8kv8JHgFVrJJfecg.woff2
    2021-12-15T14:04:55.781765402Z 2021-12-15T14:04:55.776Z - debug: Page request finished: GET (font) 200 https://fonts.gstatic.com/s/poppins/v15/pxiDyp8kv8JHgFVrJJLmg1hVF9eO.woff2

    2021-12-15T14:04:57.977181108Z 2021-12-15T14:04:57.976Z - debug: Running chrome with params {"printBackground":true,"landscape":true,"marginTop":"0.5cm","marginLeft":"0.5cm","marginRight":"0.5cm","format":"Legal","margin":{"top":"0.5cm","right":"0.5cm","left":"0.5cm"}}
    2021-12-15T14:04:58.617501951Z 2021-12-15T14:04:58.612Z - info: Starting rendering request 17 (user: undefined)
    2021-12-15T14:04:58.621338952Z 2021-12-15T14:04:58.619Z - info: Rendering template { name: estadisticas, recipe: chrome-pdf, engine: handlebars, preview: false }
    2021-12-15T14:04:58.624347209Z 2021-12-15T14:04:58.624Z - debug: Data item not defined for this template.
    2021-12-15T14:04:58.627593379Z 2021-12-15T14:04:58.627Z - debug: Resources not defined for this template.
    2021-12-15T14:04:58.633255876Z 2021-12-15T14:04:58.633Z - debug: Executing script estadisticas using http-server strategy
    2021-12-15T14:04:58.642206345Z 2021-12-15T14:04:58.642Z - debug: Replaced assets ["/share/utilities/library_request.js","/core/services/global_service.js","/share/services/stats_service.js","/share/utilities/date_format.js","/share/utilities/message_configuration.js","/share/utilities/sendgrid.js","/share/utilities/application_insights.js","/modules/estadisticas/services/estadisticas_service.js"]

    2021-12-15T14:05:11.962177783Z 2021-12-15T14:05:11.961Z - debug: Processing schedule 7942bef4-c36b-4394-8500-295b856b70ff is starting.

    2021-12-15T14:05:32.907350032Z 2021-12-15T14:05:32.907Z - debug: Report stored as VnHMYwVQyiK0xuC7.pdf
    2021-12-15T14:05:32.909338636Z 2021-12-15T14:05:32.909Z - debug: Executing script anonymous using http-server strategy
    2021-12-15T14:05:34.350837088Z 2021-12-15T14:05:34.350Z - debug: Processing schedule efcfc49e-f070-4aa7-ab7d-c7d1ccb0e78a succeeded.

    2021-12-15T14:05:34.350837088Z 2021-12-15T14:05:34.350Z - debug: Processing schedule efcfc49e-f070-4aa7-ab7d-c7d1ccb0e78a succeeded.

    2021-12-15T14:05:37.718760264Z 2021-12-15T14:05:37.718Z - info: Starting rendering request 18 (user: undefined)
    2021-12-15T14:05:37.726971011Z 2021-12-15T14:05:37.726Z - info: Rendering template { name: estadisticas, recipe: chrome-pdf, engine: handlebars, preview: false }
    2021-12-15T14:05:37.728342586Z 2021-12-15T14:05:37.727Z - debug: Data item not defined for this template.
    2021-12-15T14:05:37.728971520Z 2021-12-15T14:05:37.728Z - debug: Resources not defined for this template.
    2021-12-15T14:05:37.730043978Z 2021-12-15T14:05:37.729Z - debug: Executing script estadisticas using http-server strategy
    2021-12-15T14:05:37.740977273Z 2021-12-15T14:05:37.740Z - debug: Replaced assets ["/share/utilities/library_request.js","/core/services/global_service.js","/share/services/stats_service.js","/share/utilities/date_format.js","/share/utilities/message_configuration.js","/share/utilities/sendgrid.js","/share/utilities/application_insights.js","/modules/estadisticas/services/estadisticas_service.js"]

    2021-12-15T14:05:55.367279303Z 2021-12-15T14:05:55.367Z - debug: Mapeo: rgba(166, 201, 106, 1)
    2021-12-15T14:05:55.367864234Z 2021-12-15T14:05:55.367Z - debug: Mapeo: rgba(119, 161, 229, 1)
    2021-12-15T14:05:55.368222052Z 2021-12-15T14:05:55.367Z - debug: Mapeo: rgba(73, 41, 112, 1)
    2021-12-15T14:05:55.368786382Z 2021-12-15T14:05:55.368Z - debug: Mapeo: rgba(145, 0, 0, 1)
    2021-12-15T14:05:55.369053596Z 2021-12-15T14:05:55.368Z - debug: Mapeo: rgba(13, 35, 58, 1)
    2021-12-15T14:05:55.369664628Z 2021-12-15T14:05:55.369Z - debug: Mapeo: undefined
    2021-12-15T14:05:55.369934842Z 2021-12-15T14:05:55.369Z - debug: Mapeo: undefined
    2021-12-15T14:05:55.370187156Z 2021-12-15T14:05:55.369Z - debug: Mapeo: undefined
    2021-12-15T14:05:55.370779687Z 2021-12-15T14:05:55.370Z - debug: Mapeo: undefined
    2021-12-15T14:05:55.742789712Z 2021-12-15T14:05:55.742Z - debug: Mapeo: undefined
    2021-12-15T14:05:55.745238641Z 2021-12-15T14:05:55.742Z - debug: Mapeo: undefined
    2021-12-15T14:05:55.758101816Z 2021-12-15T14:05:55.757Z - debug: Base url not specified, skipping its injection.
    2021-12-15T14:05:55.839772803Z 2021-12-15T14:05:55.839Z - debug: Replaced assets ["/modules/estadisticas/css/estadisticas.css","Logo_Wiga.png"]
    2021-12-15T14:05:55.842370539Z 2021-12-15T14:05:55.842Z - debug: Replaced assets ["Logo_Wiga.png"]
    2021-12-15T14:05:55.846050232Z 2021-12-15T14:05:55.845Z - debug: Rendering engine handlebars using http-server strategy
    2021-12-15T14:05:56.141703150Z 2021-12-15T14:05:56.141Z - debug: Taking compiled template from engine cache

    2021-12-15T14:05:56.261464136Z 2021-12-15T14:05:56.261Z - debug: Executing recipe chrome-pdf
    2021-12-15T14:05:56.769061778Z 2021-12-15T14:05:56.768Z - debug: Converting with chrome HeadlessChrome/79.0.3945.130 using dedicated-process strategy
    2021-12-15T14:05:57.159186955Z 2021-12-15T14:05:57.158Z - debug: Page request: GET (document) file:///tmp/jsreport/autocleanup/ff483549-9e22-498e-bd51-3f4b7a9d8a2b-chrome-pdf.html

    2021-12-15T14:05:58.155160030Z 2021-12-15T14:05:58.154Z - debug: Page request: GET (stylesheet) https://fonts.googleapis.com/css?family=Poppins:400,500i&display=swap
    2021-12-15T14:05:58.158646413Z 2021-12-15T14:05:58.158Z - debug: Page request: GET (script) https://code.jquery.com/jquery-3.1.1.min.js
    2021-12-15T14:05:58.159430054Z 2021-12-15T14:05:58.159Z - debug: Page request: GET (script) https://code.highcharts.com/stock/highstock.js
    2021-12-15T14:05:58.160232396Z 2021-12-15T14:05:58.159Z - debug: Page request: GET (script) https://code.highcharts.com/highcharts-more.js
    2021-12-15T14:05:58.162839933Z 2021-12-15T14:05:58.162Z - debug: Page request: GET (script) https://code.highcharts.com/stock/modules/exporting.js
    2021-12-15T14:05:58.163656576Z 2021-12-15T14:05:58.163Z - debug: Page request: GET (script) https://code.highcharts.com/stock/modules/export-data.js
    2021-12-15T14:05:58.169970608Z 2021-12-15T14:05:58.169Z - debug: Page request finished: GET (document) file:///tmp/jsreport/autocleanup/ff483549-9e22-498e-bd51-3f4b7a9d8a2b-chrome-pdf.html
    2021-12-15T14:05:58.171296277Z 2021-12-15T14:05:58.170Z - debug: Page request finished: GET (stylesheet) 200 https://fonts.googleapis.com/css?family=Poppins:400,500i&display=swap
    2021-12-15T14:05:58.172308630Z 2021-12-15T14:05:58.171Z - debug: Page request finished: GET (script) 200 https://code.jquery.com/jquery-3.1.1.min.js
    2021-12-15T14:05:58.174831463Z 2021-12-15T14:05:58.174Z - debug: Page request finished: GET (script) 200 https://code.highcharts.com/stock/modules/exporting.js
    2021-12-15T14:05:58.175874517Z 2021-12-15T14:05:58.175Z - debug: Page request finished: GET (script) 200 https://code.highcharts.com/stock/modules/export-data.js
    2021-12-15T14:05:58.177728915Z 2021-12-15T14:05:58.177Z - debug: Page request finished: GET (script) 200 https://code.highcharts.com/highcharts-more.js
    2021-12-15T14:05:58.179986933Z 2021-12-15T14:05:58.179Z - debug: Page request finished: GET (script) 200 https://code.highcharts.com/stock/highstock.js

    2021-12-15T14:06:02.588937685Z 2021-12-15T14:06:02.577Z - debug: Report stored as 5nrizoLLPtzyP5a9.pdf
    2021-12-15T14:06:02.597755656Z 2021-12-15T14:06:02.591Z - debug: Executing script anonymous using http-server strategy
    2021-12-15T14:06:03.175141496Z 2021-12-15T14:06:03.174Z - info: Rendering request 16 finished in 131644 ms
    2021-12-15T14:06:03.190270905Z 2021-12-15T14:06:03.190Z - debug: Processing schedule 7942bef4-c36b-4394-8500-295b856b70ff succeeded.



  • Thank you, this is really suspicious:

    2021-12-15T14:05:34.350837088Z 2021-12-15T14:05:34.350Z - debug: Processing schedule efcfc49e-f070-4aa7-ab7d-c7d1ccb0e78a succeeded.
    2021-12-15T14:05:34.350837088Z 2021-12-15T14:05:34.350Z - debug: Processing schedule efcfc49e-f070-4aa7-ab7d-c7d1ccb0e78a succeeded.

    How do you persist the entities? Are you using the default fs store with a mapped disk? Or a full database?
    It would probably help me a lot if you would email me your data backup.



  • yes, I'm using the default fs store


Log in to reply
 

Looks like your connection to jsreport forum was lost, please wait while we try to reconnect.