[MAGNOLIA-385] saving dialogs leads to nullpointer exception Created: 09/May/05  Updated: 17/Mar/09  Resolved: 09/May/05

Status: Closed
Project: Magnolia
Component/s: None
Affects Version/s: None
Fix Version/s: 2.1 Final

Type: Bug Priority: Blocker
Reporter: Philipp Bärfuss Assignee: Philipp Bärfuss
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Template:
Acceptance criteria:
Empty
Task DoD:
[ ]* Doc/release notes changes? Comment present?
[ ]* Downstream builds green?
[ ]* Solution information and context easily available?
[ ]* Tests
[ ]* FixVersion filled and not yet released
[ ]  Architecture Decision Record (ADR)
Bug DoR:
[ ]* Steps to reproduce, expected, and actual results filled
[ ]* Affected version filled
Date of First Response:

 Description   

java.lang.NullPointerException
info.magnolia.cms.servlets.MVCServlet.doGet(MVCServlet.java:90)
info.magnolia.cms.servlets.MVCServlet.doPost(MVCServlet.java:48)

Seams to belong to the same problem:

When I try to edit a page in the sample website I get the following errors:

ERROR info.magnolia.module.admininterface.DialogMVCServlet 07.05.2005 17:37:05 – no config node found for dialog : samplesPageFooter
ERROR info.magnolia.module.admininterface.DialogMVCServlet 07.05.2005 17:37:05 – no dialog found: samplesPageFooter
ERROR info.magnolia.module.admininterface.Store 07.05.2005 18:19:55 – can't instanciate the dialoghandler: selectParagraph
java.lang.NullPointerException
at info.magnolia.module.admininterface.Store.getDialogHandler(Store.java:100)
at info.magnolia.module.admininterface.DialogMVCServlet.getHandler(DialogMVCServlet.java:73)
at info.magnolia.cms.servlets.MVCServlet.doGet(MVCServlet.java:89)
at info.magnolia.cms.servlets.MVCServlet.doPost(MVCServlet.java:48)



 Comments   
Comment by Fabrizio Giustina [ 09/May/05 ]

Hi Philipp
after the dialog refactoring I get this error for most of the dialogs.

I added a better error handling in the code so that at least a specific exception is thrown (instead of NPEs in the log), but I don't know exactly how it is supposed to work (why isn't dialog handler optional?), can you give it a look?

Comment by Philipp Bracher [ 09/May/05 ]

fixed with a ugly workaround in DialogMVCServlet. I will register a new task to remove this:

//TODO remove this code!!! we should register the dialgos during startup
String paragraph = RequestFormUtil.getParameter(request, "mgnlParagraph");
if (StringUtils.isNotEmpty(paragraph))

{ dialogName = "standard"; }

// END of the workaround

Generated at Mon Feb 12 03:16:54 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.