Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CET save issue for CrudListenerScripts during upgradation of module installed . #739

Closed
masumcse1 opened this issue Jul 17, 2023 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@masumcse1
Copy link
Contributor

masumcse1 commented Jul 17, 2023

issue with CET's CrudListenerScripts
if we add a new CET and add a new CrudListenerScript for it, it is not possible to upgrade the module installed on another meveo instance

To Reproduce
After install a meveo module in two meveo instance then add a new CET with add a new CrudListenerScript and push the changes to github then pull from the other meveo instance , it will generate this error.

Error Log :

2023-07-04 01:48:16,967 ERROR [org.jboss.as.ejb3.invocation] (default task-1) WFLYEJB0034: EJB Invocation failed on component CustomEntityTemplateApi for
method public org.meveo.model.IEntity org.meveo.api.CustomEntityTemplateApi.createOrUpdate(org.meveo.api.dto.BaseEntityDto)
throws org.meveo.api.exception.MeveoApiException,org.meveo.admin.exception.BusinessException:
javax.ejb.EJBTransactionRolledbackException: Script com.unikbase.rfid.NFCTagListenerScript does not exists
at org.jboss.as.ejb3@18.0.0.Final//org.jboss.as.ejb3.tx.CMTTxInterceptor.invokeInCallerTx(CMTTxInterceptor.java:203)
Caused by: java.lang.IllegalArgumentException: Script com.unikbase.rfid.NFCTagListenerScript does not exists
at deployment.meveo.war//org.meveo.api.CustomEntityTemplateApi.fromDTO(CustomEntityTemplateApi.java:648).

Root Casue

when prepare CustomEntityTemplate object on that time need to initialize --crudEventListenerScript attribute ,
it is depend on a scriptinstance .but this dependent object is not persist already .
for this reason it gives giving null value.

image

Solution
Need to update a CET if (cetDto.getCrudEventListenerScript() != null) after complete installation of all module item .

@masumcse1 masumcse1 added the bug Something isn't working label Jul 17, 2023
@masumcse1 masumcse1 self-assigned this Jul 17, 2023
masumcse1 added a commit to masumcse1/meveo that referenced this issue Jul 17, 2023
@masumcse1 masumcse1 mentioned this issue Jul 17, 2023
@masumcse1 masumcse1 changed the title CET save issue for CrudListenerScripts during upgradation of module installed on meveo instance. CET save issue for CrudListenerScripts during upgradation of module installed . Jul 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant