mirror of
https://github.com/corda/corda.git
synced 2025-06-19 23:53:52 +00:00
Simple Attachment Storage implementation using Requery/H2 database
This commit is contained in:
@ -0,0 +1,18 @@
|
||||
package net.corda.node.services.persistence.schemas
|
||||
|
||||
import io.requery.*
|
||||
import net.corda.core.crypto.SecureHash
|
||||
import net.corda.core.schemas.requery.converters.BlobConverter
|
||||
|
||||
@Table(name = "attachments")
|
||||
@Entity(model = "persistence")
|
||||
interface Attachment : Persistable {
|
||||
|
||||
@get:Key
|
||||
@get:Column(name = "att_id", index = true)
|
||||
var attId: SecureHash
|
||||
|
||||
@get:Column(name = "content")
|
||||
@get:Convert(BlobConverter::class)
|
||||
var content: ByteArray
|
||||
}
|
Reference in New Issue
Block a user