-
-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Sync at end, call GC, start event log
- Loading branch information
Showing
24 changed files
with
531 additions
and
63 deletions.
There are no files selected for viewing
19 changes: 19 additions & 0 deletions
19
...creator-web/src/main/kotlin/de/griefed/serverpackcreator/web/customizing/ModRepository.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
30 changes: 30 additions & 0 deletions
30
...b/src/main/kotlin/de/griefed/serverpackcreator/web/customizing/StartArgumentRepository.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
/* Copyright (C) 2023 Griefed | ||
* | ||
* This library is free software; you can redistribute it and/or | ||
* modify it under the terms of the GNU Lesser General Public | ||
* License as published by the Free Software Foundation; either | ||
* version 2.1 of the License, or (at your option) any later version. | ||
* | ||
* This library is distributed in the hope that it will be useful, | ||
* but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
* Lesser General Public License for more details. | ||
* | ||
* You should have received a copy of the GNU Lesser General Public | ||
* License along with this library; if not, write to the Free Software | ||
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 | ||
* USA | ||
* | ||
* The full license can be found at https:github.com/Griefed/ServerPackCreator/blob/main/LICENSE | ||
*/ | ||
package de.griefed.serverpackcreator.web.customizing | ||
|
||
import de.griefed.serverpackcreator.web.data.StartArgument | ||
import org.springframework.data.jpa.repository.JpaRepository | ||
import org.springframework.stereotype.Repository | ||
import java.util.* | ||
|
||
@Repository | ||
interface StartArgumentRepository : JpaRepository<StartArgument, Int> { | ||
fun findByArgument(argument: String): Optional<StartArgument> | ||
} |
58 changes: 58 additions & 0 deletions
58
serverpackcreator-web/src/main/kotlin/de/griefed/serverpackcreator/web/data/ErrorEntry.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
/* Copyright (C) 2023 Griefed | ||
* | ||
* This library is free software; you can redistribute it and/or | ||
* modify it under the terms of the GNU Lesser General Public | ||
* License as published by the Free Software Foundation; either | ||
* version 2.1 of the License, or (at your option) any later version. | ||
* | ||
* This library is distributed in the hope that it will be useful, | ||
* but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
* Lesser General Public License for more details. | ||
* | ||
* You should have received a copy of the GNU Lesser General Public | ||
* License along with this library; if not, write to the Free Software | ||
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 | ||
* USA | ||
* | ||
* The full license can be found at https:github.com/Griefed/ServerPackCreator/blob/main/LICENSE | ||
*/ | ||
package de.griefed.serverpackcreator.web.data | ||
|
||
import jakarta.persistence.Column | ||
import jakarta.persistence.Entity | ||
import jakarta.persistence.GeneratedValue | ||
import jakarta.persistence.Id | ||
|
||
@Entity | ||
class ErrorEntry { | ||
|
||
@Id | ||
@GeneratedValue | ||
@Column(updatable = false, nullable = false) | ||
var id: Int = 0 | ||
|
||
@Column | ||
var error: String | ||
|
||
constructor(error: String) { | ||
this.error = error | ||
} | ||
|
||
override fun equals(other: Any?): Boolean { | ||
if (this === other) return true | ||
if (javaClass != other?.javaClass) return false | ||
|
||
other as ErrorEntry | ||
|
||
return error == other.error | ||
} | ||
|
||
override fun hashCode(): Int { | ||
return error.hashCode() | ||
} | ||
|
||
override fun toString(): String { | ||
return "ErrorEntry(id=$id, error='$error')" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
53 changes: 53 additions & 0 deletions
53
serverpackcreator-web/src/main/kotlin/de/griefed/serverpackcreator/web/data/QueueEvent.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
/* Copyright (C) 2023 Griefed | ||
* | ||
* This library is free software; you can redistribute it and/or | ||
* modify it under the terms of the GNU Lesser General Public | ||
* License as published by the Free Software Foundation; either | ||
* version 2.1 of the License, or (at your option) any later version. | ||
* | ||
* This library is distributed in the hope that it will be useful, | ||
* but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
* Lesser General Public License for more details. | ||
* | ||
* You should have received a copy of the GNU Lesser General Public | ||
* License along with this library; if not, write to the Free Software | ||
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 | ||
* USA | ||
* | ||
* The full license can be found at https:github.com/Griefed/ServerPackCreator/blob/main/LICENSE | ||
*/ | ||
package de.griefed.serverpackcreator.web.data | ||
|
||
import de.griefed.serverpackcreator.web.modpack.ModpackStatus | ||
import jakarta.persistence.* | ||
import org.hibernate.annotations.CreationTimestamp | ||
import java.sql.Timestamp | ||
|
||
@Entity | ||
class QueueEvent { | ||
|
||
@Id | ||
@GeneratedValue | ||
@Column(updatable = false, nullable = false) | ||
var id: Int = 0 | ||
|
||
@Column | ||
var modPackId: Int = 0 | ||
|
||
@Column | ||
var serverPackId: Int? = null | ||
|
||
@Column | ||
var status: ModpackStatus? = null | ||
|
||
@Column | ||
var message: String = "" | ||
|
||
@CreationTimestamp | ||
@Column | ||
var timestamp: Timestamp? = null | ||
|
||
@ManyToMany | ||
var errors: MutableList<ErrorEntry> = mutableListOf() | ||
} |
Oops, something went wrong.