gpt4 book ai didi

java - Artifactory 启动时抛出异常 : "No content to map due to end-of-input"

转载 作者:太空宇宙 更新时间:2023-11-04 09:37:54 35 4
gpt4 key购买 nike

前几天,我下载并安装了 JFrog Artifactory 6.10.0 版的开源免费版本。使用 Artifactory UI,我能够根据需要为 Maven 项目设置本地、远程和虚拟存储库,以便存储 Artifactory 上的构建并使用它来获取 Maven 依赖项。具体来说,我在第一次打开 UI 时通过选择 Maven 来设置这些内容,它会询问如何设置存储库。

我在 Windows 10 上将 Artifact 作为服务运行。如果有什么关系的话,我会说,在我第一次安装它时,当我从 Eclipse 运行 maven“部署”目标时,我收到了 401 未经授权的错误。我使用的项目在 pom.xml 文件中具有适当的条目,并且在我的 .m2 文件夹中具有适当的 settings.xml 文件。即使我的 settings.xml 文件是使用管理员凭据创建的,也会发生 401 错误。我致力于更改 Artifact 用户界面中的权限,最终在授予“管理员访问”用户所有权限后解决了问题。需要明确的是,此时一切都运行良好。当我从 Eclipse 运行“部署”目标时,从代理存储库下载依赖项,并将 Artifact 存储在 Artifact 中。

现在,当我启动 Artifactory 时,我会看到典型的启动动画,然后显示一个屏幕:

    {
"errors" : [ {
"status" : 500,
"message" : "Artifactory failed to initialize: check Artifactory logs for errors."
} ]
}

编辑:为了澄清起见,我将添加显示上述 JSON 错误消息的屏幕是当我转到 http://localhost:8081/artifactory/webapp 时我在屏幕上看到的唯一内容。并等待启动动画结束。该应用程序完全无法使用,因为它只显示上述 JSON 并停留在显示它的屏幕上。这是我面临的核心问题。

在检查人工日志时,在系统信息转储部分之后,我看到以下内容:

    2019-05-23 12:07:50,487 [art-init] [INFO ] (o.j.c.w.ConfigurationManagerImpl:445) - Replacing temporary DB channel with permanent DB channel
2019-05-23 12:07:50,488 [art-init] [INFO ] (o.j.c.w.ConfigurationManagerImpl:445) - Successfully closed temporary DB channel
2019-05-23 12:07:50,488 [art-init] [INFO ] (o.a.s.ArtifactoryApplicationContext:505) - Artifactory application context set to READY by refresh
2019-05-23 12:07:50,632 [art-init] [INFO ] (o.a.s.a.AccessServiceImpl:1529) - Successful register of Artifactory serviceId jfrt@01db44pt153v8z1j4eqnm60qxr in Access Federation
2019-05-23 12:07:50,710 [art-init] [ERROR] (o.a.w.s.ArtifactoryContextConfigListener:96) - Application could not be initialized: No content to map due to end-of-input
at [Source: (byte[])""; line: 1, column: 0]
java.lang.reflect.InvocationTargetException: null
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
at org.artifactory.webapp.servlet.ArtifactoryContextConfigListener.configure(ArtifactoryContextConfigListener.java:211)
at org.artifactory.webapp.servlet.ArtifactoryContextConfigListener.access$200(ArtifactoryContextConfigListener.java:67)
at org.artifactory.webapp.servlet.ArtifactoryContextConfigListener$1.run(ArtifactoryContextConfigListener.java:92)
Caused by: org.jfrog.common.JsonParsingException: com.fasterxml.jackson.databind.exc.MismatchedInputException: No content to map due to end-of-input
at [Source: (byte[])""; line: 1, column: 0]
at org.jfrog.common.MapperUtilsBase.unchecked(MapperUtilsBase.java:233)
at org.jfrog.common.MapperUtilsBase.readValue(MapperUtilsBase.java:203)
at org.jfrog.common.JsonUtils.readValue(JsonUtils.java:27)
at org.artifactory.storage.db.migration.service.MigrationStatusStorageServiceImpl.findMigrationByIdWithInfoBlob(MigrationStatusStorageServiceImpl.java:56)
at org.artifactory.metadata.service.MetadataMigrationHelper.getMigrationStatus(MetadataMigrationHelper.java:194)
at org.artifactory.metadata.service.MetadataMigrationHelper.shouldMigrate(MetadataMigrationHelper.java:65)
at org.artifactory.metadata.service.MetadataMigrationHelper.migrateOrStartEventPipe(MetadataMigrationHelper.java:52)
at org.artifactory.metadata.service.MetadataEventServiceImpl.onContextCreated(MetadataEventServiceImpl.java:121)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:317)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:201)
at com.sun.proxy.$Proxy220.onContextCreated(Unknown Source)
at org.artifactory.spring.ArtifactoryApplicationContext.contextCreated(ArtifactoryApplicationContext.java:285)
at org.artifactory.spring.ArtifactoryApplicationContext.<init>(ArtifactoryApplicationContext.java:146)
... 7 common frames omitted
Caused by: com.fasterxml.jackson.databind.exc.MismatchedInputException: No content to map due to end-of-input
at [Source: (byte[])""; line: 1, column: 0]
at com.fasterxml.jackson.databind.exc.MismatchedInputException.from(MismatchedInputException.java:59)
at com.fasterxml.jackson.databind.ObjectMapper._initForReading(ObjectMapper.java:4133)
at com.fasterxml.jackson.databind.ObjectMapper._readMapAndClose(ObjectMapper.java:3988)
at com.fasterxml.jackson.databind.ObjectMapper.readValue(ObjectMapper.java:3079)
at org.jfrog.common.MapperUtilsBase.lambda$readValue$14(MapperUtilsBase.java:203)
at org.jfrog.common.MapperUtilsBase.unchecked(MapperUtilsBase.java:231)
... 23 common frames omitted

对此的任何帮助将不胜感激。我不确定我是否以某种方式偶然发现了 Artifactory 错误,或者在创建存储库、使用 Artifactory 存储/获取依赖项或将我的 Artifact 存储在那里时是否以某种方式破坏了应用程序。

如果重要的话,这里是我的 pom.xml 文件的摘录(更改了名称字段以避免任何可能的安全问题。)

    <distributionManagement>
<repository>
<id>central</id>
<name>my_computer-releases</name>
<url>http://localhost:8081/artifactory/libs-release-local</url>
</repository>
<snapshotRepository>
<id>snapshots</id>
<name>my_computer-snapshots</name>
<url>http://localhost:8081/artifactory/libs-snapshot-local</url>
</snapshotRepository>
</distributionManagement>

这是我的settings.xml 文件(已更改加密密码信息)

   <?xml version="1.0" encoding="UTF-8"?>
<settings xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.1.0 http://maven.apache.org/xsd/settings-1.1.0.xsd" xmlns="http://maven.apache.org/SETTINGS/1.1.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<servers>
<server>
<username>${security.getCurrentUsername()}</username>
<password>${security.getEscapedEncryptedPassword()!"[EncryptedPasswordHere]"}</password>
<id>central</id>
</server>
<server>
<username>${security.getCurrentUsername()}</username>
<password>${security.getEscapedEncryptedPassword()!"[EncryptedPasswordHere]"}</password>
<id>snapshots</id>
</server>
</servers>
<profiles>
<profile>
<repositories>
<repository>
<snapshots>
<enabled>false</enabled>
</snapshots>
<id>central</id>
<name>libs-release</name>
<url>http://localhost:8081/artifactory/libs-release</url>
</repository>
<repository>
<snapshots />
<id>snapshots</id>
<name>libs-snapshot</name>
<url>http://localhost:8081/artifactory/libs-snapshot</url>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<snapshots>
<enabled>false</enabled>
</snapshots>
<id>central</id>
<name>libs-release</name>
<url>http://localhost:8081/artifactory/libs-release</url>
</pluginRepository>
<pluginRepository>
<snapshots />
<id>snapshots</id>
<name>libs-snapshot</name>
<url>http://localhost:8081/artifactory/libs-snapshot</url>
</pluginRepository>
</pluginRepositories>
<id>artifactory</id>
</profile>
</profiles>
<activeProfiles>
<activeProfile>artifactory</activeProfile>
</activeProfiles>
</settings>

最佳答案

如果功能正常。我想这个问题大可不必担心。它只是提示某些库的 pom xml 由于某种原因可能是空的。

关于java - Artifactory 启动时抛出异常 : "No content to map due to end-of-input",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/56282329/

35 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com