We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
#321 #326 #337
The text was updated successfully, but these errors were encountered:
public void RunImageProcessQueue() { var factory = new ConnectionFactory() { HostName = "localhost" }; using (var connection = factory.CreateConnection()) using (var channel = connection.CreateModel()) { channel.QueueDeclare(queue: QueueName.ImageResizeProcessing.ToString(), durable: true, exclusive: false, autoDelete: false, arguments: null); //Fair dispatch setup channel.BasicQos(prefetchSize: 0, prefetchCount: 1, global: false); Console.WriteLine(" [*] Waiting for messages."); var consumer = new EventingBasicConsumer(channel); consumer.Received += (model, ea) => { var body = ea.Body; var assetMessage = Encoding.UTF8.GetString(body); Console.WriteLine(" [x] Received {0}", assetMessage); var imageName = assetMessage.Split("\\")[1]; var s = ProjectPath.ToApplicationPath(imageName); var assetPath = $"{ProjectPath.GetApplicationRoot()}\\wwwroot\\{assetMessage}"; var path = "D:\\SourceCode\\Awesome-CMS-Core\\src\\AwesomeCMSCore\\AwesomeCMSCore"; using (var image = Image.Load(path)) { image.Mutate(x => x .Resize(295, 205) .Grayscale()); image.Save(imageName); } channel.BasicAck(deliveryTag: ea.DeliveryTag, multiple: false); }; channel.BasicConsume(queue: QueueName.ImageResizeProcessing.ToString(), autoAck: false, consumer: consumer); Console.WriteLine(" Press [enter] to exit."); Console.ReadLine(); }
Still can't resize eventhough I can load it cc @AbelianKraun
Sorry, something went wrong.
I will check this ASAP when I have time, I'm still configuring the environment.
ngohungphuc
No branches or pull requests
#321
#326
#337
The text was updated successfully, but these errors were encountered: