Skip to content

Commit

Permalink
version bump (#203)
Browse files Browse the repository at this point in the history
  • Loading branch information
dev-claw authored Dec 14, 2024
1 parent 91e74c3 commit b429c58
Show file tree
Hide file tree
Showing 204 changed files with 16,733 additions and 11,756 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,5 @@
/**/*/build-dir
/**/*/java-runtime
.idea
.vripper
.vripper
.flattened-pom.xml
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ Direct access to `vipergirls.to` domain.

<img src="https://github.com/stashapp/stash/raw/develop/docs/readme_assets/windows_logo.svg" width="100%" height="75"> Windows | <img src="https://github.com/stashapp/stash/raw/develop/docs/readme_assets/mac_logo.svg" width="100%" height="75"> macOS | <img src="https://github.com/stashapp/stash/raw/develop/docs/readme_assets/linux_logo.svg" width="100%" height="75"> Linux | <img src="https://images.vexels.com/media/users/3/166401/isolated/preview/b82aa7ac3f736dd78570dd3fa3fa9e24-java-programming-language-icon-by-vexels.png" width="100%" height="75"> Java
:---:|:---:|:---:|:---:
[Installer (EXE)](https://github.com/death-claw/vripper-project/releases/download/5.8.0/vripper-windows-installer-5.8.0.exe) <br /> [Installer (MSI)](https://github.com/death-claw/vripper-project/releases/download/5.8.0/vripper-windows-installer-5.8.0.msi) <br /> [Portable (ZIP)](https://github.com/death-claw/vripper-project/releases/download/5.8.0/vripper-windows-portable-5.8.0.zip) | [Installer (DMG)](https://github.com/death-claw/vripper-project/releases/download/5.8.0/vripper-macos-5.8.0.dmg) <br /> [Installer (PKG)](https://github.com/death-claw/vripper-project/releases/download/5.8.0/vripper-macos-5.8.0.pkg) <br /> [Portable (ZIP)](https://github.com/death-claw/vripper-project/releases/download/5.8.0/vripper-macos-portable-5.8.0.zip) | [Linux (amd64) (DEB)](https://github.com/death-claw/vripper-project/releases/download/5.8.0/vripper-linux-5.8.0_amd64.deb) <br /> [Linux (x86_64) (RPM)](https://github.com/death-claw/vripper-project/releases/download/5.8.0/vripper-linux-5.8.0.x86_64.rpm) <br /> [Portable (ZIP)](https://github.com/death-claw/vripper-project/releases/download/5.8.0/vripper-linux-portable-5.8.0.zip) | [Java GUI (noarch)](https://github.com/death-claw/vripper-project/releases/download/5.8.0/vripper-noarch-gui-5.8.0.jar) <br /> [Java Web (noarch)](https://github.com/death-claw/vripper-project/releases/download/5.8.0/vripper-noarch-web-5.8.0.jar)
[Installer (EXE)](https://github.com/death-claw/vripper-project/releases/download/6.0.0/vripper-windows-installer-6.0.0.exe) <br /> [Installer (MSI)](https://github.com/death-claw/vripper-project/releases/download/6.0.0/vripper-windows-installer-6.0.0.msi) <br /> [Portable (ZIP)](https://github.com/death-claw/vripper-project/releases/download/6.0.0/vripper-windows-portable-6.0.0.zip) | [Installer (DMG)](https://github.com/death-claw/vripper-project/releases/download/6.0.0/vripper-macos-6.0.0.dmg) <br /> [Installer (PKG)](https://github.com/death-claw/vripper-project/releases/download/6.0.0/vripper-macos-6.0.0.pkg) <br /> [Portable (ZIP)](https://github.com/death-claw/vripper-project/releases/download/6.0.0/vripper-macos-portable-6.0.0.zip) | [Linux (amd64) (DEB)](https://github.com/death-claw/vripper-project/releases/download/6.0.0/vripper-linux-6.0.0_amd64.deb) <br /> [Linux (x86_64) (RPM)](https://github.com/death-claw/vripper-project/releases/download/6.0.0/vripper-linux-6.0.0.x86_64.rpm) <br /> [Portable (ZIP)](https://github.com/death-claw/vripper-project/releases/download/6.0.0/vripper-linux-portable-6.0.0.zip) | [Java GUI (noarch)](https://github.com/death-claw/vripper-project/releases/download/6.0.0/vripper-noarch-gui-6.0.0.jar) <br /> [Java Web (noarch)](https://github.com/death-claw/vripper-project/releases/download/6.0.0/vripper-noarch-web-6.0.0.jar)

Source code and previous versions are available on the [Releases page](https://github.com/death-claw/vripper-project/releases).

Expand Down
53 changes: 35 additions & 18 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -15,27 +15,29 @@
<maven.compiler.source>${java.version}</maven.compiler.source>
<maven.compiler.target>${java.version}</maven.compiler.target>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<revision>5.8.0</revision>
<kotlin.version>1.9.22</kotlin.version>
<slf4j.version>2.0.12</slf4j.version>
<logback.version>1.5.0</logback.version>
<kotlinx-coroutines.version>1.8.0</kotlinx-coroutines.version>
<exposed.version>0.47.0</exposed.version>
<revision>6.0.0</revision>
<kotlin.version>2.0.21</kotlin.version>
<slf4j.version>2.0.16</slf4j.version>
<logback.version>1.5.12</logback.version>
<kotlinx-coroutines.version>1.9.0</kotlinx-coroutines.version>
<exposed.version>0.55.0</exposed.version>
<snakeyaml.version>2.0</snakeyaml.version>
<koin.version>3.5.3</koin.version>
<koin.version>4.0.0</koin.version>
<h2.version>2.2.224</h2.version>
<htmlcleaner.version>2.29</htmlcleaner.version>
<failsafe.version>2.4.4</failsafe.version>
<caffeine.version>3.1.8</caffeine.version>
<jna-platform.version>5.14.0</jna-platform.version>
<kotlinx-serialization-json.version>1.6.2</kotlinx-serialization-json.version>
<httpclient5.version>5.3.1</httpclient5.version>
<commons-codec.version>1.16.1</commons-codec.version>
<liquibase-core.version>4.26.0</liquibase-core.version>
<kotlinx-serialization-json.version>1.7.3</kotlinx-serialization-json.version>
<httpclient5.version>5.4</httpclient5.version>
<httpcore5.version>5.3</httpcore5.version>
<commons-codec.version>1.17.1</commons-codec.version>
<liquibase-core.version>4.29.2</liquibase-core.version>
<liquibase-slf4j.version>5.0.0</liquibase-slf4j.version>
<grpc.kotlin.version>1.4.1</grpc.kotlin.version>
<java.grpc.version>1.62.2</java.grpc.version>
<protobuf.version>3.25.3</protobuf.version>
<java.grpc.version>1.68.1</java.grpc.version>
<protobuf.version>3.25.5</protobuf.version>
<sqlite-jdbc.version>3.47.0.0</sqlite-jdbc.version>
</properties>
<build>
<plugins>
Expand Down Expand Up @@ -129,6 +131,11 @@
<groupId>com.h2database</groupId>
<version>${h2.version}</version>
</dependency>
<dependency>
<groupId>org.xerial</groupId>
<artifactId>sqlite-jdbc</artifactId>
<version>${sqlite-jdbc.version}</version>
</dependency>
<dependency>
<artifactId>htmlcleaner</artifactId>
<groupId>net.sourceforge.htmlcleaner</groupId>
Expand Down Expand Up @@ -169,6 +176,16 @@
<groupId>org.apache.httpcomponents.client5</groupId>
<version>${httpclient5.version}</version>
</dependency>
<dependency>
<artifactId>httpcore5</artifactId>
<groupId>org.apache.httpcomponents.core5</groupId>
<version>${httpcore5.version}</version>
</dependency>
<dependency>
<artifactId>httpcore5-h2</artifactId>
<groupId>org.apache.httpcomponents.core5</groupId>
<version>${httpcore5.version}</version>
</dependency>
<dependency>
<artifactId>commons-codec</artifactId>
<groupId>commons-codec</groupId>
Expand All @@ -194,16 +211,16 @@
<artifactId>grpc-protobuf</artifactId>
<version>${java.grpc.version}</version>
</dependency>
<dependency>
<groupId>com.google.protobuf</groupId>
<artifactId>protobuf-kotlin</artifactId>
<version>${protobuf.version}</version>
</dependency>
<dependency>
<groupId>io.grpc</groupId>
<artifactId>grpc-netty-shaded</artifactId>
<version>${java.grpc.version}</version>
</dependency>
<dependency>
<groupId>com.google.protobuf</groupId>
<artifactId>protobuf-kotlin</artifactId>
<version>${protobuf.version}</version>
</dependency>
</dependencies>
</dependencyManagement>
</project>
4 changes: 4 additions & 0 deletions vripper-core/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,10 @@
<artifactId>h2</artifactId>
<groupId>com.h2database</groupId>
</dependency>
<dependency>
<groupId>org.xerial</groupId>
<artifactId>sqlite-jdbc</artifactId>
</dependency>
<dependency>
<artifactId>httpclient5</artifactId>
<groupId>org.apache.httpcomponents.client5</groupId>
Expand Down
22 changes: 14 additions & 8 deletions vripper-core/src/main/kotlin/me/vripper/Module.kt
Original file line number Diff line number Diff line change
@@ -1,10 +1,16 @@
package me.vripper

import me.vripper.data.repositories.ImageRepository
import me.vripper.data.repositories.MetadataRepository
import me.vripper.data.repositories.PostDownloadStateRepository
import me.vripper.data.repositories.ThreadRepository
import me.vripper.data.repositories.impl.ImageRepositoryImpl
import me.vripper.data.repositories.impl.MetadataRepositoryImpl
import me.vripper.data.repositories.impl.PostDownloadStateRepositoryImpl
import me.vripper.data.repositories.impl.ThreadRepositoryImpl
import me.vripper.download.DownloadService
import me.vripper.event.EventBus
import me.vripper.host.*
import me.vripper.repositories.*
import me.vripper.repositories.impl.*
import me.vripper.services.*
import org.koin.core.qualifier.named
import org.koin.dsl.bind
Expand All @@ -17,6 +23,9 @@ val coreModule = module {
single<SettingsService> {
SettingsService(get())
}
single<LogService> {
LogService(get())
}
single<ImageRepository> {
ImageRepositoryImpl()
}
Expand All @@ -29,11 +38,8 @@ val coreModule = module {
single<ThreadRepository> {
ThreadRepositoryImpl()
}
single<LogRepository> {
LogRepositoryImpl(get())
}
single<DataTransaction> {
DataTransaction(get(), get(), get(), get(), get(), get(), get())
DataTransaction(get(), get(), get(), get(), get(), get())
}
single<RetryPolicyService> {
RetryPolicyService(get(), get())
Expand All @@ -55,11 +61,11 @@ val coreModule = module {
}

single<AppEndpointService> {
AppEndpointService(get(), get(), get(), get(), get())
AppEndpointService(get(), get(), get(), get(), get(), get())
}

single((named("localAppEndpointService"))) {
AppEndpointService(get(), get(), get(), get(), get())
AppEndpointService(get(), get(), get(), get(), get(), get())
} bind IAppEndpointService::class

single<MetadataService> {
Expand Down
16 changes: 16 additions & 0 deletions vripper-core/src/main/kotlin/me/vripper/RingAppender.kt
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
package me.vripper

import ch.qos.logback.classic.spi.ILoggingEvent
import ch.qos.logback.core.AppenderBase
import org.apache.commons.collections4.queue.CircularFifoQueue

class RingAppender : AppenderBase<ILoggingEvent>() {

object Static {
val events = CircularFifoQueue<ILoggingEvent>()
}

override fun append(event: ILoggingEvent) {
Static.events.offer(event)
}
}
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
package me.vripper.repositories
package me.vripper.data.repositories

import me.vripper.entities.ImageEntity
import java.util.*

interface ImageRepository {
internal interface ImageRepository {
fun save(imageEntity: ImageEntity): ImageEntity
fun save(imageEntityList: List<ImageEntity>)
fun deleteAllByPostId(postId: Long)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
package me.vripper.repositories
package me.vripper.data.repositories

import me.vripper.entities.MetadataEntity
import java.util.*

interface MetadataRepository {
internal interface MetadataRepository {
fun save(metadataEntity: MetadataEntity): MetadataEntity
fun findByPostId(postId: Long): Optional<MetadataEntity>
fun deleteByPostId(postId: Long): Int
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
package me.vripper.repositories
package me.vripper.data.repositories

import me.vripper.entities.PostEntity
import java.util.*

interface PostDownloadStateRepository {
internal interface PostDownloadStateRepository {
fun save(postEntities: List<PostEntity>): List<PostEntity>
fun findByPostId(postId: Long): Optional<PostEntity>
fun findById(id: Long): Optional<PostEntity>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
package me.vripper.repositories
package me.vripper.data.repositories

import me.vripper.entities.ThreadEntity
import java.util.*

interface ThreadRepository {
internal interface ThreadRepository {
fun save(threadEntity: ThreadEntity): ThreadEntity
fun update(threadEntity: ThreadEntity)
fun findByThreadId(threadId: Long): Optional<ThreadEntity>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
package me.vripper.repositories.impl
package me.vripper.data.repositories.impl

import me.vripper.data.repositories.ImageRepository
import me.vripper.data.tables.ImageTable
import me.vripper.entities.ImageEntity
import me.vripper.entities.domain.Status
import me.vripper.repositories.ImageRepository
import me.vripper.tables.ImageTable
import me.vripper.entities.Status
import org.jetbrains.exposed.sql.*
import org.jetbrains.exposed.sql.SqlExpressionBuilder.eq
import org.jetbrains.exposed.sql.transactions.TransactionManager
import java.sql.Connection
import java.util.*

class ImageRepositoryImpl : ImageRepository {
internal class ImageRepositoryImpl : ImageRepository {
override fun save(imageEntity: ImageEntity): ImageEntity {
val id = ImageTable.insertAndGetId {
it[downloaded] = imageEntity.downloaded
Expand Down Expand Up @@ -47,21 +47,21 @@ class ImageRepositoryImpl : ImageRepository {
}

override fun findByPostId(postId: Long): List<ImageEntity> {
return ImageTable.select {
return ImageTable.selectAll().where {
ImageTable.postId eq postId
}.map(this::transform)
}

override fun countError(): Int {
return ImageTable
.slice(ImageTable.id)
.select { ImageTable.status eq Status.ERROR.name }
.select(ImageTable.id)
.where { ImageTable.status eq Status.ERROR.name }
.count().toInt()
}

override fun findByPostIdAndIsNotCompleted(postId: Long): List<ImageEntity> {
return ImageTable
.select {
.selectAll().where {
(ImageTable.postId eq postId) and (ImageTable.status neq Status.FINISHED.name)
}.map(this::transform)
}
Expand All @@ -79,13 +79,13 @@ class ImageRepositoryImpl : ImageRepository {
}

override fun findByPostIdAndIsError(postId: Long): List<ImageEntity> {
return ImageTable.select {
return ImageTable.selectAll().where {
(ImageTable.postId eq postId) and (ImageTable.status eq Status.ERROR.name)
}.map(this::transform)
}

override fun findById(id: Long): Optional<ImageEntity> {
val result = ImageTable.select {
val result = ImageTable.selectAll().where {
ImageTable.id eq id
}.map(this::transform)
return if (result.isEmpty()) {
Expand Down Expand Up @@ -122,7 +122,7 @@ class ImageRepositoryImpl : ImageRepository {

override fun deleteAllByPostId(postIds: List<Long>) {
val conn = TransactionManager.current().connection.connection as Connection
conn.prepareStatement("CREATE LOCAL TEMPORARY TABLE IMAGES_DELETE(POST_ID BIGINT PRIMARY KEY)")
conn.prepareStatement("CREATE TEMPORARY TABLE IMAGES_DELETE(POST_ID BIGINT PRIMARY KEY)")
.use {
it.execute()
}
Expand All @@ -140,7 +140,7 @@ class ImageRepositoryImpl : ImageRepository {
it.execute()
}

conn.prepareStatement("TRUNCATE TABLE IMAGES_DELETE").use {
conn.prepareStatement("DELETE FROM IMAGES_DELETE").use {
it.execute()
}
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
package me.vripper.repositories.impl
package me.vripper.data.repositories.impl

import kotlinx.serialization.encodeToString
import kotlinx.serialization.json.Json
import me.vripper.data.repositories.MetadataRepository
import me.vripper.data.tables.MetadataTable
import me.vripper.entities.MetadataEntity
import me.vripper.repositories.MetadataRepository
import me.vripper.tables.MetadataTable
import org.jetbrains.exposed.sql.ResultRow
import org.jetbrains.exposed.sql.SqlExpressionBuilder.eq
import org.jetbrains.exposed.sql.deleteWhere
import org.jetbrains.exposed.sql.insert
import org.jetbrains.exposed.sql.select
import org.jetbrains.exposed.sql.selectAll
import org.jetbrains.exposed.sql.transactions.TransactionManager
import java.sql.Connection
import java.util.*

class MetadataRepositoryImpl: MetadataRepository {
internal class MetadataRepositoryImpl : MetadataRepository {

override fun save(metadataEntity: MetadataEntity): MetadataEntity {
MetadataTable.insert {
Expand All @@ -27,7 +27,7 @@ class MetadataRepositoryImpl: MetadataRepository {

override fun findByPostId(postId: Long): Optional<MetadataEntity> {

val result = MetadataTable.select {
val result = MetadataTable.selectAll().where {
MetadataTable.postId eq postId
}.map(::transform)

Expand All @@ -50,7 +50,7 @@ class MetadataRepositoryImpl: MetadataRepository {

override fun deleteAllByPostId(postIds: List<Long>) {
val conn = TransactionManager.current().connection.connection as Connection
conn.prepareStatement("CREATE LOCAL TEMPORARY TABLE METADATA_DELETE(POST_ID BIGINT PRIMARY KEY)")
conn.prepareStatement("CREATE TEMPORARY TABLE METADATA_DELETE(POST_ID BIGINT PRIMARY KEY)")
.use {
it.execute()
}
Expand All @@ -68,7 +68,7 @@ class MetadataRepositoryImpl: MetadataRepository {
it.execute()
}

conn.prepareStatement("TRUNCATE TABLE METADATA_DELETE").use {
conn.prepareStatement("DELETE FROM METADATA_DELETE").use {
it.execute()
}
}
Expand Down
Loading

0 comments on commit b429c58

Please sign in to comment.