diff --git a/modules/core/shared/src/main/scala/scaladex/core/service/SonatypeClient.scala b/modules/core/shared/src/main/scala/scaladex/core/service/MavenCentralClient.scala similarity index 94% rename from modules/core/shared/src/main/scala/scaladex/core/service/SonatypeClient.scala rename to modules/core/shared/src/main/scala/scaladex/core/service/MavenCentralClient.scala index 662011709..3181da9f7 100644 --- a/modules/core/shared/src/main/scala/scaladex/core/service/SonatypeClient.scala +++ b/modules/core/shared/src/main/scala/scaladex/core/service/MavenCentralClient.scala @@ -8,7 +8,7 @@ import scaladex.core.model.Artifact import scaladex.core.model.Artifact.MavenReference import scaladex.core.model.SemanticVersion -trait SonatypeClient { +trait MavenCentralClient { def getAllArtifactIds(groupId: Artifact.GroupId): Future[Seq[Artifact.ArtifactId]] def getAllVersions(groupId: Artifact.GroupId, artifactId: Artifact.ArtifactId): Future[Seq[SemanticVersion]] def getPomFile(mavenReference: MavenReference): Future[Option[(String, Instant)]] diff --git a/modules/core/shared/src/main/scala/scaladex/core/service/SchedulerDatabase.scala b/modules/core/shared/src/main/scala/scaladex/core/service/SchedulerDatabase.scala index 58c8c5a20..85f0256b7 100644 --- a/modules/core/shared/src/main/scala/scaladex/core/service/SchedulerDatabase.scala +++ b/modules/core/shared/src/main/scala/scaladex/core/service/SchedulerDatabase.scala @@ -29,8 +29,9 @@ trait SchedulerDatabase extends WebDatabase { def updateArtifacts(artifacts: Seq[Artifact], newRef: Project.Reference): Future[Int] def updateArtifactReleaseDate(reference: MavenReference, releaseDate: Instant): Future[Int] def getAllGroupIds(): Future[Seq[Artifact.GroupId]] - def getAllArtifactIds(ref: Project.Reference): Future[Seq[(Artifact.GroupId, String)]] + def getArtifactIds(ref: Project.Reference): Future[Seq[(Artifact.GroupId, String)]] def getAllMavenReferences(): Future[Seq[Artifact.MavenReference]] + def getMavenReferences(ref: Project.Reference): Future[Seq[Artifact.MavenReference]] def getDependencies(projectRef: Project.Reference): Future[Seq[ArtifactDependency]] def updateLatestVersion(ref: MavenReference): Future[Unit] } diff --git a/modules/core/shared/src/test/scala/scaladex/core/test/InMemoryDatabase.scala b/modules/core/shared/src/test/scala/scaladex/core/test/InMemoryDatabase.scala index 716dd8b69..d528bcece 100644 --- a/modules/core/shared/src/test/scala/scaladex/core/test/InMemoryDatabase.scala +++ b/modules/core/shared/src/test/scala/scaladex/core/test/InMemoryDatabase.scala @@ -139,6 +139,8 @@ class InMemoryDatabase extends SchedulerDatabase { override def updateArtifacts(allArtifacts: Seq[Artifact], newRef: Project.Reference): Future[Int] = ??? override def getAllGroupIds(): Future[Seq[Artifact.GroupId]] = ??? override def getAllMavenReferences(): Future[Seq[Artifact.MavenReference]] = ??? + + override def getMavenReferences(ref: Project.Reference): Future[Seq[Artifact.MavenReference]] = ??? override def insertUser(userId: UUID, userInfo: UserInfo): Future[Unit] = ??? override def updateUser(userId: UUID, userInfo: UserState): Future[Unit] = ??? override def getUser(userId: UUID): Future[Option[UserState]] = ??? @@ -208,7 +210,7 @@ class InMemoryDatabase extends SchedulerDatabase { Future.successful(res) } - override def getAllArtifactIds(ref: Project.Reference): Future[Seq[(Artifact.GroupId, String)]] = + override def getArtifactIds(ref: Project.Reference): Future[Seq[(Artifact.GroupId, String)]] = Future.successful(allArtifacts(ref).map(a => (a.groupId, a.artifactId)).toSeq) override def updateLatestVersion(ref: Artifact.MavenReference): Future[Unit] = diff --git a/modules/data/src/main/scala/scaladex/data/maven/PomsReader.scala b/modules/data/src/main/scala/scaladex/data/maven/PomsReader.scala index fe40ba587..dc1769383 100644 --- a/modules/data/src/main/scala/scaladex/data/maven/PomsReader.scala +++ b/modules/data/src/main/scala/scaladex/data/maven/PomsReader.scala @@ -77,16 +77,12 @@ class PomsReader(resolver: PomResolver) extends LazyLogging { private val jdk = new Properties jdk.setProperty("java.version", "1.8") // << ??? - def loadOne(path: Path): Try[(ArtifactModel, String)] = { - val sha1 = path.getFileName.toString.stripSuffix(".pom") - - Try { - val request = (new DefaultModelBuildingRequest) - .setModelResolver(modelResolver) - .setSystemProperties(jdk) - .setPomFile(path.toFile) - - builder.build(request).getEffectiveModel - }.map(pom => (PomConvert(pom), sha1)) - } + def loadOne(path: Path): Try[ArtifactModel] = Try { + val request = (new DefaultModelBuildingRequest) + .setModelResolver(modelResolver) + .setSystemProperties(jdk) + .setPomFile(path.toFile) + + builder.build(request).getEffectiveModel + }.map(pom => PomConvert(pom)) } diff --git a/modules/infra/src/main/scala/scaladex/infra/SonatypeClientImpl.scala b/modules/infra/src/main/scala/scaladex/infra/MavenCentralClientImpl.scala similarity index 91% rename from modules/infra/src/main/scala/scaladex/infra/SonatypeClientImpl.scala rename to modules/infra/src/main/scala/scaladex/infra/MavenCentralClientImpl.scala index 5a0e5431e..6ab8c06a4 100644 --- a/modules/infra/src/main/scala/scaladex/infra/SonatypeClientImpl.scala +++ b/modules/infra/src/main/scala/scaladex/infra/MavenCentralClientImpl.scala @@ -25,15 +25,15 @@ import scaladex.core.model.Artifact import scaladex.core.model.Artifact.MavenReference import scaladex.core.model.SbtPlugin import scaladex.core.model.SemanticVersion -import scaladex.core.service.SonatypeClient +import scaladex.core.service.MavenCentralClient import scaladex.core.util.JsoupUtils -class SonatypeClientImpl()(implicit val system: ActorSystem) +class MavenCentralClientImpl()(implicit val system: ActorSystem) extends CommonAkkaHttpClient - with SonatypeClient + with MavenCentralClient with LazyLogging { private implicit val ec: ExecutionContextExecutor = system.dispatcher - private val sonatypeUri = "https://repo1.maven.org/maven2" + private val baseUri = "https://repo1.maven.org/maven2" lazy val poolClientFlow: Flow[ (HttpRequest, Promise[HttpResponse]), (Try[HttpResponse], Promise[HttpResponse]), @@ -46,7 +46,7 @@ class SonatypeClientImpl()(implicit val system: ActorSystem) ) def getAllArtifactIds(groupId: Artifact.GroupId): Future[Seq[Artifact.ArtifactId]] = { - val uri = s"$sonatypeUri/${groupId.mavenUrl}/" + val uri = s"$baseUri/${groupId.mavenUrl}/" val request = HttpRequest(uri = uri) @@ -60,7 +60,7 @@ class SonatypeClientImpl()(implicit val system: ActorSystem) } def getAllVersions(groupId: Artifact.GroupId, artifactId: Artifact.ArtifactId): Future[Seq[SemanticVersion]] = { - val uri = s"$sonatypeUri/${groupId.mavenUrl}/${artifactId.value}/" + val uri = s"$baseUri/${groupId.mavenUrl}/${artifactId.value}/" val request = HttpRequest(uri = uri) val future = for { @@ -104,7 +104,7 @@ class SonatypeClientImpl()(implicit val system: ActorSystem) .parse(mavenReference.artifactId) .map { artifactId => val pomUrl = getPomUrl(artifactId, mavenReference.version) - val uri = s"$sonatypeUri/${groupIdUrl}/${mavenReference.artifactId}/${mavenReference.version}/$pomUrl" + val uri = s"$baseUri/${groupIdUrl}/${mavenReference.artifactId}/${mavenReference.version}/$pomUrl" val request = HttpRequest(uri = uri) queueRequest(request).map(Option.apply) } diff --git a/modules/infra/src/main/scala/scaladex/infra/SqlDatabase.scala b/modules/infra/src/main/scala/scaladex/infra/SqlDatabase.scala index f25a570be..111554e43 100644 --- a/modules/infra/src/main/scala/scaladex/infra/SqlDatabase.scala +++ b/modules/infra/src/main/scala/scaladex/infra/SqlDatabase.scala @@ -180,12 +180,14 @@ class SqlDatabase(datasource: HikariDataSource, xa: doobie.Transactor[IO]) exten override def getAllGroupIds(): Future[Seq[Artifact.GroupId]] = run(ArtifactTable.selectGroupIds.to[Seq]) - override def getAllArtifactIds(ref: Project.Reference): Future[Seq[(Artifact.GroupId, String)]] = + override def getArtifactIds(ref: Project.Reference): Future[Seq[(Artifact.GroupId, String)]] = run(ArtifactTable.selectArtifactIds.to[Seq](ref)) override def getAllMavenReferences(): Future[Seq[Artifact.MavenReference]] = - run(ArtifactTable.selectMavenReference.to[Seq]) + run(ArtifactTable.selectAllMavenReferences.to[Seq]) + override def getMavenReferences(ref: Project.Reference): Future[Seq[Artifact.MavenReference]] = + run(ArtifactTable.selectMavenReferences.to[Seq](ref)) override def insertUser(userId: UUID, userInfo: UserInfo): Future[Unit] = run(UserSessionsTable.insert.run((userId, userInfo)).map(_ => ())) diff --git a/modules/infra/src/main/scala/scaladex/infra/sql/ArtifactTable.scala b/modules/infra/src/main/scala/scaladex/infra/sql/ArtifactTable.scala index 8dd8d690d..caeb4a3c4 100644 --- a/modules/infra/src/main/scala/scaladex/infra/sql/ArtifactTable.scala +++ b/modules/infra/src/main/scala/scaladex/infra/sql/ArtifactTable.scala @@ -107,9 +107,12 @@ object ArtifactTable { val selectArtifactIds: Query[Project.Reference, (Artifact.GroupId, String)] = selectRequest(table, Seq("DISTINCT group_id", "artifact_id"), keys = projectReferenceFields) - val selectMavenReference: Query0[Artifact.MavenReference] = + val selectAllMavenReferences: Query0[Artifact.MavenReference] = selectRequest(table, Seq("DISTINCT group_id", "artifact_id", "\"version\"")) + val selectMavenReferences: Query[Project.Reference, Artifact.MavenReference] = + selectRequest(table, Seq("DISTINCT group_id", "artifact_id", "\"version\""), keys = projectReferenceFields) + val selectMavenReferenceWithNoReleaseDate: Query0[Artifact.MavenReference] = selectRequest(table, Seq("group_id", "artifact_id", "\"version\""), where = Seq("release_date is NULL")) diff --git a/modules/infra/src/test/scala/scaladex/infra/SonatypeClientImplTests.scala b/modules/infra/src/test/scala/scaladex/infra/MavenCentralClientImplTests.scala similarity index 66% rename from modules/infra/src/test/scala/scaladex/infra/SonatypeClientImplTests.scala rename to modules/infra/src/test/scala/scaladex/infra/MavenCentralClientImplTests.scala index df4b90386..e5e3ce48a 100644 --- a/modules/infra/src/test/scala/scaladex/infra/SonatypeClientImplTests.scala +++ b/modules/infra/src/test/scala/scaladex/infra/MavenCentralClientImplTests.scala @@ -9,28 +9,28 @@ import scaladex.core.model.Artifact import scaladex.core.model.Artifact._ import scaladex.core.model.SemanticVersion -class SonatypeClientImplTests extends AsyncFunSpec with Matchers { - implicit val system: ActorSystem = ActorSystem("sonatype-client-tests") - val sonatypeClient = new SonatypeClientImpl() +class MavenCentralClientImplTests extends AsyncFunSpec with Matchers { + implicit val system: ActorSystem = ActorSystem("maven-central-client-tests") + val client = new MavenCentralClientImpl() val groupId: GroupId = GroupId("ch.epfl.scala") val artifactId: ArtifactId = ArtifactId.parse("sbt-scalafix_2.12_1.0").get val version: SemanticVersion = SemanticVersion.parse("0.9.23").get it(s"retrieve artifactIds for ${groupId.value}") { for { - res <- sonatypeClient.getAllArtifactIds(groupId) + res <- client.getAllArtifactIds(groupId) } yield res should contain(artifactId) } it(s"retrieve versions for groupId: ${groupId.value}, artifactId: ${artifactId.value}") { for { - res <- sonatypeClient.getAllVersions(groupId, artifactId) + res <- client.getAllVersions(groupId, artifactId) } yield res should contain(version) } it(s"retrieve versions for ru.tinkoff:typed-schema-swagger-typesafe_2.12") { for { - res <- sonatypeClient.getAllVersions( + res <- client.getAllVersions( GroupId("ru.tinkoff"), ArtifactId.parse("typed-schema-swagger-typesafe_2.12").get ) @@ -39,31 +39,31 @@ class SonatypeClientImplTests extends AsyncFunSpec with Matchers { it(s"retrieve pomfile for maven reference of sbt plugin") { for { - res <- sonatypeClient.getPomFile(Artifact.MavenReference("ch.epfl.scala", "sbt-scalafix_2.12_1.0", "0.9.23")) + res <- client.getPomFile(Artifact.MavenReference("ch.epfl.scala", "sbt-scalafix_2.12_1.0", "0.9.23")) } yield res.get._1.startsWith(" groupId.value) ++ artifactNameOpt.map(name => "Artifact Name" -> name.value) val task = TaskRunner.run(Task.findMissingArtifacts, user.info.login, input) { () => - sonatypeSynchronizer.syncOne(groupId, artifactNameOpt) + mavenCentralService.syncOne(groupId, artifactNameOpt) } tasks = tasks :+ task } @@ -137,9 +137,9 @@ class AdminService( tasks = tasks :+ task } - def updateMavenArtifacts(user: UserState): Unit = { - val task = TaskRunner.run(Task.updateMavenArtifacts, user.info.login, input = Seq.empty) { () => - sonatypeSynchronizer.updateAllArtifacts() + def republishArtifacts(user: UserState): Unit = { + val task = TaskRunner.run(Task.republishArtifacts, user.info.login, input = Seq.empty) { () => + mavenCentralService.republishArtifacts() } tasks = tasks :+ task } diff --git a/modules/server/src/main/scala/scaladex/server/service/ArtifactService.scala b/modules/server/src/main/scala/scaladex/server/service/ArtifactService.scala index bcea99294..3ddd9ecd1 100644 --- a/modules/server/src/main/scala/scaladex/server/service/ArtifactService.scala +++ b/modules/server/src/main/scala/scaladex/server/service/ArtifactService.scala @@ -52,7 +52,7 @@ class ArtifactService(database: SchedulerDatabase)(implicit ec: ExecutionContext def updateLatestVersions(ref: Project.Reference, preferStableVersion: Boolean): Future[Int] = for { - artifactIds <- database.getAllArtifactIds(ref) + artifactIds <- database.getArtifactIds(ref) _ <- artifactIds.mapSync { case (groupId, artifactId) => updateLatestVersion(groupId, artifactId, preferStableVersion) } diff --git a/modules/server/src/main/scala/scaladex/server/service/GithubUpdater.scala b/modules/server/src/main/scala/scaladex/server/service/GithubUpdater.scala index cc3d62b9a..eab73efff 100644 --- a/modules/server/src/main/scala/scaladex/server/service/GithubUpdater.scala +++ b/modules/server/src/main/scala/scaladex/server/service/GithubUpdater.scala @@ -52,7 +52,7 @@ class GithubUpdater(database: WebDatabase, github: GithubClient)(implicit ec: Ex case GithubResponse.MovedPermanently((destination, info)) => val status = GithubStatus.Moved(now, destination) - logger.info(s"$repo moved to $status") + logger.info(s"$repo moved to $destination") database.moveProject(repo, info, status).map(_ => status) case GithubResponse.Failed(code, reason) => diff --git a/modules/server/src/main/scala/scaladex/server/service/SonatypeService.scala b/modules/server/src/main/scala/scaladex/server/service/MavenCentralService.scala similarity index 65% rename from modules/server/src/main/scala/scaladex/server/service/SonatypeService.scala rename to modules/server/src/main/scala/scaladex/server/service/MavenCentralService.scala index 39b687d7d..656d92bdb 100644 --- a/modules/server/src/main/scala/scaladex/server/service/SonatypeService.scala +++ b/modules/server/src/main/scala/scaladex/server/service/MavenCentralService.scala @@ -6,16 +6,17 @@ import scala.concurrent.Future import com.typesafe.scalalogging.LazyLogging import scaladex.core.model.Artifact import scaladex.core.model.Artifact._ +import scaladex.core.model.Project +import scaladex.core.service.MavenCentralClient import scaladex.core.service.SchedulerDatabase -import scaladex.core.service.SonatypeClient import scaladex.core.util.ScalaExtensions._ import scaladex.data.cleanup.NonStandardLib import scaladex.infra.DataPaths -class SonatypeService( +class MavenCentralService( dataPaths: DataPaths, database: SchedulerDatabase, - sonatypeService: SonatypeClient, + mavenCentralClient: MavenCentralClient, publishProcess: PublishProcess )(implicit ec: ExecutionContext) extends LazyLogging { @@ -39,14 +40,14 @@ class SonatypeService( knownRefs: Set[MavenReference] ): Future[Int] = for { - versions <- sonatypeService.getAllVersions(groupId, artifactId) + versions <- mavenCentralClient.getAllVersions(groupId, artifactId) mavenReferences = versions.map(v => MavenReference(groupId = groupId.value, artifactId = artifactId.value, version = v.toString) ) missingVersions = mavenReferences.filterNot(knownRefs) _ = if (missingVersions.nonEmpty) logger.warn(s"${missingVersions.size} artifacts are missing for ${groupId.value}:${artifactId.value}") - missingPomFiles <- missingVersions.map(ref => sonatypeService.getPomFile(ref).map(_.map(ref -> _))).sequence + missingPomFiles <- missingVersions.map(ref => mavenCentralClient.getPomFile(ref).map(_.map(ref -> _))).sequence publishResult <- missingPomFiles.flatten.mapSync { case (mavenRef, (pomFile, creationDate)) => publishProcess.publishPom(mavenRef.toString(), pomFile, creationDate, None) @@ -70,7 +71,7 @@ class SonatypeService( knownRefs: Set[MavenReference] ): Future[Int] = for { - artifactIds <- sonatypeService.getAllArtifactIds(groupId) + artifactIds <- mavenCentralClient.getAllArtifactIds(groupId) scalaArtifactIds = artifactIds.filter(artifact => artifactNameOpt.forall(_ == artifact.name) && artifact.isScala && artifact.binaryVersion.isValid ) @@ -84,19 +85,31 @@ class SonatypeService( result <- findAndIndexMissingArtifacts(groupId, artifactNameOpt, mavenReferenceFromDatabase.toSet) } yield s"Inserted $result poms" - def updateAllArtifacts(): Future[String] = + def republishArtifacts(): Future[String] = for { - mavenReferences <- database.getAllMavenReferences() - _ = logger.info(s"${mavenReferences.size} artifacts will be synced for new metadata.") - publishResult <- mavenReferences.mapSync(updateArtifact) - successCount = publishResult.count(_ == PublishResult.Success) - failedCount = publishResult.size - successCount - } yield s"Synced $successCount poms, while $failedCount poms failed to update." + projectStatuses <- database.getAllProjectsStatuses() + refs = projectStatuses.collect { case (ref, status) if status.isOk || status.isUnknown || status.isFailed => ref } + counts <- refs.mapSync(republishArtifacts) + } yield { + val successes = counts.map(_._1).sum + val failures = counts.map(_._2).sum + s"Re-published $successes artifacts ($failures failures)." + } + + private def republishArtifacts(projectRef: Project.Reference): Future[(Int, Int)] = + for { + mavenReferences <- database.getMavenReferences(projectRef) + publishResult <- mavenReferences.mapSync(republishArtifact(projectRef, _)) + } yield { + val successes = publishResult.count(_ == PublishResult.Success) + val failures = publishResult.size - successes + logger.info(s"Re-published $successes artifacts of $projectRef ($failures failures)") + (successes, failures) + } - private def updateArtifact(ref: MavenReference): Future[PublishResult] = - sonatypeService.getPomFile(ref).map(ref -> _).flatMap { - case (mavenRef, Some((pomFile, creationDate))) => - publishProcess.publishPom(mavenRef.toString(), pomFile, creationDate, None) - case _ => Future.successful(PublishResult.InvalidPom) + private def republishArtifact(projectRef: Project.Reference, ref: MavenReference): Future[PublishResult] = + mavenCentralClient.getPomFile(ref).flatMap { + case Some((pomFile, creationDate)) => publishProcess.republishPom(projectRef, ref, pomFile, creationDate) + case _ => Future.successful(PublishResult.InvalidPom) } } diff --git a/modules/server/src/main/scala/scaladex/server/service/PublishProcess.scala b/modules/server/src/main/scala/scaladex/server/service/PublishProcess.scala index 152f00960..4b10d7f73 100644 --- a/modules/server/src/main/scala/scaladex/server/service/PublishProcess.scala +++ b/modules/server/src/main/scala/scaladex/server/service/PublishProcess.scala @@ -4,9 +4,11 @@ import java.time.Instant import scala.concurrent.ExecutionContext import scala.concurrent.Future +import scala.util.Try import com.typesafe.scalalogging.LazyLogging import org.apache.pekko.actor.ActorSystem +import scaladex.core.model.Artifact import scaladex.core.model.Env import scaladex.core.model.Project import scaladex.core.model.Sha1 @@ -49,17 +51,12 @@ class PublishProcess( userState: Option[UserState] ): Future[PublishResult] = { logger.info(s"Publishing POM $path") - val sha1 = Sha1(data) - val tempFile = filesystem.createTempFile(data, sha1, ".pom") - val future = - Future(pomsReader.loadOne(tempFile).get) - .flatMap { case (pom, _) => publishPom(pom, creationDate, userState) } - .recover { cause => - logger.error(s"Invalid POM $path", cause) - PublishResult.InvalidPom - } - future.onComplete(_ => filesystem.deleteTempFile(tempFile)) - future + Future(loadPom(data).get) + .flatMap(publishPom(_, creationDate, userState)) + .recover { cause => + logger.error(s"Invalid POM $path", cause) + PublishResult.InvalidPom + } } private def publishPom( @@ -74,7 +71,7 @@ class PublishProcess( Future.successful(PublishResult.NoGithubRepo) case Some(repo) => // userState can be empty when the request of publish is done through the scheduler - if (userState.isEmpty || userState.get.hasPublishingAuthority(env) || userState.get.repos.contains(repo)) { + if (userState.forall(userState => userState.hasPublishingAuthority(env) || userState.repos.contains(repo))) { converter.convert(pom, repo, creationDate) match { case Some((artifact, deps)) => for { @@ -98,6 +95,38 @@ class PublishProcess( } } } + + def republishPom( + repo: Project.Reference, + ref: Artifact.MavenReference, + data: String, + creationDate: Instant + ): Future[PublishResult] = + Future(loadPom(data).get) + .flatMap { pom => + converter.convert(pom, repo, creationDate).map(_._1) match { + case Some(artifact) if artifact.mavenReference == ref => + database.insertArtifact(artifact).map(_ => PublishResult.Success) + case Some(artifact) => + logger.error(s"Unexpected ref ${artifact.mavenReference}") + Future.successful(PublishResult.InvalidPom) + case None => + logger.warn(s"Cannot convert $ref to valid Scala artifact.") + Future.successful(PublishResult.InvalidPom) + } + } + .recover { cause => + logger.warn(s"Invalid POM $ref", cause) + PublishResult.InvalidPom + } + + private def loadPom(data: String): Try[ArtifactModel] = { + val sha1 = Sha1(data) + val tempFile = filesystem.createTempFile(data, sha1, ".pom") + val res = pomsReader.loadOne(tempFile) + filesystem.deleteTempFile(tempFile) + res + } } object PublishProcess { diff --git a/modules/template/src/main/scala/scaladex/view/Task.scala b/modules/template/src/main/scala/scaladex/view/Task.scala index f3ca5ebcc..699178b61 100644 --- a/modules/template/src/main/scala/scaladex/view/Task.scala +++ b/modules/template/src/main/scala/scaladex/view/Task.scala @@ -24,9 +24,9 @@ object Task { "Update the Github info of an existing project" ) - val updateMavenArtifacts: Task = Task( - "update-maven-artifact", - "Download all pom files to update existing artifacts with new fields" + val republishArtifacts: Task = Task( + "republish-maven-artifact", + "Re-download pom files of known artifacts to extract new fields" ) case class Status(name: String, user: String, start: Instant, input: Seq[(String, String)], state: State) { diff --git a/modules/template/src/main/twirl/scaladex/view/admin/admin.scala.html b/modules/template/src/main/twirl/scaladex/view/admin/admin.scala.html index 6b1a0db37..a152cd2c6 100644 --- a/modules/template/src/main/twirl/scaladex/view/admin/admin.scala.html +++ b/modules/template/src/main/twirl/scaladex/view/admin/admin.scala.html @@ -122,11 +122,11 @@
@Task.updateMavenArtifacts.description
+@Task.republishArtifacts.description