Habari Client libraries release 2020.06

Habarisoft released version 2020.06 of its Object Pascal STOMP client libraries for Delphi and Free Pascal integration with popular free open source message brokers.

What’s new

  • Tested with Indy 10.6.2, Delphi 2009, Lazarus 2.0.4 / Free Pascal 3.0.4
  • Support advisory message transformation header ‘jms-advisory-json’ (ActiveMQ only)
  • Added a basic example for advisory message receive (ActiveMQ only)
  • Changed Stomp destination prefixes to /queue and /topic (for details please see the ‘Getting Started’ PDF) (ActiveMQ Artemis)

20 % discount

You may purchase licenses now with a 20 % discount – use code habari062020delphi in the order form. This special offer is limited until 18 July 2020. Existing license holders with expired access to updates qualify for up to 30 % discount. Offer may not be combined with any other coupons, discounts, offers, or promotions.

About Habari Client libraries

habari_logo_2016Habari Client libraries enable Object Pascal applications to take advantage of message broker / message queue technology – which is distributed, loosely coupled, reliable and asynchronous – to build integrated systems, using peer-to-peer and publish-subscribe communication models.

Lazarus 2.0.8 released

The Lazarus team announced the release of Lazarus 2.0.8.

Here is the list of changes for Lazarus and Free Pascal:
http://wiki.lazarus.freepascal.org/Lazarus_2.0.0_release_notes
http://wiki.lazarus.freepascal.org/User_Changes_3.0.4

The release is available for download on SourceForge:
http://sourceforge.net/projects/lazarus/files/

About Lazarus IDE

Lazarus is a Delphi compatible cross-platform IDE for Rapid Application Development. It has variety of components ready for use and a graphical form designer to easily create complex graphical user interfaces.

Habari Client libraries release 2020.04

Habarisoft released the 2020.04 version of its Object Pascal STOMP client libraries for application integration with open source message brokers Apache ActiveMQ, Artemis, OpenMQ and RabbitMQ. The release includes

About Habari Client libraries

habari_logo_2016Habari Client libraries enable Object Pascal applications to take advantage of message broker / message queue technology – which is distributed, loosely coupled, reliable and asynchronous – to build integrated systems, using peer-to-peer and publish-subscribe communication models.

Habari Client libraries release 2019.12

Habarisoft released the 2019.12 version of its Object Pascal STOMP client libraries for application integration with open source message brokers Apache ActiveMQ, Artemis, OpenMQ and RabbitMQ. The release includes

About Habari Client libraries

habari_logo_2016Habari Client libraries enable Object Pascal applications to take advantage of message broker / message queue technology – which is distributed, loosely coupled, reliable and asynchronous – to build integrated systems, using peer-to-peer and publish-subscribe communication models.

Habari Client library for RabbitMQ patch version available

A download which includes two patches for Habari Client for RabbitMQ is now available. The patches are:

  1. configuration support for extra headers of NACK frames
  2. fix for failover URLs containing heart-beat parameters

Configuration of extra headers for NACK

The RabbitMQ message broker supports a special STOMP header for the NACK frame, requeue. By default, a NACKed message will be requeued. By setting the requeue header to false, the NACKed message will be discarded/dead lettered by the message broker (for more details see https://www.rabbitmq.com/stomp.html).

The patch version contains a new interface, IFrameOptionsProvider, which contains the SetNackHeaders method.

Code Example:

uses
  BTMsgInterfaces, ...
...
NackHeaders := TStringList.Create;
try
  NackHeaders.Add('requeue=false');
  (Msg as IFrameOptionsProvider).SetNackHeaders(NackHeaders);
finally
  NackHeaders.Free;
end;

Fix for failover URLs containing heart-beat parameters

A failover URL may contain heart-beat configuration (for example heart-beat=0,60000). A bug in the current version has been fixed which splits the URL in the wrong position.

Example:

failover:(stomp://host-a?connect.heart-beat=0,60000&connect.host=myvhost,stomp://host-b?connect.heart-beat=0,60000&connect.host=myvhost) 

The patched version correctly splits up the URLs into these two parts:

stomp://host-a?connect.heart-beat=0,60000&connect.host=myvhost
stomp://host-b?connect.heart-beat=0,60000&connect.host=myvhost

Download

Registered users may download the patch version at https://www.habarisoft.com/habari_rabbitmq/download/snapshot/

Habari Client libraries release 2019.08

Habarisoft released the 2019.08 version of its Object Pascal STOMP client libraries for application integration with open source message brokers Apache ActiveMQ, Artemis, OpenMQ and RabbitMQ. The release includes

About Habari Client libraries

habari_logo_2016Habari Client libraries enable Object Pascal applications to take advantage of message broker / message queue technology – which is distributed, loosely coupled, reliable and asynchronous – to build integrated systems, using peer-to-peer and publish-subscribe communication models.

How to: Let’s Encrypt certificates with Indy HTTP Server

This article guides you through the setup for a simple HTTPS server using Let’s Encrypt certificates.

Download the project source

The example project is included in the Daraja demo folder at https://github.com/michaelJustin/daraja-framework/tree/master/demo/https. You may use the project IndyHttpsTest with Delphi 6 or later, or with the Lazarus IDE. This stand-alone project only requires the Indy library, it does not depend on the Daraja HTTP framework.
Three lines in the project specifiy the domain certificate, the domain certificate key and the intermediate certificate:

...

IOHandler := TIdServerIOHandlerSSLOpenSSL.Create;
IOHandler.SSLOptions.CertFile := 'cert.pem';  // domain certificate
IOHandler.SSLOptions.KeyFile := 'key.pem';  // domain key
IOHandler.SSLOptions.RootCertFile := 'cacert.pem'; // intermediate certificate
IOHandler.SSLOptions.Mode := sslmServer;

...

Install the OpenSSL DLLs

The OpenSSL libraries can be downloaded from https://indy.fulgan.com/SSL/ (note that there are different versions for 32 and 64 bit applications). Extract the archive and copy the DLLs to the daraja-framework\demo\https folder.

Intermediate certificate

Let’s Encrypt uses an intermediate certificate which is available for download at https://letsencrypt.org/certificates/

From the Intermediate Certificates section, download the active intermediate certificate, copy it to the daraja-framework\demo\https folder, and rename it to cacert.pem

Server certificate and key

Now you need your server certificate and key files. An easy way to do this is the free ‘SSL Certificate Wizard‘ at https://zerossl.com/ – this service allows to create Let’s Encrypt certificates for your web domain.

Domain verification

Before you can download server certificate and key, the ZeroSSL certificate wizard must verify that the domain is under your control. Verification options are HTTP or DNS based. To verify domain ownership using HTTP verification, you will need to create appropriate files with specific text strings under your “<webroot>/.well-known/acme-challenge/” directory. Only after ZeroSSL checked these files, your certificate will be issued.

Finally, you need to download the files domain-crt.txt and domain-key.txt from the last page of the SSL Certificate Wizard.

Certificate installation

Copy the files domain-crt.txt and domain-key.txt to the project daraja-framework\demo\https folder with the names cert.pem and key.pem

Ready to launch

Verify the certificate chain

You may inspect the certificate properties in Windows if you copy or rename domain-crt.txt to domain.crt and double-click to open it. The certificate information window willl show the certificate properties (validity period etc.) and the certification chain:

Local test

Compile and start the IndyHttpsTest project in the folder daraja-framework\demo\https. The program will launch your default web browser and navigate to https://127.0.0.1. As the certificate is not issued for 127.0.0.1, the browser will display a security warning which displays the name mismatch.

Only if the server runs on the web server which the certificate has been issued for, browsers will accept the certificate without warnings.

Disclaimer

Please understand that this how to guide is only meant to be a short introduction into SSL/TLS certificate usage and you should always be aware of potential security risks.

Daraja HTTP Framework 2.0 released

dj

The Daraja HTTP Framework is a free open source library for Object Pascal (Free Pascal 3.0.4, Delphi 2009+), based on the stand-alone HTTP server component in Internet Direct (Indy).

The 2.0 release uses const parameters in the Handle method of the IHandler interface and its implementing classes.

old:
- procedure Handle(Target: string; Context: TdjServerContext; Request:
- TdjRequest; Response: TdjResponse);

new:
+ procedure Handle(const Target: string; Context: TdjServerContext; Request:
+ TdjRequest; Response: TdjResponse);

Note: this is a breaking change for code which declares custom handler implementations. Such code must now use a const parameter.

“Using const allows the compiler to optimize code for structured – and string-type parameters. It also provides a safeguard against unintentionally passing a parameter by reference to another routine.”

More information

– GitHub: https://github.com/michaelJustin/daraja-framework
– API documentation: https://michaeljustin.github.io/daraja-framework/
– Resources: https://www.habarisoft.com/daraja_framework.html
– Wiki: https://github.com/michaelJustin/daraja-framework/wiki

Habari Client libraries release 2019.06

Habarisoft released the 2019.06 version of its Object Pascal STOMP client libraries for application integration with open source message brokers Apache ActiveMQ, Artemis, OpenMQ and RabbitMQ. The release includes

About Habari Client libraries

habari_logo_2016Habari Client libraries enable Object Pascal applications to take advantage of message broker / message queue technology – which is distributed, loosely coupled, reliable and asynchronous – to build integrated systems, using peer-to-peer and publish-subscribe communication models.