mirror of
https://github.com/storytold/artcraft.git
synced 2026-11-03 17:08:13 +00:00
sort sentences desc, increase limit to 1000
This commit is contained in:
1 parent
66bf126639
commit
2bafa7cec0
3 files changed
+3
-2
No files matched your search
+1
-1
@@ -84,7 +84,7 @@ spec:
|
||||
# LSpeech model that sounds 100% amazing
|
||||
# image: docker.pkg.github.com/echelon/voder/tts-service:6b5c22567614
|
||||
#
|
||||
image: docker.pkg.github.com/ml-applications/voder/tts-service:d83cd11aaf1f
|
||||
image: docker.pkg.github.com/ml-applications/voder/tts-service:a671a66b3903
|
||||
resources:
|
||||
limits:
|
||||
memory: "2048Mi" # 2048 MiB = 2 GiB
|
||||
|
||||
@@ -39,6 +39,7 @@ impl Sentence {
|
||||
let pooled_connection : MysqlPooledConnection = db_connector.get_pooled_connection()?;
|
||||
let results = sentences::dsl::sentences
|
||||
.limit(limit)
|
||||
.order(sentences::dsl::id.desc())
|
||||
.load::<Sentence>(&pooled_connection)?;
|
||||
Ok(results)
|
||||
}
|
||||
|
||||
@@ -21,7 +21,7 @@ pub async fn get_sentences(
|
||||
) -> Either<Json<SentencesResult>, std::io::Result<HttpResponse>>{
|
||||
let app_state = app_state.into_inner();
|
||||
|
||||
let limit = 100;
|
||||
let limit = 1000;
|
||||
let sentences = match Sentence::load(&app_state.database_connector, limit) {
|
||||
Err(e) => {
|
||||
error!("Couldn't query database for sentences: {:?}", e);
|
||||
|
||||
Reference in new issue
Block a user