08-10-2011 05:20 AM
Hi,
I have written a sample app using Junos Space SDK. App gets successfully deployed. But when I check jboss server.log, it gives below error. Could you please point me in right direction where is the problem..
Code :
@Entity
@NamedQueries(value =
{
@NamedQuery(query = "SELECT e FROM Equipment e", name = EquipmentEntity.GET_ALL_EQUIPMETS)
}
)
@Table(name = "Equipment", uniqueConstraints = {
@UniqueConstraint(columnNames = "id") })
@ManagedObject({"vnd.techmjunosteam.samplejunosapp
Exception:
ObjectName: persistence.units:ear=SampleJunosApp.ear,jar=Sampl
State: FAILED
Reason: javax.persistence.PersistenceException: org.hibernate.HibernateException: Errors in named queries: vnd.techmjunosteam.samplejunosapp.jpa.AllEquipment
I Depend On:
jboss.jca:service=DataSourceBinding,name=SampleJun
Depends On Me:
jboss.j2ee:ear=SampleJunosApp.ear,jar=SampleJunosA
ObjectName: jboss.j2ee:ear=SampleJunosApp.ear,jar=SampleJunosA
State: FAILED
Reason: javax.management.InstanceNotFoundException: jboss.mq:service=DestinationManager is not registered.
ObjectName: jboss.j2ee:ear=SampleJunosApp.ear,jar=SampleJunosA
State: NOTYETINSTALLED
I Depend On:
persistence.units:ear=SampleJunosApp.ear,jar=Sampl
--- MBEANS THAT ARE THE ROOT CAUSE OF THE PROBLEM ---
ObjectName: jboss:service=RDMEventManager
State: NOTYETINSTALLED
Depends On Me:
jboss:service=HASingletonController
Regards
Satish
08-10-2011 05:48 AM
Hi Satish,
Looks like your application is not really installed. Can you please go to the Junos Space console and type
rpm -qa |grep Sample and see if the app is installed. Can you access your App in UI?
Also, go to Web UI , Platform ->Administration -> manage Applications and see if your application is listed.
Thanks
Yesh
08-10-2011 06:11 AM
Yesh,
Yes application is deployed and one of the two tasks works. When I click on second task, it throws an exception. But before I do this, I find this error related to second tasks in server log.
08-10-2011 11:25 PM
HI Satish,
To get it working, the name of the Entity class should also be 'Equipment'.
<<<
@NamedQueries(value =
{
@NamedQuery(query = "SELECT e FROM Equipment e", name = EquipmentEntity.GET_ALL_EQUIPMETS)
}
)
>>>
Regards
Yesh
08-11-2011 04:10 AM
Thanks Yesh. As you suggested, we maded change and problem has been resolved.
Now all the problems are resolved.
But when I deploy our own sample application, application is not shown on mainui screen. I can see application installed on Junos console using rpm -qa | grep <app name>. It used to get deployed, but suddenly it stopped after we made changes to code.
I am able to deply Junos space sample hello world app. But mine does not get deployed
Can you please help
Regards
Satish
08-11-2011 08:23 AM
HI Satish,
Thanks Satish! Can you see the app in the App selector (Right hand top corner)?? Or in Platform->Administration -> manage Applications.
If yes, then I think you have not configured Module.xml properly to show the icon in Dahsboard.
Plase check.
Thanks
Yesh