CMDBuild Forum

Request for change - cannot get content of column 'RequestForChange#FlowStatus#Description'

Ho verificato che il workflow di esempio non funziona correttamente né sul sito demo.cmdbuild.org né sulla mia installazione locale con in database demo.

I sintomi sembrano essere identici, la registrazione della scheda Avvia Request for change avviene senza errori sulla GUI, ma guardando i campi della scheda si nota che il campo Request number non viene valorizzato, nonché tutti gli altri campi che dovrebbero essere valorizzati dallo script SYS010.

Analizzando i log ho trovato riscontro di anomalie solo in cmdbuild.log 

INFO  2015-03-08 12:21:49 [cmdbuild] getting all-in-one 'interface org.cmdbuild.services.event.Observer'

INFO  2015-03-08 12:21:49 [cmdbuild] getting all-in-one 'interface org.cmdbuild.services.event.Observer'

INFO  2015-03-08 12:21:49 [workflow] getting process class with id '29398'

INFO  2015-03-08 12:21:49 [workflow] starting process for class 'RequestForChange'

INFO  2015-03-08 12:21:49 [cmdbuild] trying to login user workflow with group null

INFO  2015-03-08 12:21:49 [workflow] pushing event 'WorkflowEvent[type=START,processDefinitionId=Process_requestforchange,processInstanceId=309_Package_requestforchange_Process_requestforchange]' for session '56'

INFO  2015-03-08 12:21:49 [cmdbuild] trying to login user workflow with group null

INFO  2015-03-08 12:21:49 [workflow] pushing event 'WorkflowEvent[type=UPDATE,processDefinitionId=Process_requestforchange,processInstanceId=309_Package_requestforchange_Process_requestforchange]' for session '56'

WARN  2015-03-08 12:21:49 [sql     ] cannot get content of column 'RequestForChange#FlowStatus#Description'

WARN  2015-03-08 12:21:49 [sql     ] cannot get content of column 'RequestForChange#FlowStatus#Description'

INFO  2015-03-08 12:21:49 [workflow] updating activity instance '118_309_Package_requestforchange_Process_requestforchange_RegisterRFC' for process 'RequestForChange'

WARN  2015-03-08 12:21:49 [sql     ] cannot get content of column 'RequestForChange#FlowStatus#Description'

INFO  2015-03-08 12:21:49 [jsonrpc ] Calling url /management/modcard/getcardposition

INFO  2015-03-08 12:21:49 [cmdbuild] getting all-in-one 'interface org.cmdbuild.services.event.Observer'

INFO  2015-03-08 12:21:49 [cmdbuild] getting all-in-one 'interface org.cmdbuild.services.event.Observer'

INFO  2015-03-08 12:21:49 [jsonrpc ] adding condition '{"value":[6],"attribute":"FlowStatus","operator":"in"}' to actual filter 'null'

WARN  2015-03-08 12:21:49 [sql     ] cannot get content of column 'RequestForChange#FlowStatus#Description'

INFO  2015-03-08 12:21:49 [jsonrpc ] Calling url /workflow/getprocessinstancelist

INFO  2015-03-08 12:21:49 [jsonrpc ] adding condition '{"value":[6],"attribute":"FlowStatus","operator":"in"}' to actual filter 'null'

INFO  2015-03-08 12:21:49 [cmdbuild] getting all-in-one 'interface org.cmdbuild.services.event.Observer'

INFO  2015-03-08 12:21:49 [cmdbuild] getting all-in-one 'interface org.cmdbuild.services.event.Observer'

WARN  2015-03-08 12:21:49 [sql     ] cannot get content of column 'RequestForChange#FlowStatus#Description'

WARN  2015-03-08 12:21:49 [sql     ] cannot get content of column 'RequestForChange#FlowStatus#Description'

WARN  2015-03-08 12:21:49 [sql     ] cannot get content of column 'RequestForChange#FlowStatus#Description'

WARN  2015-03-08 12:21:49 [sql     ] cannot get content of column 'RequestForChange#FlowStatus#Description'

WARN  2015-03-08 12:21:49 [sql     ] cannot get content of column 'RequestForChange#FlowStatus#Description'

WARN  2015-03-08 12:21:49 [sql     ] cannot get content of column 'RequestForChange#FlowStatus#Description'

WARN  2015-03-08 12:21:49 [sql     ] cannot get content of column 'RequestForChange#FlowStatus#Description'

WARN  2015-03-08 12:21:49 [sql     ] cannot get content of column 'RequestForChange#FlowStatus#Description'

WARN  2015-03-08 12:21:49 [sql     ] cannot get content of column 'RequestForChange#FlowStatus#Description'

INFO  2015-03-08 12:21:50 [jsonrpc ] Calling url /workflow/getactivityinstance

INFO  2015-03-08 12:21:50 [cmdbuild] getting all-in-one 'interface org.cmdbuild.services.event.Observer'

INFO  2015-03-08 12:21:50 [cmdbuild] getting all-in-one 'interface org.cmdbuild.services.event.Observer'

INFO  2015-03-08 12:21:50 [workflow] getting process class with id '29398'

WARN  2015-03-08 12:21:50 [sql     ] cannot get content of column 'RequestForChange#FlowStatus#Description'

 

Quello che mi è balzato all'occhio è che FlowStatus è un campo  integer, ma nell'errore viene menzionata la Description.

Sul vostro sito di demo solo la prima scheda viene valorizzata con Request number 0, tutte le altre hanno valore nullo. Sulla mia istanza non riesco a valorizzare nemmeno la prima scheda con un request number che non sia nullo.

Spero che la mia segnalazione possa essere ritenuta utile, anche perché senza un esempio funzionante di 

workflow è davvero difficile studiarne il funzionamento ed iniziare ad implementarne qualcuno.

Grazie

Nell'attesa di avere un riscontro per quanto esposto nel mio precedente post,
ho creato un processo elementare che contiene solo due blocchi, il primo è un'attività di registrazione
di una scheda e il secondo è uno script che non fa altro che aggiornare una data relativa ad un attributo datachiusura del processo Incident e aggiornare un campo di testo:
 
datachiusura = Calendar.getInstance();
Description = Description + " - funziona?";
 
Dopo aver caricato il file XPDL avvio il processo Incident e aggiorno tramite GUI i campi che ho selezionato 
nella sezione Extended attributes dell'editor TWE e salvo la scheda.
 
Non ho nessun errore a video ,  ne tanto meno nei log (a parte quel warning già segnalato nel post precedente), ma di fatto quelle due semplici istruzioni contenute nello script sembrano non sortire alcun effetto, così come quelle del vostro wowrflow di esempio della script SYS010.
 
Nè a video, nè nei log riscontro errori.
 
Come si fa in questi casi a tracciare o a fare una sorta di debug delle istruzioni contenute negli script del file XPDL di Shark? Esistono altri file di log?
 
Sto usando CMDBUILD 2.3.0, Tomcat 7, Postgres 9.4, java 1.7.0_75, su Ubuntu Server 14.04
 
Ecco i log (non allego quelli di tomcat e postgres perché non ci sono errori):
 
cmdbuild.log
 
INFO  2015-03-09 15:50:14 [jsonrpc ] Calling url /workflow/saveactivity
INFO  2015-03-09 15:50:14 [cmdbuild] getting all-in-one 'interface org.cmdbuild.services.event.Observer'
INFO  2015-03-09 15:50:14 [cmdbuild] getting all-in-one 'interface org.cmdbuild.services.event.Observer'
INFO  2015-03-09 15:50:14 [workflow] getting process class with id '32115'
INFO  2015-03-09 15:50:14 [workflow] starting process for class 'Incident'
INFO  2015-03-09 15:50:14 [cmdbuild] trying to login user workflow with group null
INFO  2015-03-09 15:50:14 [workflow] pushing event 'WorkflowEvent[type=START,processDefinitionId=Process_incident,processInstanceId=1010_Package_incident_Process_incident]' for session '94'
INFO  2015-03-09 15:50:15 [cmdbuild] trying to login user workflow with group null
INFO  2015-03-09 15:50:15 [workflow] pushing event 'WorkflowEvent[type=UPDATE,processDefinitionId=Process_incident,processInstanceId=1010_Package_incident_Process_incident]' for session '94'
WARN  2015-03-09 15:50:15 [sql     ] cannot get content of column 'Incident#FlowStatus#Description'
WARN  2015-03-09 15:50:15 [sql     ] cannot get content of column 'Incident#FlowStatus#Description'
INFO  2015-03-09 15:50:15 [workflow] updating activity instance '721_1010_Package_incident_Process_incident_Process_incident_act2' for process 'Incident'
WARN  2015-03-09 15:50:15 [sql     ] cannot get content of column 'Incident#FlowStatus#Description'
INFO  2015-03-09 15:50:15 [jsonrpc ] Calling url /management/modcard/getcardposition
INFO  2015-03-09 15:50:15 [cmdbuild] getting all-in-one 'interface org.cmdbuild.services.event.Observer'
INFO  2015-03-09 15:50:15 [cmdbuild] getting all-in-one 'interface org.cmdbuild.services.event.Observer'
INFO  2015-03-09 15:50:15 [jsonrpc ] adding condition '{"value":[6],"attribute":"FlowStatus","operator":"in"}' to actual filter 'null'
WARN  2015-03-09 15:50:15 [sql     ] cannot get content of column 'Incident#FlowStatus#Description'
INFO  2015-03-09 15:50:15 [jsonrpc ] Calling url /workflow/getprocessinstancelist
INFO  2015-03-09 15:50:15 [jsonrpc ] adding condition '{"value":[6],"attribute":"FlowStatus","operator":"in"}' to actual filter 'null'
INFO  2015-03-09 15:50:15 [cmdbuild] getting all-in-one 'interface org.cmdbuild.services.event.Observer'
INFO  2015-03-09 15:50:15 [cmdbuild] getting all-in-one 'interface org.cmdbuild.services.event.Observer'
WARN  2015-03-09 15:50:15 [sql     ] cannot get content of column 'Incident#FlowStatus#Description'
WARN  2015-03-09 15:50:15 [sql     ] cannot get content of column 'Incident#FlowStatus#Description'
WARN  2015-03-09 15:50:15 [sql     ] cannot get content of column 'Incident#FlowStatus#Description'
WARN  2015-03-09 15:50:15 [sql     ] cannot get content of column 'Incident#FlowStatus#Description'
WARN  2015-03-09 15:50:15 [sql     ] cannot get content of column 'Incident#FlowStatus#Description'
WARN  2015-03-09 15:50:15 [sql     ] cannot get content of column 'Incident#FlowStatus#Description'
WARN  2015-03-09 15:50:15 [sql     ] cannot get content of column 'Incident#FlowStatus#Description'
INFO  2015-03-09 15:50:16 [jsonrpc ] Calling url /workflow/getactivityinstance
INFO  2015-03-09 15:50:16 [cmdbuild] getting all-in-one 'interface org.cmdbuild.services.event.Observer'
INFO  2015-03-09 15:50:16 [cmdbuild] getting all-in-one 'interface org.cmdbuild.services.event.Observer'
INFO  2015-03-09 15:50:16 [workflow] getting process class with id '32115'
WARN  2015-03-09 15:50:16 [sql     ] cannot get content of column 'Incident#FlowStatus#Description'
 
Shark.log
2015-03-09 15:50:14,789: SharkUtilities -> synchronizing XPDL cache
2015-03-09 15:50:14,803: Process [key=1010_Package_incident_Process_incident,mgrname=Package_incident#8#Process_incident] is created
2015-03-09 15:50:14,865: process 'Process_incident' started
2015-03-09 15:50:14,865: sending notification for start of process 'Process_incident'
2015-03-09 15:50:15,060: Process [key=1010_Package_incident_Process_incident,mgrname=Package_incident#8#Process_incident] is starting...
2015-03-09 15:50:15,062: Process[key=1010_Package_incident_Process_incident,mgrname=Package_incident#8#Process_incident] - Activity[Process Id=1010_Package_incident_Process_incident, Id=720_1010_Package_incident_Process_incident_Process_incident_act1, ba=null, ActDefId=Process_incident_act1] is created
2015-03-09 15:50:15,063: activity 'Process_incident_act1' started
2015-03-09 15:50:15,064: activity 'Process_incident_act1' closed
2015-03-09 15:50:15,064: Process[key=1010_Package_incident_Process_incident,mgrname=Package_incident#8#Process_incident] - Activity[Process Id=1010_Package_incident_Process_incident, Id=720_1010_Package_incident_Process_incident_Process_incident_act1, ba=null, ActDefId=Process_incident_act1] is completed.
2015-03-09 15:50:15,110: Process[key=1010_Package_incident_Process_incident,mgrname=Package_incident#8#Process_incident] - Activity[Process Id=1010_Package_incident_Process_incident, Id=721_1010_Package_incident_Process_incident_Process_incident_act2, ba=null, ActDefId=Process_incident_act2] is created
2015-03-09 15:50:15,110: activity 'Process_incident_act2' started
2015-03-09 15:50:15,110: sending notification for activity 'Process_incident_act2'
2015-03-09 15:50:15,110: sending notification for update of process 'Process_incident'

come si vede dall’ultimo log di Shark il processo di ferma a 


sending notification for update of process 'Process_incident'
 
e non va oltre.
 
La stessa cosa succede per il vostro workflow di esempio, si blocca a 

sending notification for update of process 'Process_requestforchange'
 
Non posso ovviamente accedere ai log del vostro server di demo http://demo.cmdbuild.org/
ma scommetto che lì sta succedendo più o meno la stessa cosa.
 
Il workflow deomo RequestForChange sul vostro sito si blocca all'update della scheda e non esegue lo script SYS010, proprio come avviene sulla mia istanza locale con il database di demo.
La scheda web viene registrata senza comunicazione di errori (come nel mio caso), ma di fatto 
tutti i campi che dovrebbero essere valorizzati dallo script SYS010 non lo sono.
 
RFCStartDate = Calendar.getInstance();
RequestNumber = cmdb.callFunction("cmwf_getRFCNumber").execute().get("RFCNumber");
Description = "RFC n. " + RequestNumber.toString() + " created by " + Requester.getDescription() + " date " + RFCStartDate.getTime().toString();
RFCStatus = cmdb.selectLookupByCode("RFC status", "REC_RFC");
 
 
Per cortesia potrei avere qualche indicazione su come continuare il troubleshooting?
 
Grazie

Ho verificato nuovamente tutti i file di log dopo averli cancellati ed effettuato un restart dei servizi.

Ho notato che ogni volta che effettuo il login all'applicazione  ho questo errore in cmdbuild.log

ERROR 2015-03-10 15:20:26 [jsonrpc ] Error retrieving start activity for process in cmdbuild.log
 
L'errore non si presenta mentre cerco di eseguire il workflow.
 
 
 
 
 
 
Ho effettuato una nuova installazione utilizzando software diversi, ma il risultato è identico.

Sul server utilizzato fino ad ora ho:
CMDBUILD 2.3.0, Tomcat 7, Postgres 9.4, java 1.7.0_75, su Ubuntu Server 14.04.

Sul nuovo server:
Sto usando CMDBUILD 2.3.0, Tomcat 7, Postgres 9.3, java 1.7.0_75, su CentOS 7.

Su entrambi i server:

1) ogni volta che effettuo il login all'applicazione  ho questo errore in cmdbuild.log

ERROR  [jsonrpc ] Error retrieving start activity for process in cmdbuild.log
 
   2) Avvio il processo Request for change e salvo la scheda senza avere errori a video
   3) la prima attività del processo RegisterRFC viene avviata ma non viene completata, il log si fermano a:
 
2015-03-11 17:49:52,936: activity 'RegisterRFC' started
2015-03-11 17:49:52,936: sending notification for activity 'RegisterRFC'
2015-03-11 17:49:52,936: sending notification for update of process 'Process_requestforchange'
 
non arrivando mai ad eseguire lo script SYS010
 
4) vengono registrati sistematicamente warning in cmdbuild.log del tipo
 
WARN  2015-03-11 17:49:53 [sql     ] cannot get content of column 'RequestForChange#FlowStatus#Description'
 
lo stesso avviene anche su altri workflow che disegno, c'è sempre l'avviso su #FlowStatus#Description
 
5) Gli stessi risultati li ottengo anche nel caso di workflow disegnati da me.
 
Poiché ho lo stesso comportamento su due piattaforme differenti e sul vostro sito demo.cmdbuild.org il workflow non funziona correttamente in quanto non vengono valorizzati i campi RFCStartDate , RequestNumber, Description e RFCStatus penso sia un bug.
 
In ogni caso chiedo cortesemente di avere un riscontro di quanto riportato.
Grazie