Developer forum

Forum » Development » Replace ImageGlue with MagicScaler

Replace ImageGlue with MagicScaler

Imar Spaanjaars Dynamicweb Employee
Imar Spaanjaars
Reply

Hi there,

I am trying to replace ImageGlue with MagicScaler. I can successfully add the package Dynamicweb.Imaging.Providers.MagicScalerProviders to my solution. When I then build my project and manually delete Dynamicweb.Imaging.Providers.ImageGlueProviders my images work fine. I think this proves that the system then uses MagicScaler instead of ImageGlue which is great.

I then tried to uninstall ImageGlue completely but was greeted by the following error:

 

This leads to two questions:

  1. When I have both providers in my Bin folder, which one does Dynamicweb pick? When I have both, could it still be running on ImageGlue?
  2. How do I get rid of ImageGlue? The main reason to switch to MagicScaler is that we're experiencing file locks with ImageGlue during automated builds. However, when I don't uninstall the package, I get the file back on every build.

Thanks!

Imar

 


Replies

 
Nicolai Pedersen
Reply
This post has been marked as an answer

Hi Imar

The dependency is there so the provider gets distributed with the appplication automatically. So you can only do /bin folder replacement

If they are both there, the first one in the folder will be used. Probably imageglue.

BR Nicolai

Votes for this answer: 1
 
Anders Ebdrup
Anders Ebdrup
Reply

Dear Nicolai,

 

So in a nuget setup this will not work? When do you expect to have ImageGlue phased out?

 

Best regards, Anders

 
Nicolai Pedersen
Reply

It will not work in a nuget setup without some hardcoding in the deployment. Or we change the Admin package which might give some other issues.

ImageGlue will phase out with DW10 as things stand now.

BR Nicolai

 
Imar Spaanjaars Dynamicweb Employee
Imar Spaanjaars
Reply

I solved it by deleting imageglue*.dll during the automated deployment. That deletes the files before the site starts up, so locking is not an issue there.

Imar

 
Nuno Aguiar Dynamicweb Employee
Nuno Aguiar
Reply

Hi Imar,

 

Do you remember if this was all you did? I tried to follow your steps, but get a YSOD (attached). Here's what I did:

 

Do you know of any additional steps needed?

 

Best Regards,

Nuno Aguiar

2022-08-29_14-03-40.jpg
 
Imar Spaanjaars Dynamicweb Employee
Imar Spaanjaars
Reply

Did you install the package using Visual Studio? I think it adds some additional references to the web.config as well as additional assemblies.

Imar

 

 
Nuno Aguiar Dynamicweb Employee
Nuno Aguiar
Reply

HI Imar,

 

I did not. I was just trying to swap it out in a solution after getting some concerns/complaints that ImageGlue is slow. Do you happen to have a web.config for me to compare against? I will try the VS approach tomorrow.

 

I did try a few more things though

 

  • Getting v1.01 from Dynamicweb's Provider for MagicScaler (built for .net 472) and the latest PhotoSauce.MagicScaler (v0.13.1) gives me the YSOD from above
  • Getting PhotoSauce.MagicScaler v0.10.3 (from YSOD) gets me a YSOD for System.Buffers v4.0.2 - and DW's ships with 4.6
  • I tried to add the assemblydependency for System.Buffers in web.config to see if that helped without any luck

 

Best Regards,

Nuno Aguiar

 
Imar Spaanjaars Dynamicweb Employee
Imar Spaanjaars
Reply

The one I have is for an older project so the differences between mine and yours may be unrelated. So it would be simpler to install a copy using NuGet into your own project.

 
Nuno Aguiar Dynamicweb Employee
Nuno Aguiar
Reply

Hi Imar,

 

Yeah, I tried that and there was nothing added to web.config with any of the dependency settings (Ignore dependencies, lowest, highest). EIther I'm missing something really simple, or this is not working since Dynamicweb made the latest upgrade (after your initial post). I'll spend more time on this tomorrow and if I come up with nothing again, I'll bug someone else :)

 

Thanks,

Nuno Aguiar

 
Imar Spaanjaars Dynamicweb Employee
Imar Spaanjaars
Reply

Happy to have a call with you and check this out. Heading out now for a bit but find me on Teams or so and we can schedule something.

 
Nuno Aguiar Dynamicweb Employee
Nuno Aguiar
Reply

Hi Imar,

 

Thank you for your offer. I got it to work after Scott helped me figure out the right version. The misleading version you get from right-clicking the file (dll) versus the actual version and publicToken using Powershell.

 

Here's my update if you are curious http://doc.dynamicweb.com/forum?ThreadID=83584&PID=1605

 

BTW, hope to see you in Denmark ;)

Best Regards,

Nuno Aguiar

 
Imar Spaanjaars Dynamicweb Employee
Imar Spaanjaars
Reply

Glad you got it working. See you next week.

Imar

 

You must be logged in to post in the forum