Uploaded image for project: 'PUBLIC - Liferay Sync'
  1. PUBLIC - Liferay Sync
  2. SYNC-1706

Enabling Sync's OAuth authentication may fail under certain circumstances

    Details

    • Affects Portal Version/s:
      6.2.x

      Description

      The following error message may appear on 6.2 EE if the OAuth is enabled but sync-web deploys before OAuth.

      The only time this will be an actual issue is if OAuth is enabled through portlet.properties or Sync's OAuth application instance is deleted.

      02:00:32,143 INFO [localhost-startStop-1][ServiceComponentLocalServiceImpl:361] Upgrading database with indexes.sql
      Loading file:/opt/java/liferay-portal-6.2-ee-sp14/tomcat-7.0.62/temp/5-sync-web/WEB-INF/classes/portlet.properties
      Dec 13, 2016 2:00:33 AM org.apache.catalina.core.ApplicationContext log
      INFO: Initializing Spring root WebApplicationContext
      Loading file:/opt/java/liferay-portal-6.2-ee-sp14/tomcat-7.0.62/temp/5-sync-web/WEB-INF/classes/service.properties
      02:00:33,614 ERROR [localhost-startStop-1][PortletBeanLocatorUtil:42] BeanLocator is null for servlet context oauth-portlet
      02:00:33,616 ERROR [localhost-startStop-1][SyncServletContextListener:171] com.liferay.portal.kernel.bean.BeanLocatorException: BeanLocator has not been set for servlet context oauth-portlet
      com.liferay.portal.kernel.bean.BeanLocatorException: BeanLocator has not been set for servlet context oauth-portlet
      at com.liferay.portal.kernel.bean.PortletBeanLocatorUtil.locate(PortletBeanLocatorUtil.java:46)
      at com.liferay.oauth.service.OAuthApplicationLocalServiceUtil.getService(OAuthApplicationLocalServiceUtil.java:368)
      at com.liferay.oauth.service.OAuthApplicationLocalServiceUtil.fetchOAuthApplication(OAuthApplicationLocalServiceUtil.java:189)
      at com.liferay.sync.service.impl.SyncPreferencesLocalServiceImpl.enableOAuth(SyncPreferencesLocalServiceImpl.java:65)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      at java.lang.reflect.Method.invoke(Method.java:606)
      at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:115)
      at com.liferay.portal.spring.transaction.DefaultTransactionExecutor.execute(DefaultTransactionExecutor.java:62)
      at com.liferay.portal.spring.transaction.TransactionInterceptor.invoke(TransactionInterceptor.java:51)
      at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:111)
      at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
      at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:111)
      at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
      at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:111)
      at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
      at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:111)
      at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
      at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:111)
      at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
      at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:111)
      at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
      at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:111)
      at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
      at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:111)
      at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
      at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:111)
      at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
      at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:111)
      at com.liferay.portal.spring.aop.ServiceBeanAopProxy.invoke(ServiceBeanAopProxy.java:175)
      at com.sun.proxy.$Proxy496.enableOAuth(Unknown Source)
      at com.liferay.sync.service.SyncPreferencesLocalServiceUtil.enableOAuth(SyncPreferencesLocalServiceUtil.java:76)
      at com.liferay.sync.servlet.SyncServletContextListener.doPortalInit(SyncServletContextListener.java:166)
      at com.liferay.portal.kernel.util.BasePortalLifecycle.portalInit(BasePortalLifecycle.java:44)
      at com.liferay.portal.kernel.util.PortalLifecycleUtil.register(PortalLifecycleUtil.java:74)
      at com.liferay.portal.kernel.util.PortalLifecycleUtil.register(PortalLifecycleUtil.java:58)
      at com.liferay.portal.kernel.util.BasePortalLifecycle.registerPortalLifecycle(BasePortalLifecycle.java:54)
      at com.liferay.sync.servlet.SyncServletContextListener.contextInitialized(SyncServletContextListener.java:69)
      at com.liferay.portal.kernel.servlet.SecurePluginContextListener.instantiatingListener(SecurePluginContextListener.java:360)
      at com.liferay.portal.kernel.servlet.SecurePluginContextListener.instantiatingListeners(SecurePluginContextListener.java:163)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      at java.lang.reflect.Method.invoke(Method.java:606)
      at com.liferay.portal.deploy.hot.ServletContextListenerHotDeployListener.doInvokeDeploy(ServletContextListenerHotDeployListener.java:77)
      at com.liferay.portal.deploy.hot.ServletContextListenerHotDeployListener.invokeDeploy(ServletContextListenerHotDeployListener.java:37)
      at com.liferay.portal.deploy.hot.HotDeployImpl.doFireDeployEvent(HotDeployImpl.java:230)
      at com.liferay.portal.deploy.hot.HotDeployImpl.fireDeployEvent(HotDeployImpl.java:96)
      at com.liferay.portal.kernel.deploy.hot.HotDeployUtil.fireDeployEvent(HotDeployUtil.java:28)
      at com.liferay.portal.kernel.servlet.PluginContextListener.fireDeployEvent(PluginContextListener.java:186)
      at com.liferay.portal.kernel.servlet.PluginContextListener.doPortalInit(PluginContextListener.java:170)
      at com.liferay.portal.kernel.util.BasePortalLifecycle.portalInit(BasePortalLifecycle.java:44)
      at com.liferay.portal.kernel.util.PortalLifecycleUtil.register(PortalLifecycleUtil.java:74)
      at com.liferay.portal.kernel.util.PortalLifecycleUtil.register(PortalLifecycleUtil.java:58)
      at com.liferay.portal.kernel.util.BasePortalLifecycle.registerPortalLifecycle(BasePortalLifecycle.java:54)
      at com.liferay.portal.kernel.servlet.PluginContextListener.contextInitialized(PluginContextListener.java:120)
      at com.liferay.portal.kernel.servlet.SecurePluginContextListener.contextInitialized(SecurePluginContextListener.java:151)
      at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:5016)
      at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5528)
      at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
      at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901)
      at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)
      at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:652)
      at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1263)
      at org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1948)
      at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
      at java.util.concurrent.FutureTask.run(FutureTask.java:262)
      at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
      at java.lang.Thread.run(Thread.java:745)
      02:00:33,635 INFO [localhost-startStop-1][HookHotDeployListener:709] Registering hook for sync-web

        Attachments

          Activity

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Days since last comment:
                2 years, 48 weeks, 2 days ago

                Packages

                Version Package
                Connector-3.3.0
                Connector-3.3.1