[ 
https://issues.apache.org/jira/browse/QPID-4027?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13284782#comment-13284782
 ] 

Rajith Attapattu commented on QPID-4027:
----------------------------------------

Rough design/implementation notes.
-------------------------------------

1. Swig will be used for generating the wrapper/JNI code.

2. The biggest overhead would be in moving message data across the JNI 
boundary. To avoid extra copying both message headers and content are shared as 
raw bytes using direct byte buffers.
  2.1 Message data/headers will be allocated direct on the java side which 
allows the C++ side to access the memory directly without any copying.
  2.2 Message data/headers on the c++ side will be wrapped via a 
java.nio.ByteBuffer directly (using JNI) to avoid any copying.

3. The various implementations (pure java, jython, c++) will be loaded via the 
"qpid.connection-factory" jvm argument.
   Ex 
-Dqpid.connection-factory=org.apache.qpid.messaging.cpp.CppConnectionFactory

4. In order for the bindings/implementations to work properly, 
failover/reconnection should be done at the Qpid API implementation layer and 
not the JMS layer as we now have. This allows us to leverage the 
implementations failover. Even in the current jms client, the jms failover 
interferes quite badly with the failover at the amqp layer causing deadlocks 
and other undesirable behaviour.
                
> Provide a Java Qpid API implementation over the C++ client
> ----------------------------------------------------------
>
>                 Key: QPID-4027
>                 URL: https://issues.apache.org/jira/browse/QPID-4027
>             Project: Qpid
>          Issue Type: New Feature
>          Components: C++ Client, Java Client
>            Reporter: Rajith Attapattu
>            Assignee: Rajith Attapattu
>             Fix For: 0.17
>
>
> QPID-4001 defines a java version of the Qpid API.
> While a pure java implementation is required and would be the default, under 
> certain circumstances jni over the C++ client maybe be useful. 
> Ex RDMA support
> It is also a good opportunity to leverage the more performant and stable 0-10 
> client as an alternative to the current JMS client provided we complete 
> QPID-4002
> This also provides an opportunity for QPID-4002 to progress without having to 
> wait for a pure java implementation.
> A few minor changes to the C++ is required.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to