Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ import java.util.UUID
* normal tuple size limits.
*/
object LargeBinaryManager extends LazyLogging {
private val DEFAULT_BUCKET = "texera-large-binaries"
val DEFAULT_BUCKET: String = "texera-large-binaries"

/**
* Creates a new LargeBinary reference.
Expand All @@ -39,8 +39,6 @@ object LargeBinaryManager extends LazyLogging {
* @return S3 URI string for the new LargeBinary (format: s3://bucket/key)
*/
def create(): String = {
S3StorageClient.createBucketIfNotExist(DEFAULT_BUCKET)

val objectKey = s"objects/${System.currentTimeMillis()}/${UUID.randomUUID()}"
val uri = s"s3://$DEFAULT_BUCKET/$objectKey"

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ import org.apache.texera.service.resource.{
HealthCheckResource
}
import org.apache.texera.service.util.S3StorageClient
import org.apache.texera.service.util.LargeBinaryManager
import org.eclipse.jetty.server.session.SessionHandler
import java.nio.file.Path

Expand Down Expand Up @@ -70,6 +71,8 @@ class FileService extends Application[FileServiceConfiguration] with LazyLogging

// check if the texera dataset bucket exists, if not create it
S3StorageClient.createBucketIfNotExist(StorageConfig.lakefsBucketName)
// ensure the large-binary S3 bucket exists before any workflow execution attempts to use it
S3StorageClient.createBucketIfNotExist(LargeBinaryManager.DEFAULT_BUCKET)
// check if we can connect to the lakeFS service
LakeFSStorageClient.healthCheck()

Expand Down
Loading