Technology Working Group - January 11, 2016
Jason Coposky, Chief Technologist
Agenda
New Plugin Framework
Existing plugin framework relies on type erasure via variadic parameters in the plugin operation:
typedef error( *plugin_operation )( plugin_context&, ... );
Chosen due to limitations of current compilers and ease of integration with Legacy code.
Issues include a serious lack of type safety across shared object boundaries
New Plugin Framework
Given the move to clang 3.7 we now have access to modern features:
New Plugin Framework
Adding an operation to a plugin
template<typename... types_t>
error add_operation( const std::string& _op,
std::function<error(plugin_context&, types_t...)> _f ) {
}
In the plugin implementation
resc->add_operation<T0,T1,T2>(
"operation_name",
std::function<error(plugin_context&,T0,T1,T2)( operation_impl ) );
New Plugin Framework
Calling a Plugin Operation
template< typename... types_t >
error call(rsComm_t* _comm,
const std::string& _operation_name,
irods::first_class_object_ptr _fco,
types_t... _t ) {
}
Calling a Plugin Operation
resc->call<T0,T1,T2>( comm, "operation_name", fco, t0, t1, t2 );
Consideration of move to Resource IDs
Currently resc_hier is stored as a string in r_data_main
Propose to move to storing leaf resource id as an integer
Consideration of move to Resource IDs
Considerations:
Requires a change in schema for r_data_main
Code is near complete in a feature branch
Table update may exist as a separate script ran before the new package is installed, or as part of the upgrade
Proposed deprecations
X Message - Move to use of AMQP Message Bus
iphybun & bundleResc - not well tested, can be implemented as a resource plugin if required by membership or the community