• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

CORBA.NO_PERMISSION Exception

 
Imran Vohra
Ranch Hand
Posts: 77
Chrome Eclipse IDE Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
When I am trying to run AdviceClient.java, I am getting this exception. Even I changed name of business method from getAdvice() to getMessage(). But its not working.
Can anybody suggest me what are the changes needed?

java.rmi.AccessException: CORBA NO_PERMISSION 0 No; nested exception is:
org.omg.CORBA.NO_PERMISSION: vmcid: 0x0 minor code: 0 completed: No
at com.sun.corba.ee.internal.iiop.ShutdownUtilDelegate.mapSystemException(ShutdownUtilDelegate.java:87)
at javax.rmi.CORBA.Util.mapSystemException(Util.java:65)
at headfirst._AdviceHome_Stub.create(Unknown Source)
at AdviceClient.go(AdviceClient.java:23)
at AdviceClient.main(AdviceClient.java:11)
Caused by: org.omg.CORBA.NO_PERMISSION: vmcid: 0x0 minor code: 0 completed: No
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
at java.lang.reflect.Constructor.newInstance(Constructor.java:274)
at java.lang.Class.newInstance0(Class.java:308)
at java.lang.Class.newInstance(Class.java:261)
at com.sun.corba.ee.internal.iiop.messages.ReplyMessage_1_2.getSystemException(ReplyMessage_1_2.java:93)
at com.sun.corba.ee.internal.iiop.ClientResponseImpl.getSystemException(ClientResponseImpl.java:108)
at com.sun.corba.ee.internal.POA.GenericPOAClientSC.invoke(GenericPOAClientSC.java:136)
at org.omg.CORBA.portable.ObjectImpl._invoke(ObjectImpl.java:457)
... 3 more
 
Sankar Subbiramaniam
Ranch Hand
Posts: 116
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Looks like you have set some method permission on getAdvice() method and the client does not have the necessary rights to call this method.

If you are running the client as mentioned in the book, the client calls will be running with the default principal "guest".

Check the following in the Application Deployment Tool:
1) Select the AdviceBean
2) Select the "Security" tab
3) Select under "Method Permissions", the option "remote"
4) Check the value of "Availability" column for getAdvice() method. It must be "All Users". If not you will get this exception.
(Click on the "Availability" column to select and set values).
 
Imran Vohra
Ranch Hand
Posts: 77
Chrome Eclipse IDE Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I checked that Availabilty column, but it is already set to "ALL Users". And I have not set permission explicitly.
Thanks
 
Sankar Subbiramaniam
Ranch Hand
Posts: 116
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Check the following setting in Deployment Tool:
1) Select your deployed Bean
2) Select Security tab
3) Click on "Deployment settings". Whic option is selected ?

If you have selected the option "Password" - you would get the above exception.

Change your option to "Support Client Choice".

Deploy your application. Hopefully it works after the change.
 
Imran Vohra
Ranch Hand
Posts: 77
Chrome Eclipse IDE Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks buddy. Your reply has solved my problem. But I am wondering how it was changed to "Password" as I have not changed it explicitly.
 
Daniel Nunes
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thannnnnnnnnks Buddy! You helped me also! been struggling with it the whole day...

I think somebody could make a big tutorial on this since many developers have trouble running the AdviceGuy tutorial!
 
Carol Enderlin
drifter
Ranch Hand
Posts: 1364
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There are some helpful notes from the authors on the OReilly site
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic