RPC with Delphi server and Java client using RabbitMQ (part 2 of 2)

This article shows the code for a Delphi server which receives a RPC call message from the inbound RabbitMQ request queue, and sends the response message back to the Java client. It is the mirror code for the previous article.

Continue reading

RPC with Delphi client and Java server using RabbitMQ (part 1 of 2)

The RabbitMQ online tutorial Remote procedure call (RPC) – using the Java client demonstrates how RPC can be implemented between a Java client and a Java server process, communicating over the RabbitMQ open source message broker.

But access to the RPC server process is not limited to Java applications – Delphi and Free Pascal applications using the Habari Client for RabbitMQ library can invoke the server process method too.

This article shows the code for a Delphi client which sends a RPC call message to the inbound RabbitMQ request queue, and receives the response message over a temporary queue, which exists only for the duration of the connection.

Continue reading

A Delphi REST client API open source library

Fabricio Colombo created a Delphi REST client API to consume REST services written in any programming language on Github. It supports two implementations, using Indy 10 and WinHTTP.The API was tested in Delphi 7, XE, XE2 and XE3.

The library uses JSON serialization to and from Delphi objects and supports Generics. This allows to perform complex REST commands with little code, for example a GET which retrieves a TPerson object list:


var
  vList : TList<TPerson>;
begin
  vList := RestClient.Resource('http://localhost:8080/java-rest-server/rest/persons')
                     .Accept(RestUtils.MediaType_Json)
                     .Get<TList<TPerson>>();

Habari Client for OpenMQ 2.5a1 released

May 7, 2013 – Habarisoft is pleased to announce release 2.5a1 of its
Delphi and Free Pascal client library for the Open MQ open source
message broker (http://mq.java.net/).

This is the first alpha of release 2.5, which introduces support for
Indy 10.6 and has been tested with build 14 of Open MQ 5.0, the
next-generation message broker version which implements JMS 2.0
(introduced with the new Java EE 7.0 specification). Continue reading

RabbitMQ 3.1.0 message broker released

The RabbitMQ team announced the release of RabbitMQ 3.1.0 – This release introduces eager synchronisation of mirror queue slaves, automatic cluster partition healing, and improved statistics (including charts) in the management plugin. It also adds many smaller new features, bug fixes and performance improvements.
The developers encourage all users of earlier versions of RabbitMQ to upgrade to this latest release.

For Delphi and Free Pascal, Habarisoft offers a client library for RabbitMQ 2.8.7 and newer.

HornetQ 2.3.0.Final released

JBoss Community has released the final release of HornetQ 2.3.0. This includes new features such as replication, multiple backups, multiple failover, fallback and STOMP 1.2 support as well as many other enhancements, fixes and performance tweaks.

A STOMP based Delphi and Free Pascal client library for HornetQ is available from Habarisoft.

XE4: Changes in the Delphi language for ARM and mobile

In his blog postChanges in the Delphi language for ARM and mobile support“, Tim Anderson summarizes some of the biggest language changes in the “next generation” compiler for mobile development in RAD Studio XE4, based on the paper “The Delphi Language for Mobile Development“, which you can find here. The changes include limitation to only one string type (UTF16), zero-based strings, automatic reference counting and the announced deprecation of the with statement.

Indy 10.6 support in Habari Web Components 2.4a1

The first alpha release of Habari Web Components 2.4 with support for Internet Direct (Indy) 10.6 will be available for registered users in the next days. The demo applications are already built with revision 5002 of the Indy 10.6 library, which also includes new fixes for Delphi 6 and Free Pascal 2.6

Habari Web Components 2.3 Released

Habari Web Components is a web application framework for small to medium size HTTP services, based on the popular open source TCP/IP library for Delphi and Free Pascal, Internet Direct (Indy). The new release brings many minor and major improvements. Here is a short overview:

  • new: exception stack trace logging
    • exceptions during request execution (Service method) will be logged with stack trace and do not stop the application
    • the stack trace will also be shown as web page content
    • this feature requires madExcept (Delphi only)
  • new: example class TdjNCSALogHandler implements the standardized NCSA log format
  • new: example project which shows how web resources can be protected using HTTP Basic Authentication, by adding a simple subclass of TdjHandlerWrapper to the request handler chain
  • changed: if an unhandled exception occurs during execution of a web components Service method, the HTTP response code will be set to 500 Internal Server Error
  • updated: demo applications updated to use jQuery 1.9.1 and Twitter Bootstrap 2.3.1
  • fixed: duplication of logger names in Log4D trace level log messages
  • fixed: Ajax request statistics demo – fixed hang on some browser caused by caching of JSON responses
  • experimental code for RESTful applications has been removed
  • experimental code for WebSocket applications has been removed

Habari Web Components

Continue reading