Logo
My Account |  Site Map | Contact Us  
Welcome Guest Search | Active Topics | Sign In | Register

dotnet core 3.0 support Options
Rabobank Support
Posted: Tuesday, November 19, 2019 7:02:54 AM
Rank: Newbie
Groups: Member

Joined: 10/20/2014
Posts: 9
Hi team,

We recently upgraded to dotnet core 3.0 and are using eo.pdf from an core mvc application.

However the application crashes on the line: HtmlToPdf.ConvertUrl with the error message: : 'Failed to start image manager'

The same call is fine using dotnet core 2.2

Can you tell us if you are supporting dotnet core 3.0 , or what could be wrong ?

Kind regards,

Niels Kleizen
eo_support
Posted: Tuesday, November 19, 2019 11:30:06 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 21,737
Hi,

The current version should support .NET Core 3.0 (on Windows only). What version of our product are you using?

Thanks!
Rabobank Support
Posted: Tuesday, November 19, 2019 11:46:29 AM
Rank: Newbie
Groups: Member

Joined: 10/20/2014
Posts: 9
Hi, the latest from NuGet 19.2.91, From Windows 10





System.Exception
HResult=0x80131500
Message=Failed to start image manager
Source=EO.Base
StackTrace:
at EO.Internal.i3.k.b()
at EO.Internal.i3.k.e()
at EO.Internal.i3.p()
at EO.Internal.i3.a(Boolean& A_0, axv[] A_1, String A_2, String A_3)
at EO.Internal.i3.a(axv[] A_0, String A_1, String A_2)
at EO.Internal.at6.b()
at EO.Internal.at6.a.a()
at EO.Internal.pf.a(Action A_0)
at EO.Internal.at6.a(WindowsIdentity A_0)
at EO.WebEngine.Engine.Start(WindowsIdentity user)
at EO.Internal.ru.b()
at EO.Internal.mw.a(ru& A_0)
at EO.Internal.aj9.a(at A_0, ru& A_1)
at EO.Internal.ob.e()
at EO.Internal.ob..ctor(at A_0, HtmlToPdfOptions A_1)
at EO.Pdf.HtmlToPdfSession.a(HtmlToPdfOptions A_0)
at EO.Pdf.HtmlToPdfSession..ctor(HtmlToPdfOptions A_0, HtmlToPdfSession A_1)
at EO.Pdf.HtmlToPdf.b.a()
at EO.Internal.aj9.a[a](aox A_0)
at EO.Pdf.HtmlToPdf.ConvertUrl(String url, PdfDocument doc, HtmlToPdfOptions options)
at Web.Linking.Controllers.DocumentController.<>c__DisplayClass9_1.<GetAllDocumentGenerationTasks>b__2() in C:\Projects\LinkingTool\Code\Web\Controllers\DocumentController.cs:line 173
eo_support
Posted: Thursday, November 21, 2019 3:30:26 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 21,737
Hi,

We tested this with .NET Core 3.0 and we did not see any problem. So this issue should be caused by something else, not .NET Core version. You can try to enable EO Worker process and see if it works for you:

https://www.essentialobjects.com/doc/common/eowp.aspx

For a web application, you should try these steps:

1. Manually place eowp.exe somewhere on your server. For example, inside "eo" in your root directory. Try not to place it inside your bin directory;
2. Make sure the IIS account under which your application runs have execute permission on that directory;
3. Call EO.Base.Runtime.InitWorkerProcessExecutable with the above path;

After that run the page again and check your task manager to see eowp.exe has been sucessfully started.

Thanks!
Rabobank Support
Posted: Friday, November 22, 2019 8:06:35 AM
Rank: Newbie
Groups: Member

Joined: 10/20/2014
Posts: 9
Thanks for your reply and testing, I will work further on what could be wrong then. One more question, do you know if this is required in the project file:

<TargetFrameworks>netcoreapp3.0;net461</TargetFrameworks>

Or that it can work with just netcoreapp (I assumed it would work with only targetting netcoreapp)
eo_support
Posted: Friday, November 22, 2019 12:30:23 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 21,737
Hi,

It will work fine with just netcoreapp3.0. However it will still only run on Windows.

Thanks!
Rabobank Support
Posted: Sunday, November 24, 2019 3:16:35 PM
Rank: Newbie
Groups: Member

Joined: 10/20/2014
Posts: 9
Is it possible to share the project in which you got it running (in dotnet 3.0)? Because I keep having the same error (which is impossible to debug). Maybe I can locate the difference.

Kind regards, Niels Kleizen

Edit:

Actually I have created the smallest test project I could create, and it fails there with the same error. I can provide you that code too. (if you give me an address I can send it to)
eo_support
Posted: Monday, November 25, 2019 10:26:49 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 21,737
Hi,

This is most likely related to your environment, not your code. There is something on your system that prevented EO.Pdf from creating child process. Usually turnning EO worker process on would resolve such issue for you. So please make sure you get that working first. If you have any questions or problems on this step, feel free to let us and we will be happy to troubleshoot further with you.

For your reference, here are the steps we tested:

1. Start Visual Studio 2019;
2. Create a new ASP.NET Core MVC project (C#);
3. Add reference to our DLLs (EO.Base.dll, EO.Pdf.dll, EO.WebEngine.dll and EO.WebBrowser.dll);
4. Inside Index() in HomeController.cs add the following code:

Code: C#
EO.Pdf.PdfDocument doc = new EO.Pdf.PdfDocument();
EO.Pdf.HtmlToPdf.ConvertHtml("test", doc);


We then run the code and it did not have any problem.

Alternatively, if you can set up a bare minimum test application and provide remote access to us to the test system, we can connect to it and see what we can find.

Thanks!
Rabobank Support
Posted: Tuesday, November 26, 2019 8:41:56 AM
Rank: Newbie
Groups: Member

Joined: 10/20/2014
Posts: 9
Thank you, the solution of the turning on the EO worker process worked for me.
However I do have doubts about my environment killing the process, because in dotnet core 2.2 I don't have any issues.

But I can continue with the worker process.

Kind regards, Niels Kleizen
eo_support
Posted: Tuesday, November 26, 2019 11:51:49 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 21,737
Hi,

As we mentioned earlier, we do not think this has anything to do with .NET Core version. It's just a coincident that it stopped working after you updated .NET Core version. Something else must have also changed on your system that triggered the problem. EO Worker process is the solution for that problem, but it has nothing to do with .NET Core version.

Thanks!


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.