30 hours agoPROTON-1991: [Python] Tornado example no longer works master
Andrew Stitcher [Thu, 20 Dec 2018 22:25:05 +0000 (17:25 -0500)] 
PROTON-1991: [Python] Tornado example no longer works
- Scheduler example seems to have bit rotted
- Small logic error in tornado examples

4 weeks agoPROTON-1984: Fix pn_data_inspect test to work on 32 bit machines!
Andrew Stitcher [Thu, 20 Dec 2018 17:14:06 +0000 (12:14 -0500)] 
PROTON-1984: Fix pn_data_inspect test to work on 32 bit machines!

4 weeks agoPROTON-1986: [Python] Make example broker work with anonymous links
Andrew Stitcher [Thu, 20 Dec 2018 03:56:26 +0000 (22:56 -0500)] 
PROTON-1986: [Python] Make example broker work with anonymous links
- If you receive a message on a link with no target address then use the message address

4 weeks agoPROTON-1985: [Python] Actually make default to listen forever
Andrew Stitcher [Thu, 20 Dec 2018 03:54:33 +0000 (22:54 -0500)] 
PROTON-1985: [Python] Actually make default to listen forever
- Bug in current behaviour such that default ends up throwing every message away

4 weeks agoPROTON-1984: [c] Avoid O(n^2) complexity in pn_data_inspect
Andrew Stitcher [Wed, 19 Dec 2018 19:45:26 +0000 (14:45 -0500)] 
PROTON-1984: [c] Avoid O(n^2) complexity in pn_data_inspect
- Rework original change to preserve correct stringifying of pn_data_t
- Unfortunately restores some potential O(n^2) behaviour but in many
  fewer cases.

This reverts commit 58ec2b1e54d00fce4a07b7c3c6de2b504b2525ee.

4 weeks agoPROTON-1984: Some tests for pn_data_inspect
Andrew Stitcher [Wed, 19 Dec 2018 19:42:55 +0000 (14:42 -0500)] 
PROTON-1984: Some tests for pn_data_inspect

4 weeks agoPROTON-985: [go] Go binding uses monotonic clock
Alan Conway [Tue, 18 Dec 2018 18:03:27 +0000 (13:03 -0500)] 
PROTON-985: [go] Go binding uses monotonic clock

Updated generated code for new pn_proton_tick() signature,
Updated binding to use monotonic time.

4 weeks agoPROTON-985: [go] Update pn_proton_tick() return type.
Alan Conway [Tue, 18 Dec 2018 18:03:00 +0000 (13:03 -0500)] 
PROTON-985: [go] Update pn_proton_tick() return type.

4 weeks agoPROTON-985: Modify pn_transport_tick to use a monotonic clock.
Alan Conway [Fri, 14 Dec 2018 19:02:37 +0000 (14:02 -0500)] 
PROTON-985: Modify pn_transport_tick to use a monotonic clock.

4 weeks agoPROTON-830: trivial README change, testing JIRA commit notifications and GitHub mirro...
Robbie Gemmell [Fri, 14 Dec 2018 11:05:50 +0000 (11:05 +0000)] 
PROTON-830: trivial README change, testing JIRA commit notifications and GitHub mirror after git-wip-us to gitbox migration, ignore.

5 weeks agoPROTON-1981: [cpp] timestamp::now returns wrong value.
Alan Conway [Wed, 12 Dec 2018 01:28:24 +0000 (20:28 -0500)] 
PROTON-1981: [cpp] timestamp::now returns wrong value.

Was returning pn_proactor_now() which is monotonic time, fixed to return
wall-clock time.

5 weeks agoPROTON-1982: C tests written in C++ fail to build if no C++ compiler
Alan Conway [Wed, 12 Dec 2018 00:38:05 +0000 (19:38 -0500)] 
PROTON-1982: C tests written in C++ fail to build if no C++ compiler

Some C library tests are now written in C++, they need to be skipped on platforms
with no C++ compiler rather than failing the build.

5 weeks agoPROTON-1979: [c] Only allow scalars (non compound types) as descriptors
Andrew Stitcher [Tue, 11 Dec 2018 19:53:35 +0000 (14:53 -0500)] 
PROTON-1979: [c] Only allow scalars (non compound types) as descriptors

5 weeks agoPROTON-1984: [c] Avoid O(n^2) complexity in pn_data_inspect
Andrew Stitcher [Tue, 11 Dec 2018 19:17:52 +0000 (14:17 -0500)] 
PROTON-1984: [c] Avoid O(n^2) complexity in pn_data_inspect

5 weeks agoPROTON-1983, PROTON-1805: Allow fuzzer regression tests to use response files
Andrew Stitcher [Fri, 7 Dec 2018 20:28:02 +0000 (15:28 -0500)] 
PROTON-1983, PROTON-1805: Allow fuzzer regression tests to use response files
- Fixed bugs which make the standalone regression runner fail on Windows and Mac
- Allow fuzz tests to build under VS12 & VS10

6 weeks agoPROTON-1979: [c] Forbid AMQP values that could lead to a nested descriptor type
Andrew Stitcher [Thu, 6 Dec 2018 19:45:47 +0000 (14:45 -0500)] 
PROTON-1979: [c] Forbid AMQP values that could lead to a nested descriptor type
- Any described type descriptors that could lead to a nested described type in the
  descriptor type itself are forbidden as these can lead to indefinite stack use.
- In any event only symbol and ulong are currently valid types for descriptors,
  all other types are reserved although syntactically valid (according to amqp 1.0).

Problem found by oss-fuzz: https://oss-fuzz.com/testcase?key=5920119225057280

6 weeks agoPROTON-1978: [c] Make disposition performative handling more efficient
Andrew Stitcher [Wed, 5 Dec 2018 18:12:50 +0000 (13:12 -0500)] 
PROTON-1978: [c] Make disposition performative handling more efficient
- Minimise the effort to update deliveries affected by the disposition
  If there are fewer deliveries outstanding than delivery ids in the
  performative then loop through them all to update them.
  Otherwise, loop through the specified delivery ids.
- We have to go through this effort as we don't keep the outstanding
  deliveries sorted by id. Instead they are in a hash table and in a
  separate linked list.

Problem found by oss-fuzz: https://oss-fuzz.com/testcase?key=5118747114209280

6 weeks agoNO_JIRA: [c] Fix minor proactor test bugs
Alan Conway [Tue, 4 Dec 2018 21:06:45 +0000 (16:06 -0500)] 
NO_JIRA: [c] Fix minor proactor test bugs

Some tests were listening on default AMQP port instead of port 0.
Improved idle-timeout logic for test proactor.

6 weeks agoPROTON-1959: [cpp] Binary compatible reconnect
Alan Conway [Fri, 30 Nov 2018 19:07:58 +0000 (14:07 -0500)] 
PROTON-1959: [cpp] Binary compatible reconnect

Previous commit f53c7683d7e90363 added new virtual functions to class
messaging_handler: on_connection_start() and on_connection_reconnecting()

This is a binary incompatible change in C++. Linking a new library that calls
these functions with old user code that doesn't implement them will crash.

Removed the new functions, fixed the implementation and user docs to accomplish
the same result using existing on_connection_open() and on_transport_error().

Fixes #170.

7 weeks agoPROTON-1974: Correctly detect libraries with earlier versions of CMake
vagrant [Thu, 29 Nov 2018 22:34:01 +0000 (22:34 +0000)] 
PROTON-1974: Correctly detect libraries with earlier versions of CMake

Patch-from: Jiri DanÄ›k

7 weeks agoPROTON-1973: Make proton_tests runnable as a module
Andrew Stitcher [Tue, 27 Nov 2018 20:42:20 +0000 (15:42 -0500)] 
PROTON-1973: Make proton_tests runnable as a module

8 weeks agoPROTON-1970: Allow proton-core to be compiled by msvc9
Andrew Stitcher [Wed, 21 Nov 2018 22:24:34 +0000 (17:24 -0500)] 
PROTON-1970: Allow proton-core to be compiled by msvc9
- This is needed to compile for python2.7 setup.py

8 weeks agoPROTON-1969: Explicitly use python to run the tox test
Andrew Stitcher [Wed, 21 Nov 2018 15:37:27 +0000 (10:37 -0500)] 
PROTON-1969: Explicitly use python to run the tox test

8 weeks agoPROTON-1968: Fix ssl_stub compiling as C++
Andrew Stitcher [Wed, 21 Nov 2018 15:22:26 +0000 (10:22 -0500)] 
PROTON-1968: Fix ssl_stub compiling as C++

8 weeks agoPROTON-1887: [c] fix signed/unsigned warning
Alan Conway [Tue, 20 Nov 2018 14:44:18 +0000 (09:44 -0500)] 
PROTON-1887: [c] fix signed/unsigned warning

8 weeks agoPROTON-1887: [c] Convert C tests to use Catch2 harness.
Alan Conway [Wed, 14 Nov 2018 22:12:51 +0000 (17:12 -0500)] 
PROTON-1887: [c] Convert C tests to use Catch2 harness.

Convert c/tests from home-baked test macros to the Catch2 test harness.
We are using version 1.x until we can move on from supporting C++03.

Added files:

- catch.hpp - the Catch2 version 1.x framework in a single header.
- catch_extra.hpp - added Catch::Matcher support for C-string comparisons

- pn_test.hpp/.cpp - tools for testing the core library
  - auto_free<> - scoped freeing of pn_xxx_t*
  - matchers to check pn_condition/error_t with useful output
  - driver class to pump a pn_connection_driver_t and check events
    - trivial in-memory copy transport, no networking needed.
- pn_test_proactor.hpp/cpp - tools for testing the proactor library
  - proactor to pump a pn_proactor and check events.
  - same handler as driver above.

Renamed tests files: c/tests/*.c => c/tests/*_test.cpp

Tests are now linked into 3 executables:

- c-core-test - tests for libqpid-proton-core API
- c-extra-test - tests for the "extra" deprecated API in libqpid-proton
- c-proactor-test - tests for the proactor API in libqpid-proton-proactor

Individual tests or subsets can be run via command line arguments, run with
"-h" for a summary, or see https://github.com/catchorg/Catch2/blob/Catch1.x/docs/command-line.md

NOTE: Catch2 allows multiple "tags" to be associated with each test to easily
define different test sets. We're not using this feature yet, we could use it to
identify a fast self-test set, a long-running stress test set etc.

2 months agoPROTON-1959: [cpp] API additions to simplify reconnect
Alan Conway [Tue, 30 Oct 2018 19:14:04 +0000 (15:14 -0400)] 
PROTON-1959: [cpp] API additions to simplify reconnect

messaging_handler::on_connection_start() - initial, exactly once event
messaging_handler::on_connection_reconnecting() - disconnected with auto-reconnect pending
bool connection::reconnected() - connection has been auto-reconnected

Added connection life-cycle doc to the messaging_handler class API doc.

2 months agoPROTON-1959: [cpp] Zero pn_listener_t* in proton::listener::stop()
Alan Conway [Tue, 30 Oct 2018 19:01:07 +0000 (15:01 -0400)] 
PROTON-1959: [cpp] Zero pn_listener_t* in  proton::listener::stop()

Pointer becomes invalid sometime after stop() so must not be used again.

2 months agoPROTON-1959: [c epoll] Fix crash in some reconnect scenarios.
Alan Conway [Fri, 26 Oct 2018 21:57:12 +0000 (17:57 -0400)] 
PROTON-1959: [c epoll] Fix crash in some reconnect scenarios.

Proactor should release driver->collector *not* pn_connection_collector()
as the driver always keeps a valid collector pointer, but the connection may be
NULL if it has been released for reconnect.

2 months agoPROTON-1959: [cpp] Update simple_send example to re-send on reconnect
Alan Conway [Tue, 30 Oct 2018 19:35:35 +0000 (15:35 -0400)] 
PROTON-1959: [cpp] Update simple_send example to re-send on reconnect

2 months agoNO-JIRA: [cpp] Minor API doc cleanup
Alan Conway [Tue, 30 Oct 2018 19:08:50 +0000 (15:08 -0400)] 
NO-JIRA: [cpp] Minor API doc cleanup

- Remove API doc references to non-existent page "endpoint_lifecycle"
- Put extra doc pages in sensible order using pages.dox

2 months agoNO-JIRA: [go] Remove testing.TB.Helper(), only available from Go 1.9
Alan Conway [Wed, 24 Oct 2018 00:48:13 +0000 (20:48 -0400)] 
NO-JIRA: [go] Remove testing.TB.Helper(), only available from Go 1.9

2 months agoNO-JIRA: [go] common internal/test package for qpid.apache.org
Alan Conway [Fri, 12 Oct 2018 16:02:24 +0000 (12:02 -0400)] 
NO-JIRA: [go] common internal/test package for qpid.apache.org

Common utilities to simplify test code.
Updated package tests to use the common code.

2 months agoPROTON-1910: [go] fix faulty message test
Alan Conway [Fri, 12 Oct 2018 13:25:38 +0000 (09:25 -0400)] 
PROTON-1910: [go] fix faulty message test

2 months agoNO-JIRA: [go] Clean up warnings from `go vet -shadow`
Alan Conway [Thu, 11 Oct 2018 22:56:23 +0000 (18:56 -0400)] 
NO-JIRA: [go] Clean up warnings from `go vet -shadow`

2 months agoNO-JIRA: [go] example of using a selector
Alan Conway [Fri, 19 Oct 2018 23:26:47 +0000 (19:26 -0400)] 
NO-JIRA: [go] example of using a selector

2 months agoNO-JIRA: [go] Check Sender.Error() before sending
Alan Conway [Tue, 23 Oct 2018 22:02:48 +0000 (18:02 -0400)] 
NO-JIRA: [go] Check Sender.Error() before sending

3 months agoNO-JIRA: [c,cpp] Fix example scripts for old python and CMake
Alan Conway [Tue, 16 Oct 2018 16:34:25 +0000 (12:34 -0400)] 
NO-JIRA: [c,cpp] Fix example scripts for old python and CMake

3 months agoNO-JIRA: [c,cpp] fix monkey-patch of python 2.7 unittest features for python 2.6
Alan Conway [Tue, 16 Oct 2018 14:09:36 +0000 (10:09 -0400)] 
NO-JIRA: [c,cpp] fix monkey-patch of python 2.7 unittest features for python 2.6

Don't apply patch on versions that have the feature.

3 months agoNO-JIRA: [go] Avoid use of testing.TB.Name() for older Go versions
Alan Conway [Mon, 15 Oct 2018 23:46:55 +0000 (19:46 -0400)] 
NO-JIRA: [go] Avoid use of testing.TB.Name() for older Go versions

3 months agoNO-JIRA: [c,cpp] monkey-patch python 2.7 unittest features for python 2.6
Alan Conway [Mon, 15 Oct 2018 18:46:22 +0000 (14:46 -0400)] 
NO-JIRA: [c,cpp] monkey-patch python 2.7 unittest features for python 2.6

3 months agoNO-JIRA: Benchmark script for comparing examples in different languages
Alan Conway [Mon, 15 Oct 2018 14:23:44 +0000 (10:23 -0400)] 
NO-JIRA: Benchmark script for comparing examples in different languages

Crude but effective throughput comparison that can run and combine examples
in different languages.

3 months agoNO-JIRA: [go] example receiver grants credit like other examples
Alan Conway [Mon, 15 Oct 2018 14:22:54 +0000 (10:22 -0400)] 
NO-JIRA: [go] example receiver grants credit like other examples

Default to N credits where N is expected message count.
-prefetch option specifies a credit window instead

3 months ago PROTON-1910: [go] move message encode/decode to handler thread
Alan Conway [Thu, 11 Oct 2018 19:23:00 +0000 (15:23 -0400)] 
 PROTON-1910: [go] move message encode/decode to handler thread

3 months agoPROTON-1910: [go] native Message implementation
Alan Conway [Thu, 11 Oct 2018 19:20:23 +0000 (15:20 -0400)] 
PROTON-1910: [go] native Message implementation

3 months agoPROTON-1910: [go] proton.Link allow sending/receiving message as bytes
Alan Conway [Thu, 11 Oct 2018 19:19:00 +0000 (15:19 -0400)] 
PROTON-1910: [go] proton.Link allow sending/receiving message as bytes

3 months agoPROTON-1956: [go] server does not close transport on unexpected disconnect
Alan Conway [Tue, 9 Oct 2018 20:30:05 +0000 (16:30 -0400)] 
PROTON-1956: [go] server does not close transport on unexpected disconnect

3 months agoNO-JIRA: Map Go errors to amqp::internal-error
Alan Conway [Fri, 5 Oct 2018 21:05:16 +0000 (17:05 -0400)] 
NO-JIRA: Map Go errors to amqp::internal-error

Previously using go error type name which is not useful, and often empty.

3 months agoPROTON-1955: [go] incorrect conversion between Go time and AMQP time
Alan Conway [Fri, 5 Oct 2018 19:38:48 +0000 (15:38 -0400)] 
PROTON-1955: [go] incorrect conversion between Go time and AMQP time

3 months agoNO-JIRA: longer timeout in heartbeat test, false failures
Alan Conway [Wed, 10 Oct 2018 20:12:11 +0000 (16:12 -0400)] 
NO-JIRA: longer timeout in heartbeat test, false failures

3 months agoNO-JIRA: Fix go vet -v warnings, minor typos
Alan Conway [Fri, 5 Oct 2018 19:38:14 +0000 (15:38 -0400)] 
NO-JIRA: Fix go vet -v warnings, minor typos

3 months agoPROTON-1952: [go] Server connection fails to authenticate
Alan Conway [Fri, 5 Oct 2018 16:02:28 +0000 (12:02 -0400)] 
PROTON-1952: [go] Server connection fails to authenticate

Problem: If the Server() option came after SASL options in the option list, the
server hangs in authentication.

Solution: NewConnection panics if there is a Server() option that is not the first
option in the list.

3 months agoPROTON-1954: [go] Container should default to random container-id
Alan Conway [Fri, 21 Sep 2018 00:53:14 +0000 (20:53 -0400)] 
PROTON-1954: [go] Container should default to random container-id

- default to random container-id
- add ContainerId option to set container ID without a Container object
- set remote heartbeat on incoming connection settings

3 months agoPROTON-1910: [go] test refactor and benchmarks
Alan Conway [Fri, 21 Sep 2018 04:51:45 +0000 (00:51 -0400)] 
PROTON-1910: [go] test refactor and benchmarks

- Simplify commmon test tools, move to commmon_test.go
- Use net.Pipe for most tests, more efficient than a full network socket
- Added simple benchmarks

3 months agoPROTON-1953: [go] occasional client/server hang with high volume of messages
Alan Conway [Wed, 10 Oct 2018 20:09:33 +0000 (16:09 -0400)] 
PROTON-1953: [go] occasional client/server hang with high volume of messages

Due to race/deadlock in read/write and engine main  goroutine. Simplified:
- start read/write goroutines as needed
- handle read/write completion via Inject(), no special channels

3 months agoPROTON-1944, PROTON-1926: update versions for 0.27.0-SNAPSHOT
Robbie Gemmell [Thu, 4 Oct 2018 10:15:20 +0000 (11:15 +0100)] 
PROTON-1944, PROTON-1926: update versions for 0.27.0-SNAPSHOT

3 months agoPROTON-1926, PROTON-1944: restore versions for 0.26.0-rc2 0.26.0 0.26.0-rc2
Robbie Gemmell [Thu, 4 Oct 2018 10:09:02 +0000 (11:09 +0100)] 
PROTON-1926, PROTON-1944: restore versions for 0.26.0-rc2

This reverts commit 1b554aad70452d6501cb3e13a6c10186d14e9dc9.

3 months agoNO-JIRA: merge update to Travis config to resolve pip issues. This closes #161.
Robbie Gemmell [Thu, 4 Oct 2018 08:33:05 +0000 (09:33 +0100)] 
NO-JIRA: merge update to Travis config to resolve pip issues. This closes #161.

3 months agoNO-JIRA: Removed python upgrade for xcode7.3 build to fix pip issue 161/head
Roddie Kieley [Wed, 3 Oct 2018 18:43:29 +0000 (16:13 -0230)] 
NO-JIRA: Removed python upgrade for xcode7.3 build to fix pip issue

3 months agoNO-JIRA: call out the repo cleanup step
Robbie Gemmell [Wed, 3 Oct 2018 13:39:46 +0000 (14:39 +0100)] 
NO-JIRA: call out the repo cleanup step

3 months agoPROTON-1974: [cpp] modify to work with older jsoncpp (1.7.4)
Alan Conway [Tue, 2 Oct 2018 15:40:16 +0000 (11:40 -0400)] 
PROTON-1974: [cpp] modify to work with older jsoncpp (1.7.4)

- add jsoncpp to travis packages for CI testing
- fix string conversions - rules changed between 1.7.4 and 1.8
- better error handling/reporting

3 months agoPROTON-1947: [cpp] not locating jsoncpp library on some platforms
Alan Conway [Tue, 2 Oct 2018 14:54:50 +0000 (10:54 -0400)] 
PROTON-1947: [cpp] not locating jsoncpp library on some platforms

CMake was not adding the INCLUDE_DIR locations found by FindJsonCpp
so a non-standard installation would be found but cause a compile failure.

3 months agoPROTON-1946: [cpp] connection config parser incorrect defaults
Alan Conway [Mon, 1 Oct 2018 18:54:35 +0000 (14:54 -0400)] 
PROTON-1946: [cpp] connection config parser incorrect defaults

- Change default "host" to "localhost" (was "")
- Only throw proton::error, don't leak jsoncpp exceptions
- Add tests for SASL/TLS behavior
- Treat explicit "null" valued field as equivalent to a missing field

3 months agoPROTON-1944, PROTON-1926: update versions for 0.27.0-SNAPSHOT
Robbie Gemmell [Mon, 1 Oct 2018 11:50:30 +0000 (12:50 +0100)] 
PROTON-1944, PROTON-1926: update versions for 0.27.0-SNAPSHOT

3 months agoPROTON-1926: update versions for 0.26.0-rc1 0.26.0-rc1
Robbie Gemmell [Mon, 1 Oct 2018 11:31:26 +0000 (12:31 +0100)] 
PROTON-1926: update versions for 0.26.0-rc1

3 months agoPROTON-1926: bump so versions based on review by Justin, Andrew, Alan, and Cliff.
Robbie Gemmell [Mon, 1 Oct 2018 11:08:14 +0000 (12:08 +0100)] 
PROTON-1926: bump so versions based on review by Justin, Andrew, Alan, and Cliff.

3 months agoPartially revert "NO-JIRA: Remove unused deprecated reactor functionality"
Andrew Stitcher [Thu, 27 Sep 2018 15:52:17 +0000 (11:52 -0400)] 
Partially revert "NO-JIRA: Remove unused deprecated reactor functionality"
- Retain the symbols for linkage, but remove them from the header file

This reverts commit 57f5ec14aebe374d718cbb87c079a7b56cb6b705.

3 months agoMerge branch 'master' of https://git-wip-us.apache.org/repos/asf/qpid-proton
Kim van der Riet [Fri, 28 Sep 2018 18:28:15 +0000 (14:28 -0400)] 
Merge branch 'master' of https://git-wip-us.apache.org/repos/asf/qpid-proton

3 months agoNO_JIRA: Minor typo fix for C++ codec tests which change type long for long long.
Kim van der Riet [Fri, 28 Sep 2018 18:26:58 +0000 (14:26 -0400)] 
NO_JIRA: Minor typo fix for C++ codec tests which change type long for long long.

3 months agoNO-JIRA: [cpp] fix example race condition, causing occasional hang
Alan Conway [Fri, 28 Sep 2018 15:11:41 +0000 (11:11 -0400)] 
NO-JIRA: [cpp] fix example race condition, causing occasional hang

3 months agoPROTON-1940: [c] normalize encoding of multiple="true" fields 159/head
Alan Conway [Mon, 24 Sep 2018 15:41:03 +0000 (11:41 -0400)] 
PROTON-1940: [c] normalize encoding of multiple="true" fields

Append src to data after normalizing for "multiple" field encoding.

AMQP composite field definitions can be declared "multiple", see:

- http://docs.oasis-open.org/amqp/core/v1.0/os/amqp-core-types-v1.0-os.html#doc-idp115568
- http://docs.oasis-open.org/amqp/core/v1.0/os/amqp-core-types-v1.0-os.html#section-composite-type-representation

Multiple fields allow redundant encoding of two cases:

1. empty: null or an empty array.
2. single-value: direct encoding of value, or array with one element

For encoding compactness and inter-operability, normalize multiple
field values to always use null for empty, and direct encoding for
single value.

3 months agoPROTON-1942: [c] decoding a message does not set the inferred flag.
Alan Conway [Thu, 27 Sep 2018 18:04:48 +0000 (14:04 -0400)] 
PROTON-1942: [c] decoding a message does not set the inferred flag.

3 months agoPROTON-1942: [c] separate pn_message_encode2 from pn_message_send
Alan Conway [Thu, 27 Sep 2018 17:17:32 +0000 (13:17 -0400)] 
PROTON-1942: [c] separate pn_message_encode2 from pn_message_send

3 months agoNO-JIRA: [cpp] document proton::condition operators == and <<
Alan Conway [Fri, 22 Jun 2018 18:58:26 +0000 (14:58 -0400)] 
NO-JIRA: [cpp] document proton::condition operators == and <<

3 months agoPROTON-1888: allow configuration of connection details from file
Gordon Sim [Tue, 25 Sep 2018 20:04:11 +0000 (21:04 +0100)] 
PROTON-1888: allow configuration of connection details from file

3 months agoNO-JIRA: Rename runtime_check.cmake to RuntimeCheck.cmake
Alan Conway [Tue, 25 Sep 2018 21:59:34 +0000 (17:59 -0400)] 
NO-JIRA: Rename runtime_check.cmake to RuntimeCheck.cmake

Follow CMake file naming conventions

3 months agoNO-JIRA: Fixing numpy brew link error via removal of unused postgis
Roddie Kieley [Fri, 21 Sep 2018 17:04:15 +0000 (14:34 -0230)] 
NO-JIRA: Fixing numpy brew link error via removal of unused postgis

3 months agoPROTON-1937: Use value.type() to check for value presence or absence
Chuck Rolke [Mon, 24 Sep 2018 20:06:29 +0000 (16:06 -0400)] 
PROTON-1937: Use value.type() to check for value presence or absence

This closes #158

3 months agoNO-JIRA: Rename docs/connect_config.md -> connect-config.md
Alan Conway [Fri, 21 Sep 2018 19:59:31 +0000 (15:59 -0400)] 
NO-JIRA: Rename docs/connect_config.md -> connect-config.md

Keep in line with file naming conventions.

3 months agoNO-JIRA: [ruby] replace #sum with #reduce for ruby < 2.4
Alan Conway [Wed, 19 Sep 2018 17:19:30 +0000 (13:19 -0400)] 
NO-JIRA: [ruby] replace #sum with #reduce for ruby < 2.4

3 months agoNO-JIRA: Revert use of cmake ENVIRONMENT test property
Alan Conway [Wed, 19 Sep 2018 16:17:14 +0000 (12:17 -0400)] 
NO-JIRA: Revert use of cmake ENVIRONMENT test property

Does not work on some older versions of CMake, even though the 2.8.12
documentation says it should.

3 months agofNO-JIRA: [cpp] testme check program exists instead of using HAS_CPP11
Alan Conway [Tue, 18 Sep 2018 20:01:21 +0000 (16:01 -0400)] 
fNO-JIRA: [cpp] testme check program exists instead of using HAS_CPP11

Using HAS_CPP11 won't work outside a build tree. Instead check for existence
of test executables to detect tests that are not built under c++03

3 months agoPROTON-1935: [cpp] fix minor c++03 compatibility issues.
Alan Conway [Tue, 18 Sep 2018 19:48:48 +0000 (15:48 -0400)] 
PROTON-1935: [cpp] fix minor c++03 compatibility issues.

3 months agoPROTON-1935: minor correction to docs/connect_config.md
Alan Conway [Tue, 18 Sep 2018 18:51:55 +0000 (14:51 -0400)] 
PROTON-1935: minor correction to docs/connect_config.md

3 months agoPROTON-1935: [cpp] connection configuration and default connect()
Alan Conway [Tue, 18 Sep 2018 13:31:47 +0000 (09:31 -0400)] 
PROTON-1935: [cpp] connection configuration and default connect()

docs/connect-config.md: describes connection configuration JSON format.

container::connect() connects using the default configuration file

Additional API in proton::connect_config allows the user to parse configuration
and apply to a connection_options object for more flexible use.

3 months agoNO-JIRA: [Python] Trivial pylint fixes
Andrew Stitcher [Thu, 13 Sep 2018 21:23:26 +0000 (17:23 -0400)] 
NO-JIRA: [Python] Trivial pylint fixes

4 months agoNO-JIRA: Remove unused deprecated reactor functionality
Andrew Stitcher [Mon, 17 Sep 2018 17:59:38 +0000 (13:59 -0400)] 
NO-JIRA: Remove unused deprecated reactor functionality

4 months agoNO-JIRA: Mark FIXME items as TODO
Alan Conway [Thu, 13 Sep 2018 01:10:27 +0000 (21:10 -0400)] 
NO-JIRA: Mark FIXME items as TODO

4 months agoPROTON-1934: [Python] Export Backoff from reactor.py
Andrew Stitcher [Wed, 12 Sep 2018 20:51:43 +0000 (16:51 -0400)] 
PROTON-1934: [Python] Export Backoff from reactor.py
- Also some minor fixes to internal imports

4 months agoPROTON-1929: [c] move pn_log_data from util.c to log.c
Alan Conway [Wed, 12 Sep 2018 17:35:17 +0000 (13:35 -0400)] 
PROTON-1929: [c] move pn_log_data from util.c to log.c

util.c should not depend on anything but standard C libraries.

4 months agoPROTON-1798: [cmake] string(APPEND) is not available in CMake 2.8.12
Alan Conway [Wed, 12 Sep 2018 14:30:19 +0000 (10:30 -0400)] 
PROTON-1798: [cmake] string(APPEND) is not available in CMake 2.8.12

4 months agoNO-JIRA: [c] Fix link error in fuzz tests.
Alan Conway [Tue, 11 Sep 2018 19:17:16 +0000 (15:17 -0400)] 
NO-JIRA: [c] Fix link error in fuzz tests.

Linking the URL fuzz test directly with util.c breaks as it now depends on
private symbols in the core library. Instead link with libqpid-proton which
includes everything required.

4 months agoPROTON-1798: [c, cpp, ruby] Installable tests for proton
Alan Conway [Mon, 10 Sep 2018 21:13:09 +0000 (17:13 -0400)] 
PROTON-1798: [c, cpp, ruby] Installable tests for proton

Tests can be executed from install for c, cpp, ruby.
See tests/share/examples-README.md

RUNTIME_CHECK=memcheck, helgrind are supported for normal builds.
asan, tsan require a special library build so less likely to be useful for install tests.

- python, go examples
- non-example tests installed under share/pronton-VERSION/tests/<language>

4 months agoPROTON-1929: [c] library prints directly to stderr/stdout
Alan Conway [Mon, 10 Sep 2018 19:54:57 +0000 (15:54 -0400)] 
PROTON-1929: [c] library prints directly to stderr/stdout

Replace direct use of stdout with pn_log calls.

4 months agoPROTON-1930: [cpp] Fix race condition in container_test.cpp
Alan Conway [Mon, 10 Sep 2018 16:35:52 +0000 (12:35 -0400)] 
PROTON-1930: [cpp] Fix race condition in container_test.cpp

Test was starting container, opening connection and then checking for
["start", "open"] sequence to be set by handlers.

Sometimes the sequence was instead ["open", "start"], which is legal since the
events are generated in different handler contexts.

Fixed by starting container, waiting for "start", opening connection, then
waiting for "open"

4 months agoPROTON-1798: cmake runtime-check improvements
Alan Conway [Fri, 7 Sep 2018 17:20:42 +0000 (13:20 -0400)] 
PROTON-1798: cmake runtime-check improvements

Usage notes:
- new CMake variable: RUNTIME_CHECK, choose from [memcheck helgrind asan tsan OFF]
- defaults to 'memcheck' if available, else OFF
- old ENABLE_ variables for valgrind/sanitizers are deprecated
- example_test scripts check for stderr output including from killed processes

Implementation details:

- moved all runtime-check setup code to seprate runtime-check.cmake
- tool-agnostic internal CMake variables for running tests
- removed all valgrind-specific code outside of runtime-check.cmake
- example_test.py check stderr as well as exit status to catch broker issues.

NOTE: asan,tsan not yet working for python/ruby bindings, they are disabled in
san builds. See tests/preload_asan.sh for current status of the work.

NOTE: Some python soak tests for obscure messenger features were removed, they
have faulty start-up timing logic and can fail under valgrind. We can restore
them if needed but we'll need to fix the -X feature of msgr-recv to report ready
only after connections are remote open.

4 months agoPROTON-1798: [cpp] add library destructors for main classes
Alan Conway [Wed, 5 Sep 2018 18:12:20 +0000 (14:12 -0400)] 
PROTON-1798: [cpp] add library destructors for main classes

Add library destructors to anchor vtables and typeinfo for connection, session,
sender, recever and delivery.

Without them, the ubsan sanitizer reports mismatched types due to different
weak vtable symbols in scope at library and executable link time.

4 months agoPROTON-1798: [cpp] C++ broker example, remove unused shutdown code.
Alan Conway [Wed, 5 Sep 2018 17:56:46 +0000 (13:56 -0400)] 
PROTON-1798: [cpp] C++ broker example, remove unused shutdown code.

4 months agoPROTON-1798: [c] Fix benign race in broker.c example found by tsan
Alan Conway [Tue, 4 Sep 2018 23:32:59 +0000 (19:32 -0400)] 
PROTON-1798: [c] Fix benign race in broker.c example found by tsan

4 months agoPROTON-1928: install static libraries
Alan Conway [Fri, 7 Sep 2018 13:56:26 +0000 (09:56 -0400)] 
PROTON-1928: install static libraries