feat: Aerospike backup reader and Aerospike-to-Bigtable adapter#185
feat: Aerospike backup reader and Aerospike-to-Bigtable adapter#185prawilny wants to merge 7 commits into
Conversation
Co-authored-by: Kajetan Boroszko <kajetan@unoperate.com>
There was a problem hiding this comment.
Code Review
This pull request introduces a suite of tools for migrating data from Aerospike to Cloud Bigtable, including a data mapping adapter, a JNI-based backup loader, and a Kafka Connect Single Message Transformation for streaming replication. The review feedback identifies several areas for improvement: removing disruptive System.exit() calls from library components, addressing unsafe pointer usage and misleading error messages in the JNI layer, and correcting inaccurate Javadoc in value wrapper classes. Additionally, suggestions were provided to modernize the Dockerfile by replacing deprecated apt-key usage and to refine exception handling and string encoding for better performance and API consistency.
| try { | ||
| LOG.info("LOADING backupreader LIBRARY FROM {}...", System.mapLibraryName("backupreader")); | ||
| System.loadLibrary("backupreader"); | ||
| } catch (Exception e) { | ||
| LOG.error("Error while loading the backupreader library", e); | ||
| System.exit(123); | ||
| } |
There was a problem hiding this comment.
Calling System.exit() in a library component is generally discouraged as it terminates the entire JVM, which can be disruptive in shared environments or managed platforms like Dataflow. It is better to let the error propagate naturally (e.g., as an UnsatisfiedLinkError).
LOG.info("LOADING backupreader LIBRARY FROM {}...", System.mapLibraryName("backupreader"));
System.loadLibrary("backupreader");| RUN curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | \ | ||
| apt-key --keyring /usr/share/keyrings/cloud.google.gpg add - |
|
Closing because #189 was merged in which is based off of this PR |
This PR adds tooling for Aerospike to Cloud Bigtable migration.