60 likes | 93 Views
A 100% pure Java solution for implementing Channel Access in Java. Last release: Release 1.1.3 - 2006-12-20. Fixes for duplicate channel creations and slow connection speed. Implementation of CAJ server/library for integrating non-EPICS data into EPICS environment. Future work includes possible extensions to CA and integration with EPICS v4.
E N D
Java Channel AccessClient and Server Library - status Matej Šekoranja matej.sekoranja@cosylab.com Presented at the EPICS Meeting in Padova, 2008-10-17
CAJ Client library • Implementation of Channel Access in Java • 100% pure Java solution, no JNI • Last release is: Release 1.1.3 - 2006-12-20 • People are happy, no problems…. • Well… actually, there were 2: • Duplicate channel creations • Thanks to Marty and DLS for extensive testing • Slow connection speed when connecting to several thousands of channels at once • Thanks to Kay Kasemir and Tom Pelaia for testing • Solved in release 1.1.5 (to be released in a week) Cosylab 2008
Common CAJ (JCA) misuse • Major problem • flushIO(), pendIO(timeout), pendEvents(time) • pendIO(timeout) is being used for all • to be used only for sync. (blocking) get and channel creation • operations are context-wide, therefore must be used with care in multi-threaded applications • many threads calling pendIO(timeout) • simple brute-force synchronization will degrade performance • asynch. CA calls have to be used • non-perfect implementation of CA asynch. calls (get, put, create channel) • “basic” java synchronization mechanism, still in 99% code examples I’ve received not implemented in a right way Cosylab 2008
CAJ Server library • Already used by Gemini, DESY, Marty’s javaIOC • It’s a Java “equivalent” of C++ Portable Channel Access Server • Easy way to integrate non-EPICS data/variables into EPICS env. • clean, flexible, programmer friendly design • easy != something that is possible • easy == couple of minutes • Complete, finished implementation • Release plan: this year. Cosylab 2008
Future work • None? • A few problem reports from the first release (Nov 2004), none for a half of a year (extensive users are happy with v1.1.5) • Extensions to CA (structures)? EPICS v4? • CAJ server/client is based on state-of-the-art communication ”framework” • Acceptor/connector: an object creational pattern for connecting and initializing communication Services • Leader/Followers: design pattern for efficient multi-threaded event demultiplexing and dispatching • Reactor: synchronous I/O can be used as a base to develop new communication protocols Cosylab 2008
Thank You for Your Attention Cosylab 2008