java.lang.IllegalArgumentException

If you like a tip written by other Samebug users, mark is as helpful! Marks help our algorithm provide you better solutions and also help other users.
tip

If you're unit testing, you should instantiate only the service and mock the dependencies. If you're testing integration, you should add all the mocking to the configurations file.

You have a different solution? A short tip here would help you and many other users who saw this issue last week.

  • Attempting to upload a global logo results in an error similar to this: {code:none} java.lang.IllegalArgumentException: Content must not be null at org.springframework.util.Assert.notNull(Assert.java:112) at com.atlassian.confluence.pages.attachments.CachingAttachmentDao.getLatestAttachment(CachingAttachmentDao.java:59) at com.atlassian.confluence.pages.DefaultAttachmentManager.getAttachment(DefaultAttachmentManager.java:41) at com.atlassian.confluence.pages.DelegatorAttachmentManager.getAttachment(DelegatorAttachmentManager.java:68) at sun.reflect.GeneratedMethodAccessor388.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:304) at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149) at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:106) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171) at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204) at $Proxy18.getAttachment(Unknown Source) {code} {panel:title=Workaround|borderStyle=solid|borderColor=#3C78B5| titleBGColor=#3C78B5| bgColor=#E7F4FA} Insert the Global Description [manually|http://jira.atlassian.com/browse/CONF-13767?focusedCommentId=139652&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-139652] into your database as suggested in the related issue [CONF-13767|http://jira.atlassian.com/secure/QuickSearch.jspa?searchString=CONF-13767] and then restart your Confluence server. {panel}
    via by Michael Seager [Atlassian],
  • Attempting to upload a global logo results in an error similar to this: {code:none} java.lang.IllegalArgumentException: Content must not be null at org.springframework.util.Assert.notNull(Assert.java:112) at com.atlassian.confluence.pages.attachments.CachingAttachmentDao.getLatestAttachment(CachingAttachmentDao.java:59) at com.atlassian.confluence.pages.DefaultAttachmentManager.getAttachment(DefaultAttachmentManager.java:41) at com.atlassian.confluence.pages.DelegatorAttachmentManager.getAttachment(DelegatorAttachmentManager.java:68) at sun.reflect.GeneratedMethodAccessor388.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:304) at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149) at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:106) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171) at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204) at $Proxy18.getAttachment(Unknown Source) {code} {panel:title=Workaround|borderStyle=solid|borderColor=#3C78B5| titleBGColor=#3C78B5| bgColor=#E7F4FA} Insert the Global Description [manually|http://jira.atlassian.com/browse/CONF-13767?focusedCommentId=139652&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-139652] into your database as suggested in the related issue [CONF-13767|http://jira.atlassian.com/secure/QuickSearch.jspa?searchString=CONF-13767] and then restart your Confluence server. {panel}
    via by Michael Seager [Atlassian],
  • testHtmlExportSpaceWithIncludedImage has failed at least twice recently with the following message: {panel} null junit.framework.AssertionFailedError at junit.framework.Assert.fail(Assert.java:47) at junit.framework.Assert.assertTrue(Assert.java:20) at junit.framework.Assert.assertTrue(Assert.java:27) at com.atlassian.confluence.HtmlExportAcceptanceTest.doHtmlExport(HtmlExportAcceptanceTest.java:318) at com.atlassian.confluence.HtmlExportAcceptanceTest.testHtmlExportSpaceWithIncludedImage(HtmlExportAcceptanceTest.java:164) {panel} The logs contained the following error: {panel} com.atlassian.confluence.importexport.ImportExportException: java.lang.IllegalArgumentException: Content entity object at com.atlassian.confluence.importexport.impl.HtmlExporter.doExportEntity(HtmlExporter.java:203) at com.atlassian.confluence.importexport.impl.HtmlExporter.exportPage(HtmlExporter.java:87) at com.atlassian.confluence.importexport.impl.HtmlExporter.exportSpace(HtmlExporter.java:99) at com.atlassian.confluence.importexport.impl.AbstractRendererExporterImpl.doExport(AbstractRendererExporterImpl.java:86) at com.atlassian.confluence.importexport.impl.HtmlExporter.doExport(HtmlExporter.java:31) at com.atlassian.confluence.importexport.DefaultImportExportManager.exportAs(DefaultImportExportManager.java:112) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:304) at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149) at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:106) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171) at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204) at $Proxy69.exportAs(Unknown Source) at com.atlassian.confluence.importexport.actions.ExportSpaceLongRunningTask$1.doInTransactionWithoutResult(ExportSpaceLongRunningTask.java:87) at org.springframework.transaction.support.TransactionCallbackWithoutResult.doInTransaction(TransactionCallbackWithoutResult.java:33) at org.springframework.transaction.support.TransactionTemplate.execute(TransactionTemplate.java:127) at com.atlassian.confluence.importexport.actions.ExportSpaceLongRunningTask.runInternal(ExportSpaceLongRunningTask.java:58) at com.atlassian.confluence.util.longrunning.ConfluenceAbstractLongRunningTask.run(ConfluenceAbstractLongRunningTask.java:21) at java.lang.Thread.run(Thread.java:595) Caused by: java.lang.IllegalArgumentException: Content entity object at org.springframework.util.Assert.notNull(Assert.java:112) at com.atlassian.confluence.pages.persistence.dao.hibernate.AbstractHibernateAttachmentDao.getLatestVersionsOfAttachments(AbstractHibernateAttachmentDao.java:78) at com.atlassian.confluence.pages.DefaultAttachmentManager.getLatestVersionsOfAttachments(DefaultAttachmentManager.java:63) at com.atlassian.confluence.pages.AbstractAttachmentManager.getAttachment(AbstractAttachmentManager.java:51) at com.atlassian.confluence.pages.DelegatorAttachmentManager.getAttachment(DelegatorAttachmentManager.java:78) at sun.reflect.GeneratedMethodAccessor1193.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:304) at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149) at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:106) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171) at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204) at $Proxy20.getAttachment(Unknown Source) at com.atlassian.confluence.servlet.download.AttachmentUrlParser.getAttachment(AttachmentUrlParser.java:33) at com.atlassian.confluence.importexport.impl.ExportPathUtils.getExportPathFromAttachment(ExportPathUtils.java:76) at com.atlassian.confluence.importexport.impl.ExportPathUtils.constructRelativeExportPath(ExportPathUtils.java:50) at com.atlassian.confluence.importexport.impl.HtmlImageProcessingRule.process(HtmlImageProcessingRule.java:42) at com.opensymphony.module.sitemesh.html.HTMLProcessor$2.tag(HTMLProcessor.java:99) at com.opensymphony.module.sitemesh.html.tokenizer.Parser.parsedTag(Parser.java:303) at com.opensymphony.module.sitemesh.html.tokenizer.Parser.parseFullTag(Parser.java:215) at com.opensymphony.module.sitemesh.html.tokenizer.Parser.parseTag(Parser.java:156) at com.opensymphony.module.sitemesh.html.tokenizer.Parser.start(Parser.java:112) at com.opensymphony.module.sitemesh.html.tokenizer.TagTokenizer.start(TagTokenizer.java:33) at com.opensymphony.module.sitemesh.html.HTMLProcessor.process(HTMLProcessor.java:90) at com.atlassian.confluence.importexport.impl.HtmlImageParser.parse(HtmlImageParser.java:27) at com.atlassian.confluence.importexport.impl.AbstractRendererExporterImpl.exportImages(AbstractRendererExporterImpl.java:141) at com.atlassian.confluence.importexport.impl.HtmlExporter.doExportEntity(HtmlExporter.java:182) ... 22 more {panel} See: https://bamboo.extranet.atlassian.com/build/viewBuildResults.action?buildKey=CONFFUNC-T5PG&buildNumber=2130 https://bamboo.extranet.atlassian.com/browse/CONFFUNC-T5PG-2099 Unfortunately bamboo is lying to us about the number of failures: https://bamboo.extranet.atlassian.com/build/viewTestCaseHistory.action?buildKey=CONFFUNC-T5PG&testClassName=com.atlassian.confluence.HtmlExportAcceptanceTest&testCaseName=testHtmlExportSpaceWithIncludedImage
    via by Don Willis [Atlassian],
  • testHtmlExportSpaceWithIncludedImage has failed at least twice recently with the following message: {panel} null junit.framework.AssertionFailedError at junit.framework.Assert.fail(Assert.java:47) at junit.framework.Assert.assertTrue(Assert.java:20) at junit.framework.Assert.assertTrue(Assert.java:27) at com.atlassian.confluence.HtmlExportAcceptanceTest.doHtmlExport(HtmlExportAcceptanceTest.java:318) at com.atlassian.confluence.HtmlExportAcceptanceTest.testHtmlExportSpaceWithIncludedImage(HtmlExportAcceptanceTest.java:164) {panel} The logs contained the following error: {panel} com.atlassian.confluence.importexport.ImportExportException: java.lang.IllegalArgumentException: Content entity object at com.atlassian.confluence.importexport.impl.HtmlExporter.doExportEntity(HtmlExporter.java:203) at com.atlassian.confluence.importexport.impl.HtmlExporter.exportPage(HtmlExporter.java:87) at com.atlassian.confluence.importexport.impl.HtmlExporter.exportSpace(HtmlExporter.java:99) at com.atlassian.confluence.importexport.impl.AbstractRendererExporterImpl.doExport(AbstractRendererExporterImpl.java:86) at com.atlassian.confluence.importexport.impl.HtmlExporter.doExport(HtmlExporter.java:31) at com.atlassian.confluence.importexport.DefaultImportExportManager.exportAs(DefaultImportExportManager.java:112) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:304) at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149) at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:106) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171) at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204) at $Proxy69.exportAs(Unknown Source) at com.atlassian.confluence.importexport.actions.ExportSpaceLongRunningTask$1.doInTransactionWithoutResult(ExportSpaceLongRunningTask.java:87) at org.springframework.transaction.support.TransactionCallbackWithoutResult.doInTransaction(TransactionCallbackWithoutResult.java:33) at org.springframework.transaction.support.TransactionTemplate.execute(TransactionTemplate.java:127) at com.atlassian.confluence.importexport.actions.ExportSpaceLongRunningTask.runInternal(ExportSpaceLongRunningTask.java:58) at com.atlassian.confluence.util.longrunning.ConfluenceAbstractLongRunningTask.run(ConfluenceAbstractLongRunningTask.java:21) at java.lang.Thread.run(Thread.java:595) Caused by: java.lang.IllegalArgumentException: Content entity object at org.springframework.util.Assert.notNull(Assert.java:112) at com.atlassian.confluence.pages.persistence.dao.hibernate.AbstractHibernateAttachmentDao.getLatestVersionsOfAttachments(AbstractHibernateAttachmentDao.java:78) at com.atlassian.confluence.pages.DefaultAttachmentManager.getLatestVersionsOfAttachments(DefaultAttachmentManager.java:63) at com.atlassian.confluence.pages.AbstractAttachmentManager.getAttachment(AbstractAttachmentManager.java:51) at com.atlassian.confluence.pages.DelegatorAttachmentManager.getAttachment(DelegatorAttachmentManager.java:78) at sun.reflect.GeneratedMethodAccessor1193.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:304) at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149) at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:106) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171) at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204) at $Proxy20.getAttachment(Unknown Source) at com.atlassian.confluence.servlet.download.AttachmentUrlParser.getAttachment(AttachmentUrlParser.java:33) at com.atlassian.confluence.importexport.impl.ExportPathUtils.getExportPathFromAttachment(ExportPathUtils.java:76) at com.atlassian.confluence.importexport.impl.ExportPathUtils.constructRelativeExportPath(ExportPathUtils.java:50) at com.atlassian.confluence.importexport.impl.HtmlImageProcessingRule.process(HtmlImageProcessingRule.java:42) at com.opensymphony.module.sitemesh.html.HTMLProcessor$2.tag(HTMLProcessor.java:99) at com.opensymphony.module.sitemesh.html.tokenizer.Parser.parsedTag(Parser.java:303) at com.opensymphony.module.sitemesh.html.tokenizer.Parser.parseFullTag(Parser.java:215) at com.opensymphony.module.sitemesh.html.tokenizer.Parser.parseTag(Parser.java:156) at com.opensymphony.module.sitemesh.html.tokenizer.Parser.start(Parser.java:112) at com.opensymphony.module.sitemesh.html.tokenizer.TagTokenizer.start(TagTokenizer.java:33) at com.opensymphony.module.sitemesh.html.HTMLProcessor.process(HTMLProcessor.java:90) at com.atlassian.confluence.importexport.impl.HtmlImageParser.parse(HtmlImageParser.java:27) at com.atlassian.confluence.importexport.impl.AbstractRendererExporterImpl.exportImages(AbstractRendererExporterImpl.java:141) at com.atlassian.confluence.importexport.impl.HtmlExporter.doExportEntity(HtmlExporter.java:182) ... 22 more {panel} See: https://bamboo.extranet.atlassian.com/build/viewBuildResults.action?buildKey=CONFFUNC-T5PG&buildNumber=2130 https://bamboo.extranet.atlassian.com/browse/CONFFUNC-T5PG-2099 Unfortunately bamboo is lying to us about the number of failures: https://bamboo.extranet.atlassian.com/build/viewTestCaseHistory.action?buildKey=CONFFUNC-T5PG&testClassName=com.atlassian.confluence.HtmlExportAcceptanceTest&testCaseName=testHtmlExportSpaceWithIncludedImage
    via by Don Willis [Atlassian],
  • Rendering the logo on any page in Confluence relies on the global description existing. If you don't have a global description in your database, trying to access any page will just return a blank page and leave the following error in the logs: {code} 2008-11-17 17:26:49,468 ERROR [[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'] [confluence.util.velocity.VelocityUtils] getRenderedTemplate Error occurred rendering template: /decorators/main.vmd -- url: /confluence/dashboard.action | userName: admin org.apache.velocity.exception.MethodInvocationException: Invocation of method 'getAttachment' in class $Proxy49 threw exception java.lang.IllegalArgumentException: Content entity object should not be null @ /decorators/main.vmd[3,33] at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:286) ... at org.apache.velocity.runtime.directive.VelocimacroProxy.render(VelocimacroProxy.java:194) ... at org.apache.velocity.Template.merge(Template.java:254) at com.atlassian.confluence.util.velocity.VelocityUtils. getRenderedTemplateWithoutSwallowingErrors(VelocityUtils.java:58) at com.atlassian.confluence.util.velocity.VelocityUtils.getRenderedTemplate(VelocityUtils.java:36) at com.atlassian.confluence.util.profiling.ProfilingPageFilter. applyDecoratorUsingVelocity(ProfilingPageFilter.java:133) ... Caused by: java.lang.IllegalArgumentException: Content entity object should not be null at org.springframework.util.Assert.notNull(Assert.java:112) at com.atlassian.confluence.pages.persistence.dao.hibernate.AbstractHibernateAttachmentDao. getLatestVersionsOfAttachments(AbstractHibernateAttachmentDao.java:78) at com.atlassian.confluence.pages.DefaultAttachmentManager. getLatestVersionsOfAttachments(DefaultAttachmentManager.java:63) at com.atlassian.confluence.pages.AbstractAttachmentManager. getAttachment(AbstractAttachmentManager.java:51) at com.atlassian.confluence.pages.AbstractAttachmentManager. getAttachment(AbstractAttachmentManager.java:32) {code}
    via by Matt Ryall,
  • Rendering the logo on any page in Confluence relies on the global description existing. If you don't have a global description in your database, trying to access any page will just return a blank page and leave the following error in the logs: {code} 2008-11-17 17:26:49,468 ERROR [[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'] [confluence.util.velocity.VelocityUtils] getRenderedTemplate Error occurred rendering template: /decorators/main.vmd -- url: /confluence/dashboard.action | userName: admin org.apache.velocity.exception.MethodInvocationException: Invocation of method 'getAttachment' in class $Proxy49 threw exception java.lang.IllegalArgumentException: Content entity object should not be null @ /decorators/main.vmd[3,33] at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:286) ... at org.apache.velocity.runtime.directive.VelocimacroProxy.render(VelocimacroProxy.java:194) ... at org.apache.velocity.Template.merge(Template.java:254) at com.atlassian.confluence.util.velocity.VelocityUtils. getRenderedTemplateWithoutSwallowingErrors(VelocityUtils.java:58) at com.atlassian.confluence.util.velocity.VelocityUtils.getRenderedTemplate(VelocityUtils.java:36) at com.atlassian.confluence.util.profiling.ProfilingPageFilter. applyDecoratorUsingVelocity(ProfilingPageFilter.java:133) ... Caused by: java.lang.IllegalArgumentException: Content entity object should not be null at org.springframework.util.Assert.notNull(Assert.java:112) at com.atlassian.confluence.pages.persistence.dao.hibernate.AbstractHibernateAttachmentDao. getLatestVersionsOfAttachments(AbstractHibernateAttachmentDao.java:78) at com.atlassian.confluence.pages.DefaultAttachmentManager. getLatestVersionsOfAttachments(DefaultAttachmentManager.java:63) at com.atlassian.confluence.pages.AbstractAttachmentManager. getAttachment(AbstractAttachmentManager.java:51) at com.atlassian.confluence.pages.AbstractAttachmentManager. getAttachment(AbstractAttachmentManager.java:32) {code}
    via by Matt Ryall,
  • Steps to reproduce: # In admin panel, click "add global template page" # Copy/past content in from another page, including an image attachment. Note that all looks fine in the editor. # Click save The save action will (silently) fail, and the new template will not appear in the list. This is the relevant error log: {code:java} 2016-02-18 13:06:08,826 WARN [http-bio-8080-exec-3] [xhtml.editor.embed.EditorEmbeddedImageResourceUnmarshaller] unmarshal Error unmarshaling editor embedded image -- referer: http://localhost:8080/confluence/pages/templates2/createpagetemplate.action?key= | url: /confluence/pages/templates2/docreatepagetemplate.action | traceId: 7ce104360fdd84a6 | userName: ad min | action: docreatepagetemplate java.lang.IllegalArgumentException: Content must not be null at org.springframework.util.Assert.notNull(Assert.java:112) at com.atlassian.confluence.pages.attachments.CachingAttachmentDao.getLatestAttachment(CachingAttachmentDao.java:67) at com.atlassian.confluence.pages.DefaultAttachmentManager.getAttachment(DefaultAttachmentManager.java:125) at com.atlassian.confluence.pages.DefaultAttachmentManager.getAttachment(DefaultAttachmentManager.java:91) at com.atlassian.confluence.pages.DelegatorAttachmentManager.getAttachment(DelegatorAttachmentManager.java:101) at com.atlassian.confluence.pages.CachingAttachmentManager.getAttachment(CachingAttachmentManager.java:158) at sun.reflect.GeneratedMethodAccessor668.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:497) at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:307) at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149) at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:106) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171) at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204) at com.sun.proxy.$Proxy132.getAttachment(Unknown Source) at com.atlassian.confluence.content.render.xhtml.editor.embed.EditorEmbeddedImageResourceUnmarshaller.unmarshal(EditorEmbeddedImageResourceUnmarshaller.java:94) at com.atlassian.confluence.content.render.xhtml.editor.embed.EditorEmbeddedImageResourceUnmarshaller.unmarshal(EditorEmbeddedImageResourceUnmarshaller.java:41) at com.atlassian.confluence.content.render.xhtml.UnmarshalMarshalFragmentTransformer.transform(UnmarshalMarshalFragmentTransformer.java:28) at com.atlassian.confluence.content.render.xhtml.transformers.DefaultFragmentTransformer.transformFragment(DefaultFragmentTransformer.java:141) at com.atlassian.confluence.content.render.xhtml.transformers.DefaultFragmentTransformer.transform(DefaultFragmentTransformer.java:123) at com.atlassian.confluence.content.render.xhtml.editor.EditorXhtmlTransformer.transform(EditorXhtmlTransformer.java:45) at com.atlassian.confluence.content.render.xhtml.TransformerChain.transform(TransformerChain.java:33) at com.atlassian.confluence.content.render.xhtml.TransformerChain.transform(TransformerChain.java:33) at com.atlassian.confluence.content.render.xhtml.PluggableTransformerChain.transform(PluggableTransformerChain.java:39) at com.atlassian.confluence.content.render.xhtml.editor.DefaultEditorConverter.convert(DefaultEditorConverter.java:37) at com.atlassian.confluence.content.render.xhtml.DefaultFormatConverter.convertToStorageFormat(DefaultFormatConverter.java:123) at com.atlassian.confluence.plugins.templates.actions.CreatePageTemplateAction.createPageTemplate(CreatePageTemplateAction.java:36) at com.atlassian.confluence.plugins.templates.actions.CreatePageTemplateAction.execute(CreatePageTemplateAction.java:20) at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:168) at com.opensymphony.xwork.interceptor.AroundInterceptor.intercept(AroundInterceptor.java:35) at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:165) at com.atlassian.confluence.core.ConfluenceWorkflowInterceptor.intercept(ConfluenceWorkflowInterceptor.java:58) {code} !image-2016-02-11-16-45-24-485.png|thumbnail! Happens in Chrome, IE and Firefox.
    via by Vanessa Roberts,
  • Steps to reproduce: # In admin panel, click "add global template page" # Copy/past content in from another page, including an image attachment. Note that all looks fine in the editor. # Click save The save action will (silently) fail, and the new template will not appear in the list. This is the relevant error log: {code:java} 2016-02-18 13:06:08,826 WARN [http-bio-8080-exec-3] [xhtml.editor.embed.EditorEmbeddedImageResourceUnmarshaller] unmarshal Error unmarshaling editor embedded image -- referer: http://localhost:8080/confluence/pages/templates2/createpagetemplate.action?key= | url: /confluence/pages/templates2/docreatepagetemplate.action | traceId: 7ce104360fdd84a6 | userName: ad min | action: docreatepagetemplate java.lang.IllegalArgumentException: Content must not be null at org.springframework.util.Assert.notNull(Assert.java:112) at com.atlassian.confluence.pages.attachments.CachingAttachmentDao.getLatestAttachment(CachingAttachmentDao.java:67) at com.atlassian.confluence.pages.DefaultAttachmentManager.getAttachment(DefaultAttachmentManager.java:125) at com.atlassian.confluence.pages.DefaultAttachmentManager.getAttachment(DefaultAttachmentManager.java:91) at com.atlassian.confluence.pages.DelegatorAttachmentManager.getAttachment(DelegatorAttachmentManager.java:101) at com.atlassian.confluence.pages.CachingAttachmentManager.getAttachment(CachingAttachmentManager.java:158) at sun.reflect.GeneratedMethodAccessor668.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:497) at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:307) at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149) at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:106) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171) at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204) at com.sun.proxy.$Proxy132.getAttachment(Unknown Source) at com.atlassian.confluence.content.render.xhtml.editor.embed.EditorEmbeddedImageResourceUnmarshaller.unmarshal(EditorEmbeddedImageResourceUnmarshaller.java:94) at com.atlassian.confluence.content.render.xhtml.editor.embed.EditorEmbeddedImageResourceUnmarshaller.unmarshal(EditorEmbeddedImageResourceUnmarshaller.java:41) at com.atlassian.confluence.content.render.xhtml.UnmarshalMarshalFragmentTransformer.transform(UnmarshalMarshalFragmentTransformer.java:28) at com.atlassian.confluence.content.render.xhtml.transformers.DefaultFragmentTransformer.transformFragment(DefaultFragmentTransformer.java:141) at com.atlassian.confluence.content.render.xhtml.transformers.DefaultFragmentTransformer.transform(DefaultFragmentTransformer.java:123) at com.atlassian.confluence.content.render.xhtml.editor.EditorXhtmlTransformer.transform(EditorXhtmlTransformer.java:45) at com.atlassian.confluence.content.render.xhtml.TransformerChain.transform(TransformerChain.java:33) at com.atlassian.confluence.content.render.xhtml.TransformerChain.transform(TransformerChain.java:33) at com.atlassian.confluence.content.render.xhtml.PluggableTransformerChain.transform(PluggableTransformerChain.java:39) at com.atlassian.confluence.content.render.xhtml.editor.DefaultEditorConverter.convert(DefaultEditorConverter.java:37) at com.atlassian.confluence.content.render.xhtml.DefaultFormatConverter.convertToStorageFormat(DefaultFormatConverter.java:123) at com.atlassian.confluence.plugins.templates.actions.CreatePageTemplateAction.createPageTemplate(CreatePageTemplateAction.java:36) at com.atlassian.confluence.plugins.templates.actions.CreatePageTemplateAction.execute(CreatePageTemplateAction.java:20) at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:168) at com.opensymphony.xwork.interceptor.AroundInterceptor.intercept(AroundInterceptor.java:35) at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:165) at com.atlassian.confluence.core.ConfluenceWorkflowInterceptor.intercept(ConfluenceWorkflowInterceptor.java:58) {code} !image-2016-02-11-16-45-24-485.png|thumbnail! Happens in Chrome, IE and Firefox.
    via by Vanessa Roberts,
    • java.lang.IllegalArgumentException: Content must not be null at org.springframework.util.Assert.notNull(Assert.java:112) at com.atlassian.confluence.pages.attachments.CachingAttachmentDao.getLatestAttachment(CachingAttachmentDao.java:59) at com.atlassian.confluence.pages.DefaultAttachmentManager.getAttachment(DefaultAttachmentManager.java:41) at com.atlassian.confluence.pages.DelegatorAttachmentManager.getAttachment(DelegatorAttachmentManager.java:68) at sun.reflect.GeneratedMethodAccessor388.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:304) at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149) at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:106) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171) at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204) at $Proxy18.getAttachment(Unknown Source)

    Users with the same issue

    osvzsosvzs
    2 times, last one,
    oddodd
    2 times, last one,
    Unknown visitor
    Unknown visitor1 times, last one,
    Unknown visitor
    Unknown visitor1 times, last one,
    mauritiusmauritius
    1 times, last one,
    189 more bugmates