Ошибка при входе в Alfresco Share

Я слежу за серией уроков Джеффа. Я выполнил шаги, описанные в http://ecmarchitect.com/alfresco-developer-series-tutorials/content/tutorial/tutorial.html. Поскольку у меня нет свободного порта 8080, я дал приведенные ниже команды для репо и общего доступа соответственно.

mvn integration-test -Pamp-to-war -Dmaven.tomcat.port=8081,
mvn integration-test -Pamp-to-war -Dmaven.tomcat.port=8082,

Однако я получаю эту ошибку, когда запускаю URL-адрес: http://localhost:8082/share/page

Your authentication details have not been recognized or Alfresco may not be available at this time.

Ниже приведены трассировка стека и файл share-config-custom.xml.

Куча:

     at freemarker.core.Environment.visit(Environment.java:341)
        at freemarker.core.UnifiedCall.accept(UnifiedCall.java:136)
        at freemarker.core.Environment.visit(Environment.java:265)
        at freemarker.core.IfBlock.accept(IfBlock.java:84)
        at freemarker.core.Environment.visit(Environment.java:265)
        at freemarker.core.Environment.visit(Environment.java:487)
        at freemarker.core.BodyInstruction.accept(BodyInstruction.java:93)
        at freemarker.core.Environment.visit(Environment.java:265)
        at freemarker.core.MixedContent.accept(MixedContent.java:93)
        at freemarker.core.Environment.visit(Environment.java:265)
        at freemarker.core.Macro$Context.runMacro(Macro.java:209)
        at freemarker.core.Environment.visit(Environment.java:694)
        at freemarker.core.UnifiedCall.accept(UnifiedCall.java:116)
        at freemarker.core.Environment.visit(Environment.java:265)
        at freemarker.core.MixedContent.accept(MixedContent.java:93)
        at freemarker.core.Environment.visit(Environment.java:265)
        at freemarker.core.Environment.process(Environment.java:243)
        at org.springframework.extensions.webscripts.processor.FTLTemplateProces
sor.process(FTLTemplateProcessor.java:171)
        at org.springframework.extensions.webscripts.WebTemplateProcessor.execut
eBody(WebTemplateProcessor.java:438)
        at org.springframework.extensions.surf.render.AbstractProcessor.execute(
AbstractProcessor.java:57)
        at org.springframework.extensions.surf.render.RenderService.processTempl
ate(RenderService.java:720)
        at org.springframework.extensions.surf.render.bean.TemplateInstanceRende
rer.body(TemplateInstanceRenderer.java:140)
        at org.springframework.extensions.surf.render.AbstractRenderer.render(Ab
stractRenderer.java:77)
        at org.springframework.extensions.surf.render.bean.PageRenderer.body(Pag
eRenderer.java:85)
        at org.springframework.extensions.surf.render.AbstractRenderer.render(Ab
stractRenderer.java:77)
        at org.springframework.extensions.surf.render.RenderService.renderPage(R
enderService.java:761)
        at org.springframework.extensions.surf.mvc.PageView.dispatchPage(PageVie
w.java:411)
        at org.alfresco.web.site.SlingshotPageView.dispatchPage(SlingshotPageVie
w.java)
        at org.springframework.extensions.surf.mvc.PageView.renderView(PageView.
java:250)
        at org.alfresco.web.site.SlingshotPageView.renderView(SlingshotPageView.
java)
        at org.springframework.extensions.surf.mvc.AbstractWebFrameworkView.rend
erMergedOutputModel(AbstractWebFrameworkView.java:316)
        at org.alfresco.web.site.SlingshotPageView.renderMergedOutputModel(Sling
shotPageView.java)
        at org.springframework.web.servlet.view.AbstractView.render(AbstractView
.java:264)
        at org.alfresco.web.site.SlingshotPageView.render(SlingshotPageView.java
)
        at org.springframework.web.servlet.DispatcherServlet.render(DispatcherSe
rvlet.java:1201)
        at org.springframework.web.servlet.DispatcherServlet.processDispatchResu
lt(DispatcherServlet.java:986)
        at org.springframework.web.servlet.DispatcherServlet.doDispatch(Dispatch
erServlet.java:933)
        at org.springframework.web.servlet.DispatcherServlet.doService(Dispatche
rServlet.java:851)
        at org.springframework.web.servlet.FrameworkServlet.processRequest(Frame
workServlet.java:953)
        at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServl
et.java:844)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:621)
        at org.springframework.web.servlet.FrameworkServlet.service(FrameworkSer
vlet.java:829)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:728)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
icationFilterChain.java:305)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
ilterChain.java:210)
        at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:51
)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
icationFilterChain.java:243)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
ilterChain.java:210)
        at org.alfresco.web.site.servlet.MTAuthenticationFilter.doFilter(MTAuthe
nticationFilter.java:74)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
icationFilterChain.java:243)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
ilterChain.java:210)
        at org.alfresco.web.site.servlet.SecurityHeadersFilter.doFilter(Security
HeadersFilter.java:168)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
icationFilterChain.java:243)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
ilterChain.java:210)
        at org.alfresco.web.site.servlet.CSRFFilter.doFilter(CSRFFilter.java:322
)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
icationFilterChain.java:243)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
ilterChain.java:210)
        at org.alfresco.web.site.servlet.SSOAuthenticationFilter.doFilter(SSOAut
henticationFilter.java:394)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
icationFilterChain.java:243)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
ilterChain.java:210)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperV
alve.java:222)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextV
alve.java:123)
        at org.apache.catalina.authenticator.AuthenticatorBase.invoke(Authentica
torBase.java:502)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.j
ava:171)
        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.j
ava:100)
        at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:
953)
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineVal
ve.java:118)
        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.jav
a:408)
        at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp
11Processor.java:1041)
        at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(
AbstractProtocol.java:603)
        at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoin
t.java:312)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.
java:1142)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor
.java:617)
        at java.lang.Thread.run(Thread.java:745)
Caused by: java.net.ConnectException: Connection refused: connect
        at java.net.DualStackPlainSocketImpl.waitForConnect(Native Method)
        at java.net.DualStackPlainSocketImpl.socketConnect(DualStackPlainSocketI
mpl.java:85)
        at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.ja
va:350)
        at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocket
Impl.java:206)
        at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java
:188)
        at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:172)
        at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
        at java.net.Socket.connect(Socket.java:589)
        at org.apache.http.conn.socket.PlainConnectionSocketFactory.connectSocke
t(PlainConnectionSocketFactory.java:72)
        at org.apache.http.impl.conn.HttpClientConnectionOperator.connect(HttpCl
ientConnectionOperator.java:117)
        ... 149 more
Terminate batch job (Y/N)?
^C
D:\Code_Home\wksp-alfresco-5.0\content-tutorial-share>mvn integration-test -Pamp
-to-war -Dmaven.tomcat.port=8082
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building content-tutorial-share AMP project 1.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- alfresco-maven-plugin:2.0.0:set-version (default-set-version) @ conte
nt-tutorial-share ---
[INFO] Removed -SNAPSHOT suffix from version - 1.0
[INFO] Added timestamp to version - 1.0.1511251415
[INFO]
[INFO] --- build-helper-maven-plugin:1.9.1:add-test-resource (add-env-test-prope
rties) @ content-tutorial-share ---
[INFO]
[INFO] --- maven-resources-plugin:2.7:resources (default-resources) @ content-tu
torial-share ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 3 resources
[INFO] Copying 10 resources to ../content-tutorial-share
[INFO]
[INFO] --- maven-compiler-plugin:3.2:compile (default-compile) @ content-tutoria
l-share ---
[INFO] Nothing to compile - all classes are up to date
[INFO]
[INFO] --- maven-resources-plugin:2.7:testResources (default-testResources) @ co
ntent-tutorial-share ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 2 resources
[INFO] skip non existing resourceDirectory D:\Code_Home\wksp-alfresco-5.0\conten
t-tutorial-share\src\test\properties\local
[INFO]
[INFO] --- maven-resources-plugin:2.7:copy-resources (add-module-properties-to-t
est-classpath) @ content-tutorial-share ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 1 resource to alfresco/module/content-tutorial-share
[INFO]
[INFO] --- maven-resources-plugin:2.7:copy-resources (add-module-config-to-test-
classpath) @ content-tutorial-share ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 4 resources
[INFO]
[INFO] --- maven-compiler-plugin:3.2:testCompile (default-testCompile) @ content
-tutorial-share ---
[INFO] Nothing to compile - all classes are up to date
[INFO]
[INFO] --- maven-surefire-plugin:2.18:test (default-test) @ content-tutorial-sha
re ---
[INFO] Tests are skipped.
[INFO]
[INFO] --- maven-dependency-plugin:2.9:unpack (unpack-alfresco) @ content-tutori
al-share ---
[INFO] Configured Artifact: org.alfresco:share:5.0.c:war
[INFO] Unpacking C:\Users\pa832358\.m2\repository\org\alfresco\share\5.0.c\share
-5.0.c.war to D:\Code_Home\wksp-alfresco-5.0\content-tutorial-share\target\conte
nt-tutorial-share-war with includes "" and excludes ""
[INFO]
[INFO] --- alfresco-maven-plugin:2.0.0:amp (default-amp) @ content-tutorial-shar
e ---
[INFO] Building jar: D:\Code_Home\wksp-alfresco-5.0\content-tutorial-share\targe
t\content-tutorial-share\lib\content-tutorial-share.jar
[INFO] Adding directory to AMP package [ 'D:\Code_Home\wksp-alfresco-5.0\content
-tutorial-share\target\content-tutorial-share' '']
[INFO] Building amp: D:\Code_Home\wksp-alfresco-5.0\content-tutorial-share\targe
t\content-tutorial-share.amp
[INFO]
[INFO] --- alfresco-maven-plugin:2.0.0:install (amps-to-war-overlay) @ content-t
utorial-share ---
   - WARNING: The file '/WEB-INF/lib/slf4j-api-1.7.5.jar' is being overwritten b
y this module. The original has been backed-up to '/WEB-INF/classes/alfresco/mod
ule/backup/76c4c8ea-9351-11e5-b6d7-15ae7dccbdeb.bin'
[INFO]
[INFO] >>> tomcat7-maven-plugin:2.2:run (run-embedded) > process-classes @ conte
nt-tutorial-share >>>
[INFO]
[INFO] --- alfresco-maven-plugin:2.0.0:set-version (default-set-version) @ conte
nt-tutorial-share ---
[INFO] Removed -SNAPSHOT suffix from version - 1.0
[INFO] Added timestamp to version - 1.0.1511251419
[INFO]
[INFO] --- build-helper-maven-plugin:1.9.1:add-test-resource (add-env-test-prope
rties) @ content-tutorial-share ---
[INFO]
[INFO] --- maven-resources-plugin:2.7:resources (default-resources) @ content-tu
torial-share ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 3 resources
[INFO] Copying 10 resources to ../content-tutorial-share
[INFO]
[INFO] --- maven-compiler-plugin:3.2:compile (default-compile) @ content-tutoria
l-share ---
[INFO] Nothing to compile - all classes are up to date
[INFO]
[INFO] <<< tomcat7-maven-plugin:2.2:run (run-embedded) < process-classes @ conte
nt-tutorial-share <<<
[INFO]
[INFO] --- tomcat7-maven-plugin:2.2:run (run-embedded) @ content-tutorial-share
---
[INFO] Running war on http://localhost:8082/content-tutorial-share
[INFO] Creating Tomcat server configuration at D:\Code_Home\wksp-alfresco-5.0\co
ntent-tutorial-share\target\tomcat
[INFO] setting SystemProperties:
[INFO]  java.io.tmpdir=D:\Code_Home\wksp-alfresco-5.0\content-tutorial-share\tar
get
[INFO] create webapp with contextPath: /share
Nov 25, 2015 2:19:56 PM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["http-bio-8082"]
Nov 25, 2015 2:19:57 PM org.apache.catalina.core.StandardService startInternal
INFO: Starting service Tomcat
Nov 25, 2015 2:19:57 PM org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet Engine: Apache Tomcat/7.0.47
Nov 25, 2015 2:20:53 PM org.apache.catalina.core.ApplicationContext log
INFO: No Spring WebApplicationInitializer types detected on classpath
Nov 25, 2015 2:20:54 PM org.apache.catalina.core.ApplicationContext log
INFO: Initializing Spring root WebApplicationContext
2015-11-25 14:21:09,953  INFO  [extensions.webscripts.TemplateProcessorRegistry]
 [localhost-startStop-1] Registered template processor freemarker for extension
ftl
 2015-11-25 14:21:09,968  INFO  [extensions.webscripts.ScriptProcessorRegistry]
[localhost-startStop-1] Registered script processor javascript for extension js
 2015-11-25 14:21:09,969  INFO  [extensions.webscripts.TemplateProcessorRegistry
] [localhost-startStop-1] Registered template processor freemarker for extension
 ftl
 2015-11-25 14:21:09,971  INFO  [extensions.webscripts.ScriptProcessorRegistry]
[localhost-startStop-1] Registered script processor javascript for extension js
 2015-11-25 14:21:16,585  INFO  [extensions.webscripts.DeclarativeRegistry] [loc
alhost-startStop-1] Registered 369 Web Scripts (+0 failed), 383 URLs
 2015-11-25 14:21:16,586  INFO  [extensions.webscripts.DeclarativeRegistry] [loc
alhost-startStop-1] Registered 8 Package Description Documents (+0 failed)
 2015-11-25 14:21:16,586  INFO  [extensions.webscripts.DeclarativeRegistry] [loc
alhost-startStop-1] Registered 0 Schema Description Documents (+0 failed)
 2015-11-25 14:21:16,722  INFO  [extensions.webscripts.AbstractRuntimeContainer]
 [localhost-startStop-1] Initialised Spring Surf Container Web Script Container
(in 6743.375ms)
 2015-11-25 14:21:16,727  INFO  [extensions.webscripts.TemplateProcessorRegistry
] [localhost-startStop-1] Registered template processor freemarker for extension
 ftl
 2015-11-25 14:21:16,729  INFO  [extensions.webscripts.ScriptProcessorRegistry]
[localhost-startStop-1] Registered script processor javascript for extension js
 2015-11-25 14:21:16,944  WARN  [shared_impl.util.LocaleUtils] [localhost-startS
top-1] Locale name in faces-config.xml null or empty, setting locale to default
locale : en_US
 Nov 25, 2015 2:21:18 PM org.apache.catalina.core.ApplicationContext log
INFO: org.tuckey.web.filters.urlrewrite.UrlRewriteFilter INFO: loaded (conf ok)
Nov 25, 2015 2:21:18 PM org.apache.catalina.core.ApplicationContext log
INFO: Initializing Spring FrameworkServlet 'Spring Surf Dispatcher Servlet'
Nov 25, 2015 2:21:18 PM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["http-bio-8082"]
2015-11-25 14:30:35,862  INFO  [web.site.EditionInterceptor] [http-bio-8082-exec
-1] Successfully retrieved license information from Alfresco.

доля-config-custom.xml:

<alfresco-config>
    <!-- Document Library config section -->
    <config evaluator="string-compare" condition="DocumentLibrary">
        <aspects>
            <!-- Aspects that a user can see -->
            <visible>
                <aspect name="sc:webable" />
                <aspect name="sc:productRelated" />
            </visible>
            <!-- Aspects that a user can add. Same as "visible" if left empty -->
            <addable>
            </addable>
            <!-- Aspects that a user can remove. Same as "visible" if left empty -->
            <removeable>
            </removeable>
        </aspects>
        <types>
            <type name="cm:content">
                <subtype name="sc:doc" />
                <subtype name="sc:whitepaper" />
            </type>
            <type name="sc:doc">
                <subtype name="sc:whitepaper" />
            </type>
        </types>
    </config>


    <config evaluator="string-compare" condition="Remote">
        <remote>
            <endpoint>
                <id>alfresco-noauth</id>
                <name>Alfresco - unauthenticated access</name>
                <description>Access to Alfresco Repository WebScripts that do not
                    require authentication</description>
                <connector-id>alfresco</connector-id>
                <endpoint-url>http://localhost:8081/alfresco/s</endpoint-url>
                <identity>none</identity>
            </endpoint>



            <endpoint>
                <id>alfresco</id>
                <name>Alfresco - user access</name>
                <description>Access to Alfresco Repository WebScripts that require
                    user authentication
                </description>
                <connector-id>alfresco</connector-id>
                <endpoint-url>http://localhost:8081/alfresco/s</endpoint-url>
                <identity>none</identity>
            </endpoint>

            <endpoint>
                <id>alfresco-feed</id>
                <name>Alfresco Feed</name>
                <description>Alfresco Feed - supports basic HTTP authentication via
                    the EndPointProxyServlet
                </description>
                <connector-id>http</connector-id>
                <endpoint-url>http://localhost:8081/alfresco/s</endpoint-url>
                <basic-auth>true</basic-auth>
                <identity>none</identity>
            </endpoint>
        </remote>
    </config>
</alfresco-config>

Также обратите внимание, что я могу запустить http://localhost:8081/alfresco/ Пожалуйста, предложите


person user1703096    schedule 25.11.2015    source источник


Ответы (1)


Вам нужно переключить личность на конечной точке alfresco на пользователя, чтобы иметь возможность аутентифицироваться:

            <endpoint>
            <id>alfresco</id>
            <name>Alfresco - user access</name>
            <description>Access to Alfresco Repository WebScripts that require
                user authentication
            </description>
            <connector-id>alfresco</connector-id>
            <endpoint-url>http://localhost:8081/alfresco/s</endpoint-url>
            <identity>user</identity>
        </endpoint>
person Younes Regaieg    schedule 10.12.2015