I tried with the blob data type. This gives a Datastax exception. I tried the object itself, bytearray. Nothing good yet:
Caused by: com.datastax.driver.core.exceptions.InvalidQueryException: Invalid STRING constant ([ B@547248ad ) for user_object of type blob
This is a failed INSERT:
executeSting.append("INSERT INTO htadb.objecttable (object_id, bucket_name, object_key, link, user_status, user_object) ") .append("VALUES (") .append(objectId).append(",'") .append(bucketName).append("','") .append(key).append("','") .append(link).append("','") .append("online").append("','") .append(serializer(register)).append("')" + ";");
source share