OK then, I've just updated my web app. So far so good. That warning disappeared, and the build time is acceptable now.
Thank you so much for your cooperation!
phobos04
@phobos04
Posts made by phobos04
-
RE: .NET Core 3.1 support
-
RE: .NET Core 3.1 support
No, no errors. Only analyzer warnings due to mixing references to both .net core 3.1 and 2.2, and increased build time. I don't know whether it's related to the mixing references, but I'm trying to fix them anayway.
I've seen that in the references node of my Visual Studio Solution. More precisely,
jsreport.AspNetCore v. 2.0.2
is apparently referencing bothMicrosoft.AspNetCore.Http v.2.2.2
andMicrosoft.AspNetCore.Mvc v.2.2.0
packages.
Here's a screenshot of the references.The solution has been migrated to .NET Core 3.1 following the Microsoft Migration guide.
Thank you.
Best regards,
Matteo -
.NET Core 3.1 support
Hi,
I'm migraging an Asp.Net core web app to .NET Core 3.1. While checking the dependencies I've seen thatjsreport.AspNetCore v. 2.0.2
still targets .NET Core 2.2.
Please, do you have any plan on upgrading to 3.1?Thank you so much,
best regards.
Matteo -
Header and Footer management
Hi all,
I'm trying to build an invoice report in an asp.net core 2.2 web app using jsreport 2.6.2-beta2 with the Chrome recipe and razor views for the header, body and footer sections.
I've managed to correctly repeat the header template on each page.
Regarding the footer section, I'd like to display on the last page only, at the bottom of the page. Please, is there a way to show the footer template at the bottom of the last page only?
Thank you. -
RE: HPE_HEADER_OVERFLOW error with jsreport.binary > 2.5.0 (works fine with 2.5.0)
Thank you for the reply. Please, do you have any estimated release date for the jsreport.Binary@2.6.2-beta2 package?
-
HPE_HEADER_OVERFLOW error with jsreport.binary > 2.5.0 (works fine with 2.5.0)
Hi all.
I was facing the problem described in the Reosurce busy or locked post on a production instance of a .net Core 2.2 web app. I then tried to upgrade jsreport.binary from
v. 2.5.0
tov. 2.6.2-beta
to solve that issue on the production server. After the upgrade jsreport stopped generating any report on the dev machine (which was working correctly before the upgrade).
The report is configured to build a PDF through theChrome
recipe using a razor view. Using the older jsreport allows me to successfully generate and download the PDF file. After upgrading to v.2.6.2-beta
jsreport aHPE_HEADER_OVERFLOW
error.Here's the raw exception details:
jsreport.Local.JsReportBinaryException: Error rendering report: rendering has finished with errors:A critical error occurred while trying to execute the render command: Parse Error (1). caused by error (1) -> meta = {"bytesParsed":65536,"code":"HPE_HEADER_OVERFLOW","disableExit":false}, stack = Error: at Socket.socketOnData (_http_client.js:442:20) at Socket.emit (events.js:189:13) at addChunk (_stream_readable.js:284:12) at readableAddChunk (_stream_readable.js:265:11) at Socket.Readable.push (_stream_readable.js:220:10) at TCP.onStreamRead (internal/stream_base_commons.js:94:17) at jsreport.Local.Internal.LocalUtilityReportingService.RenderAsync(String requestString, CancellationToken ct) at jsreport.AspNetCore.JsReportMiddleware.Invoke(HttpContext context) at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.InvokeNextResourceFilter() at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.Rethrow(ResourceExecutedContext context) at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.Next(State& next, Scope& scope, Object& state, Boolean& isCompleted) at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.InvokeFilterPipelineAsync() at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.InvokeAsync() at Microsoft.AspNetCore.Routing.EndpointMiddleware.Invoke(HttpContext httpContext) at Microsoft.AspNetCore.Routing.EndpointRoutingMiddleware.Invoke(HttpContext httpContext) at Microsoft.AspNetCore.Builder.RouterMiddleware.Invoke(HttpContext httpContext) at Microsoft.AspNetCore.Builder.Extensions.MapMiddleware.Invoke(HttpContext context) at Microsoft.AspNetCore.StaticFiles.StaticFileMiddleware.Invoke(HttpContext context) at Microsoft.AspNetCore.StaticFiles.StaticFileMiddleware.Invoke(HttpContext context) at DC.Web.ProtectFolder.Invoke(HttpContext httpContext, IAuthorizationService authorizationService) in D:\Progetti\Web\NetCore\DentalCare\DC.Web\Middleware\Authorization\StaticFiles\ProtectFolderMiddleware.cs:line 37 at Microsoft.AspNetCore.ResponseCompression.ResponseCompressionMiddleware.Invoke(HttpContext context) at Microsoft.AspNetCore.Authentication.AuthenticationMiddleware.Invoke(HttpContext context) at Microsoft.AspNetCore.Diagnostics.EntityFrameworkCore.MigrationsEndPointMiddleware.Invoke(HttpContext context) at Microsoft.AspNetCore.Diagnostics.EntityFrameworkCore.DatabaseErrorPageMiddleware.Invoke(HttpContext httpContext) at Microsoft.AspNetCore.Diagnostics.EntityFrameworkCore.DatabaseErrorPageMiddleware.Invoke(HttpContext httpContext) at Microsoft.AspNetCore.Diagnostics.DeveloperExceptionPageMiddleware.Invoke(HttpContext context)
The Request header length is around 13kB.
Please is the error related to the node.js max header length default value of 8kB, as per node.js specs? I'f I'm not mistaken, wasn't it 80kB in the previous node.js releases?
Is there anything I can do to solve this problem?The jsreport nuget packages are included as follows:
<PackageReference Include="jsreport.AspNetCore" Version="2.0.2" /> <PackageReference Include="jsreport.Binary" Version="2.6.2-beta" /> <PackageReference Include="jsreport.Local" Version="2.1.2" />
After some trial and error, the actual jsreport configuration is as follows:
services.AddJsReport(new LocalReporting() .UseBinary(JsReportBinary.GetBinary()) .KillRunningJsReportProcesses() .Configure(cfg=> { cfg.BaseUrlAsWorkingDirectory().AllowedLocalFilesAccess(); cfg.TempDirectory = Path.Combine(Directory.GetCurrentDirectory(), "jsreport", "temp"); return cfg; }) .AsUtility() .Create());
Thank you so much.
Regards! -
RE: Asp.Net Core - Render multiple PDFs and download zip
Hi. Thank you for your suggestion. It's not a priority for us at the moment, though I'll provide some sample as soon as possibile.
We're facing another very specific issue. We've deployed the web app with the working jsreport reporting feature to a production server. That specific server is locally reachable via a local domain like https://<appname>.studio.local
On that machine, none of the CSS is applied when we try to generate a PDF via jsreport. Please, what shoud we do to solve this problem? we have already tried to set the local domain in the Options.Base, without luck.
The same version of our web app runs fine both locally and on a publicly reachable server.
Thank you so much,
best regards. -
RE: Asp.Net Core - Render multiple PDFs and download zip
Hi.
Thank you for your suggestions.
The problem was not related to jsreports itself, but with some weird CSS behaviour.
I've simplified the CSS used in my reports, and jsreport started to work almost as expected again.The only thing I'm still struggling with is the
@import
directive within a CSS file. In particular, I'd like to import a specific font. No matter if use the@import
directive with local fonts or with remote ones, the report renders blank. This behavior is the same no matter if I use the jsreport middleware or the RenderViewAsync.
Please, do you have any suggestion about font management?Thank you so much.
-
RE: Asp.Net Core - Render multiple PDFs and download zip
Thank you for your suggestion.
I'm using jsreport as nuget packages. How can I reach the sources for putting the breakpoints?Thank you so much.
-
RE: Asp.Net Core - Render multiple PDFs and download zip
Hi,
thank you for your suggestion.
I was alerady trying to prepend the "base url" to my styles. I've now added that line of code in the initialization of my RenderViewAsync calls.
I have a different problem now: all the text within the body of my PDFs is gone. I've debugged the issue, and the view appears correctly fed with the model data. The table styling I'm using (e.g. a gray bottom border for each table line) is printed, but no text in the body of my PDFs.The same razor views are correctly rendered as standalone PDFs.
Please, do you have any other suggestion?Thank you so much.