我从框架网站下载了Apache Sling启动jar。我将文件插入文件夹中。使用命令行,我移动到该文件夹(cd
)并运行命令
java -jar org.apache.sling.starter-10.jar
在命令行窗口中,我得到以下内容:
18.04.2018 21:26:26.352 *INFO * [main] Setting sling.home=sling (default)
18.04.2018 21:26:26.354 *INFO * [main] Starting Apache Sling in C:\Users\MyName\Desktop\MyName\Programs and Games\Programming\IDE\Java\Library and Frameworks\Apache Sling\sling
18.04.2018 21:26:26.361 *INFO * [main] Sling Extension Lib Home : C:\Users\\MyName\Desktop\MyName\Programs and Games\Programming\IDE\Java\Library and Frameworks\Apache Sling\sling\ext
18.04.2018 21:26:26.365 *INFO * [main] Checking launcher JAR in folder C:\Users\\MyName\Desktop\MyName\Programs and Games\Programming\IDE\Java\Library and Frameworks\Apache Sling\sling
18.04.2018 21:26:26.395 *INFO * [main] Installing new launcher: jar:file:/C:/Users/MyName/Desktop/MyName/Programs%20and%20Games/Programming/IDE/Java/Library%20and%20Frameworks/Apache%20Sling/org.apache.sling.starter-10.jar!/resources/org.apache.sling.launchpad.base.jar, 5.6.10.2_6_26 (org.apache.sling.launchpad.base.jar.1524079586391)
18.04.2018 21:26:26.398 *INFO * [main] Loading launcher class org.apache.sling.launchpad.base.app.MainDelegate from org.apache.sling.launchpad.base.jar.1524079586391
18.04.2018 21:26:26.399 *INFO * [main] External Libs Home (ext) is null or does not exists.
18.04.2018 21:26:26.448 *INFO * [main] Setting sling.launchpad=C:\Users\MyName\Desktop\MyName\Programs and Games\Programming\IDE\Java\Library and Frameworks\Apache Sling\sling
18.04.2018 21:26:26.449 *INFO * [main] Starting launcher ...
18.04.2018 21:26:26.465 *INFO * [main] HTTP server port: 8080
18.04.2018 21:26:30.976 *INFO * [main] Startup completed
apr 18, 2018 9:26:50 PM org.apache.tika.config.InitializableProblemHandler$3 handleInitializableProblem
WARNING: JBIG2ImageReader not loaded. jbig2 files will be ignored
See https://pdfbox.apache.org/2.0/dependencies.html#jai-image-io
for optional dependencies.
TIFFImageWriter not loaded. tiff files will not be processed
See https://pdfbox.apache.org/2.0/dependencies.html#jai-image-io
for optional dependencies.
J2KImageReader not loaded. JPEG2000 files will not be processed.
See https://pdfbox.apache.org/2.0/dependencies.html#jai-image-io
for optional dependencies.
apr 18, 2018 9:26:51 PM org.apache.tika.config.InitializableProblemHandler$3 handleInitializableProblem
WARNING: org.xerial's sqlite-jdbc is not loaded.
Please provide the jar on your classpath to parse sqlite files.
See tika-parsers/pom.xml for the correct version.
Attempting to load ESAPI.properties via file I/O.
Attempting to load ESAPI.properties as resource file via file I/O.
Not found in 'org.owasp.esapi.resources' directory or file not readable: C:\Users\MyName\Desktop\MyName\Programs and Games\Programming\IDE\Java\Library and Frameworks\Apache Sling\ESAPI.properties
Not found in SystemResource Directory/resourceDirectory: .esapi\ESAPI.properties
Not found in 'user.home' (C:\Users\MyName) directory: C:\Users\MyName\esapi\ESAPI.properties
Loading ESAPI.properties via file I/O failed. Exception was: java.io.FileNotFoundException
Attempting to load ESAPI.properties via the classpath.
SUCCESSFULLY LOADED ESAPI.properties via the CLASSPATH from '/ (root)' using class loader for DefaultSecurityConfiguration class!
Attempting to load validation.properties via file I/O.
Attempting to load validation.properties as resource file via file I/O.
Not found in 'org.owasp.esapi.resources' directory or file not readable: C:\Users\MyName\Desktop\MyName\Programs and Games\Programming\IDE\Java\Library and Frameworks\Apache Sling\validation.properties
Not found in SystemResource Directory/resourceDirectory: .esapi\validation.properties
Not found in 'user.home' (C:\Users\MyName) directory: C:\Users\MyName\esapi\validation.properties
Loading validation.properties via file I/O failed.
Attempting to load validation.properties via the classpath.
SUCCESSFULLY LOADED validation.properties via the CLASSPATH from '/ (root)' using class loader for DefaultSecurityConfiguration class!
问题在于:虽然它打印了“成功加载”#34;当我转到http://localhost:8080或http://localhost:8080/index.html时,它会返回我找不到的页面404错误。欢迎页面不起作用。
以前我使用过JDK 10但是它给了我一个错误,我在网上发现我必须使用JDK 8然后它不再给我那个错误了,现在它似乎工作了,但我上面有这个问题。 我甚至没有安装Apache Felix(因为AEM中的Sling是基本的),因为网站上的入门教程没有问我。
有什么问题?提前感谢您的回答。