Skip to Content
avatar image
Former Member

Exception: model node element cannot be created without a model instance

Hi experts,

I'm making WD app with EJB model. I've done it before but now I have a problem. In the wdDoInit method of the component controller I create model instance and put it in the modelInstanceMap of the component and also the cardinality of my request nodes is 1..1. So I think everything should be fine but I get model node element cannot be created without a model instance error. The only difference from previous cases is that now I use one ejb app as back-end to two different WD apps but the first one is still working. Any ideas will be appreciated. My coding in the wdDoInit method is:

MyModel myModel = new MyModel();
		wdComponentAPI
				.getModelInstanceMap()
				.putDefaultInstance(
						"com.sap.demo.app.wd.models.mymodel.MyModel",
						myModel);

Regards,

Martin

Edited by: musaka on Oct 28, 2009 11:31 AM

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • avatar image
    Former Member
    Oct 28, 2009 at 12:29 PM

    Hi guys,

    I resolved my problem. It turns out that when I'm using common EJB Module with several WD apps I need to pack it in separate EJB Application for each one of them and deploy them on the server. This make sense I just wasn't thinking about that.

    Regards,

    Martin

    Edited by: musaka on Oct 28, 2009 1:29 PM

    Add comment
    10|10000 characters needed characters exceeded