0
Fixed

Unable to load an avatar

cphilippe 7 years ago updated by Nguyen 7 years ago 3

Hi,


I'm getting the following error message when trying to upload an avatar:


An unexpected error has occurred. We apologize for the inconvenience. Our team has been notified and will investigate the issue right away. To provide us with the best chance of fixing this problem, please select Yes to add the detail description that includes the steps required to reproduce the problem


Here are the logs:

[root@bilbo.localdomain:~/www/mycollab/logs] cat mycollab.out

13:51:23,068 ERROR c.m.w.DesktopApplication:265 - Error
com.vaadin.server.ServerRpcManager$RpcInvocationException: Unable to invoke method click in com.vaadin.shared.ui.button.ButtonServerRpc
at com.vaadin.server.ServerRpcManager.applyInvocation(ServerRpcManager.java:162)
at com.vaadin.server.ServerRpcManager.applyInvocation(ServerRpcManager.java:119)
at com.vaadin.server.communication.ServerRpcHandler.handleInvocation(ServerRpcHandler.java:435)
at com.vaadin.server.communication.ServerRpcHandler.handleInvocations(ServerRpcHandler.java:407)
at com.vaadin.server.communication.ServerRpcHandler.handleRpc(ServerRpcHandler.java:273)
at com.vaadin.server.communication.PushHandler$2.run(PushHandler.java:148)
at com.vaadin.server.communication.PushHandler.callWithUi(PushHandler.java:240)
at com.vaadin.server.communication.PushHandler.onMessage(PushHandler.java:494)
at com.vaadin.server.communication.PushAtmosphereHandler.onMessage(PushAtmosphereHandler.java:87)
at com.vaadin.server.communication.PushAtmosphereHandler.onRequest(PushAtmosphereHandler.java:77)
at org.atmosphere.cpr.AsynchronousProcessor.action(AsynchronousProcessor.java:199)
at org.atmosphere.cpr.AsynchronousProcessor.suspended(AsynchronousProcessor.java:107)
at org.atmosphere.container.Jetty9AsyncSupportWithWebSocket.service(Jetty9AsyncSupportWithWebSocket.java:180)
at org.atmosphere.cpr.AtmosphereFramework.doCometSupport(AtmosphereFramework.java:2075)
at org.atmosphere.websocket.DefaultWebSocketProcessor.dispatch(DefaultWebSocketProcessor.java:571)
at org.atmosphere.websocket.DefaultWebSocketProcessor$3.run(DefaultWebSocketProcessor.java:333)
at org.atmosphere.util.VoidExecutorService.execute(VoidExecutorService.java:101)
at org.atmosphere.websocket.DefaultWebSocketProcessor.dispatch(DefaultWebSocketProcessor.java:328)
at org.atmosphere.websocket.DefaultWebSocketProcessor.invokeWebSocketProtocol(DefaultWebSocketProcessor.java:425)
at org.atmosphere.container.Jetty9WebSocketHandler.onWebSocketText(Jetty9WebSocketHandler.java:125)
at org.eclipse.jetty.websocket.common.events.JettyListenerEventDriver.onTextMessage(JettyListenerEventDriver.java:189)
at org.eclipse.jetty.websocket.common.message.SimpleTextMessage.messageComplete(SimpleTextMessage.java:69)
at org.eclipse.jetty.websocket.common.events.AbstractEventDriver.appendMessage(AbstractEventDriver.java:66)
at org.eclipse.jetty.websocket.common.events.JettyListenerEventDriver.onTextFrame(JettyListenerEventDriver.java:158)
at org.eclipse.jetty.websocket.common.events.AbstractEventDriver.incomingFrame(AbstractEventDriver.java:162)
at org.eclipse.jetty.websocket.common.WebSocketSession.incomingFrame(WebSocketSession.java:376)
at org.eclipse.jetty.websocket.common.extensions.ExtensionStack.incomingFrame(ExtensionStack.java:220)
at org.eclipse.jetty.websocket.common.Parser.notifyFrame(Parser.java:220)
at org.eclipse.jetty.websocket.common.Parser.parse(Parser.java:256)
at org.eclipse.jetty.websocket.common.io.AbstractWebSocketConnection.readParse(AbstractWebSocketConnection.java:679)
at org.eclipse.jetty.websocket.common.io.AbstractWebSocketConnection.onFillable(AbstractWebSocketConnection.java:511)
at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:273)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:95)
at org.eclipse.jetty.io.SelectChannelEndPoint$2.run(SelectChannelEndPoint.java:93)
at org.eclipse.jetty.util.thread.strategy.ExecuteProduceConsume.executeProduceConsume(ExecuteProduceConsume.java:303)
at org.eclipse.jetty.util.thread.strategy.ExecuteProduceConsume.produceConsume(ExecuteProduceConsume.java:148)
at org.eclipse.jetty.util.thread.strategy.ExecuteProduceConsume.run(ExecuteProduceConsume.java:136)
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:671)
at org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:589)
at java.lang.Thread.run(Thread.java:745)
Caused by: java.lang.reflect.InvocationTargetException: null
at sun.reflect.GeneratedMethodAccessor204.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at com.vaadin.server.ServerRpcManager.applyInvocation(ServerRpcManager.java:158)
... 39 common frames omitted
Caused by: com.vaadin.event.ListenerMethod$MethodException: Invocation of method buttonClick in com.mycollab.module.user.ui.components.ImagePreviewCropWindow$$Lambda$163/678316291 failed.
at com.vaadin.event.ListenerMethod.receiveEvent(ListenerMethod.java:533)
at com.vaadin.event.EventRouter.fireEvent(EventRouter.java:200)
at com.vaadin.event.EventRouter.fireEvent(EventRouter.java:163)
at com.vaadin.server.AbstractClientConnector.fireEvent(AbstractClientConnector.java:1015)
at com.vaadin.ui.Button.fireClick(Button.java:377)
at org.vaadin.viritin.button.MButton.fireClick(MButton.java:148)
at com.vaadin.ui.Button$1.click(Button.java:54)
... 43 common frames omitted
Caused by: java.lang.NoClassDefFoundError: Could not initialize class sun.awt.X11GraphicsEnvironment
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:264)
at java.awt.GraphicsEnvironment.createGE(GraphicsEnvironment.java:103)
at java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvironment.java:82)
at java.awt.image.BufferedImage.createGraphics(BufferedImage.java:1181)
at org.imgscalr.Scalr.scaleImage(Scalr.java:2135)
at org.imgscalr.Scalr.resize(Scalr.java:1667)
at com.mycollab.core.utils.ImageUtil.scaleImage(ImageUtil.java:49)
at com.mycollab.module.file.service.impl.EntityUploaderServiceImpl.uploadLogoToStorage(EntityUploaderServiceImpl.java:73)
at com.mycollab.module.file.service.impl.EntityUploaderServiceImpl.upload(EntityUploaderServiceImpl.java:55)
at com.mycollab.module.file.service.impl.UserAvatarServiceImpl.uploadAvatar(UserAvatarServiceImpl.java:70)
at com.mycollab.module.user.accountsettings.profile.view.ProfileReadViewImpl.process(ProfileReadViewImpl.java:122)
at com.mycollab.module.user.ui.components.ImagePreviewCropWindow.lambda$new$efcd8657$1(ImagePreviewCropWindow.java:89)
at sun.reflect.GeneratedMethodAccessor205.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at com.vaadin.event.ListenerMethod.receiveEvent(ListenerMethod.java:510)
... 49 common frames omitted



Under review

Could you try the solution in this thread http://stackoverflow.com/questions/21131855/could-not-initialize-class-sun-awt-x11graphicsenvironment-on-solaris


In your mycollab.sh, find the line eval \"$_RUNJAVA\" -jar $MYCOLLAB_HOME/executor.jar & then try to add eval \"$_RUNJAVA\" -jar $MYCOLLAB_HOME/executor.jar -Djava.awt.headless=true &


Restart the MyCollab then check if the issue is persisted.


Hai Nguyen

Hi,


This issue is fixed.

It seems that was actually linked to the X11 configuration (Dont see any relationship between MyCollab and X11 by the way).

After having copied the .Xauthority file in the root folder, the issue disappeared.


Thanks for your help anyway Hai.


Cheers

Phil

Fixed

You are welcome :)


Hai