[JBoss-user] [EJB 3.0] - Re: Question about merge

2006-05-25 Thread yantriki
How do I use a mappedBy for a PK which is composite and one of the fields in the composite key (that forms a FK relationship) needs to be mapped: | Module { | @Id int moduleID | | @OneToMany(cascade=CascadeType.ALL,fetch=FetchType.EAGER,mappedBy=?) | @MapKey(name=name |

[JBoss-user] [EJB 3.0] - Re: Question about merge

2006-05-25 Thread yantriki
The following seems to work for me: | @Entity | @Table(name = ModuleProperty) | public class ModuleProperty implements Serializable { | | /** | * | */ | private static final long serialVersionUID = 1L; | | ModulePropertyPK id; | | Module

[JBoss-user] [EJB 3.0] - Re: Question about merge

2006-05-24 Thread yantriki
My test fails on the testModifyModules. Is there something that I am doing wrong? Following is my Stateless Bean: /* | * Created on May 23, 2006 | * | * This distribution may include materials developed by third parties. | * | * Copyright (c) 2004 Vivek Srivastav. All rights

[JBoss-user] [EJB 3.0] - Re: Question about merge

2006-05-24 Thread yantriki
I get the following trace: junit.framework.AssertionFailedError: Test Failed: RuntimeException:org.jboss.tm.JBossRollbackException: Unable to commit, tx=TransactionImpl:XidImpl[FormatId=257, GlobalId=OPT0051/244, BranchQual=, localId=244] status=STATUS_NO_TRANSACTION; - nested throwable:

[JBoss-user] [EJB 3.0] - Re: Question about merge

2006-05-24 Thread yantriki
Here is my persistence.xml file. | persistence | persistence-unit name=test | jta-data-sourcejava:/DefaultDS/jta-data-source | classorg.test.ejb3.eb.Module/class | classorg.test.ejb3.eb.ModulePropertyPK/class |

[JBoss-user] [EJB 3.0] - Re: How could Service POJO depends on session bean

2006-05-24 Thread yantriki
Add the following to jboss-service.xml jboss.j2ee:service=EJB3,ear=yourApp.ear,jar=yourApp.ejb3,name=ModuleBean or use the @Depends annotation View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3946251#3946251 Reply to the post :

[JBoss-user] [EJB 3.0] - Question about merge

2006-05-23 Thread yantriki
I want to modify the ModuleProperty collection of the Module class and then merge it back. When I use the | public Module updateModule(Module module){ |em.merge(module) ; |return module; | } | in my stateless session bean, it throws exception (attached at the bottom of the

[JBoss-user] [EJB 3.0] - Re: TransactionManager not found

2006-05-16 Thread yantriki
http://www.jboss.com/index.html?module=bbop=viewtopicp=3939453 View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3943204#3943204 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3943204

[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Re: Error: Could not execute JDBC batch update NonSpecificEx

2006-05-13 Thread yantriki
The Warning went away after adding the dependency in the ejb-timer-service.xml. I wm wondering if the following settings have anything to do with the JDBC batch update failure: 12:29:13,203 INFO [SettingsFactory] Automatic flush during beforeCompletion(): disabled | 12:29:13,203 INFO

[JBoss-user] [Security JAAS/JBoss] - Re: @SecurityDomain in JBoss4.0.4RC1

2006-03-01 Thread yantriki
I can see the security domain loaded in the JBoss in the XMLLoginConfig MBean's displayAppConfig method and I am not using the jboss-app.xml file. Here's how my code defined import java.util.HashSet; | import java.util.List; | import java.util.Set; | | import

[JBoss-user] [Security JAAS/JBoss] - Re: @SecurityDomain in JBoss4.0.4RC1

2006-03-01 Thread yantriki
cgriffith, Your idea about the META-INF file helped me point in the right direction. Removing the META-INF/jboss.xml file from ejb3 jar seems to fix the problem. vivek View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3927184#3927184 Reply to the post :

[JBoss-user] [Security JAAS/JBoss] - @SecurityDomain in JBoss4.0.4RC1

2006-02-28 Thread yantriki
I don't see any security/roles etc level message during the the deployment . My EJB seems to be defaulting to UserPasswordLoginModule, although I have another login module configured for the domain that I am using. I used to get the adding authorization privileges messages in 4.0.3SP1, and it

[JBoss-user] [EJB 3.0] - Re: What's wrong with the following OR mapping?

2006-02-24 Thread yantriki
Bill, Thanks for the clarification. Regards Vivek anonymous wrote : | | EJB Persistence spec section 2.1.1 | | When annotations are used, the placement of the mapping annotations on either the persistent fields or persistent properties of the entity class specifies the access type

[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Re: JBoss is not using data from my postgres-ds.xml

2006-02-24 Thread yantriki
Try removing security-domainPostgressDBRealm/security-domain and add password/password to you postgress-ds.xml file If you use security domain, the configuration in ${jboss.server.home.dir}/conf/login-config.xml file is used for authentication. Vivek View the original post :

[JBoss-user] [EJB 3.0] - Re: What's wrong with the following OR mapping?

2006-02-23 Thread yantriki
just want to point out that I have a variable of ModuleType defined in the Module class. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3925860#3925860 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3925860

[JBoss-user] [EJB 3.0] - Re: What's wrong with the following OR mapping?

2006-02-23 Thread yantriki
ok I fixed it by moving the @OneToMany annotation over the field rather than the getter method. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3925913#3925913 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3925913

[JBoss-user] [EJB 3.0] - JBoss 4.0.4RC1 : Tables not found in database

2006-02-23 Thread yantriki
When I deploy my application I get the following message. However when I check the database I don't see the tables in the database. The first time I tried to deploy the application there were a few tables created, but after that on subsequent deployment I am not getting any tables created in

[JBoss-user] [EJB 3.0] - Re: JBoss 4.0.4RC1 : Tables not found in database

2006-02-23 Thread yantriki
When I use hypersonic default database with the following persistence.xml, I see all the table created in the database: persistence | persistence-unit name=ccor | jta-data-sourcejava:/DefaultDS/jta-data-source | classorg.vss.ejb3.eb.ElementType/class |

[JBoss-user] [EJB 3.0] - Re: Problem with ejb and Servlet

2006-02-23 Thread yantriki
Yogendra, The annotations are @Remote and @Local for local and remote binding. Vivek View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3925925#3925925 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3925925

[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Tables not being created in MSDE data engine

2006-02-23 Thread yantriki
When I deploy my application I get the following message. However when I check the database I don't see the tables in the database. The first time I tried to deploy the application there were a few tables created, but after that on subsequent deployment I am not getting any tables created in

[JBoss-user] [EJB 3.0] - association table on a single ended association is not yet s

2006-02-21 Thread yantriki
Caused by: org.hibernate.cfg.NotYetImplementedException: association table on a single ended association is not yet supported What does it mean? View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3925438#3925438 Reply to the post :

[JBoss-user] [Management, JMX/JBoss] - JBossMX deployment extension file name? new deployer?

2006-01-24 Thread yantriki
If I want to deploy Annotation based service (@Service rather than using META-INF/jboss-service.xml, I have to name the extension .ejb3 for it to deploy and work. It seems like if I name it .sar it never looks for @Service annotated classes. Now I need to deploy a service archieve which is

[JBoss-user] [Management, JMX/JBoss] - Re: Have you coded a cool MBean service you want to share?

2006-01-20 Thread yantriki
I tried the UserAccounts service. When deployed it on 4.0.3SP1, it failed to deploy the org.ii.jaas.har archive. It expected the jboss-service.xml file to be present. After packaging hibernate-service.xml as META-INF/jboss-service.xml in the har file, I was able to deploy it. However when

[JBoss-user] [EJB/JBoss] - There is really no way in 4.0.3SP1

2006-01-20 Thread yantriki
I tried to access a stateless session bean from a service. I can't typecast the object I obtain by lookup to the Session Bean's remote interface. I get ClassCastException: $187Proxy (or something like that), when typecasting. So I assume it's a Class Loader issue. When I remove the remote

[JBoss-user] [EJB 3.0] - Re: How to access Stateless Session bean from within MBean S

2006-01-19 Thread yantriki
I am using the appropriate class to typecast. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3918507#3918507 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3918507 ---

[JBoss-user] [EJB 3.0] - Re: ClassCastException/Entity Bean Remoting

2006-01-18 Thread yantriki
I fixed it by removing ejb3Test-client.jar from the war file. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3918164#3918164 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3918164

[JBoss-user] [EJB 3.0] - Re: SecurityDomain with EJB3.0

2006-01-18 Thread yantriki
I fixed it with the following META-INF/jboss-service.xml configuration file: ?xml version=1.0 encoding=UTF-8? | server | mbean code=org.jboss.security.auth.login.DynamicLoginConfig |name=corview:service=CORViewJAASService | attribute name=PolicyConfig

[JBoss-user] [EJB 3.0] - Re: SecurityDomain with EJB3.0

2006-01-18 Thread yantriki
The Session Bean uses @SecurityDomain(corview) View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3918167#3918167 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3918167 ---

[JBoss-user] [EJB 3.0] - How to access Stateless Session bean from within MBean Servi

2006-01-17 Thread yantriki
Statement of Problem == How to use to EJB 3.0 Stateless Session Bean from within a JBoss Service. Scenario === 1. I have created a LoginModule which I am packaging as a SAR DynamicConfig MBean. The LoginModule internally calls Stateless Session bean to authenticate userid and

[JBoss-user] [Microcontainer] - Classloader Question

2006-01-17 Thread yantriki
I am stuck on this for days now. Can someone help me with it please. Statement of Problem == How to use to EJB 3.0 Stateless Session Bean from within a JBoss Service. Scenario === 1. I have created a LoginModule which I am packaging as a SAR DynamicConfig MBean. The LoginModule

[JBoss-user] [Management, JMX/JBoss] - Refering to EJB in MBean

2006-01-16 Thread yantriki
Statement of Problem == How to use to EJB 3.0 Stateless Session Bean from within a JBoss Service. Scenario === 1. I have created a LoginModule which I am packaging as a SAR DynamicConfig MBean. The LoginModule internally calls Stateless Session bean to authenticate userid and

[JBoss-user] [EJB 3.0] - Re: Using @Service annotation in eclipse; JBoss EJB 3.0 Serv

2006-01-16 Thread yantriki
Yes, I have the Service tutorial running. Following is my code: | package org.vss.jboss.service; | import org.jboss.annotation.ejb.Management; | | @Management | public interface PollingServiceManagement { | public int getPollInterval(); | | public void

[JBoss-user] [EJB 3.0] - Re: Class Cast Exception with lookup

2006-01-16 Thread yantriki
I have a similar but interesting situation. I am trying to call a Stateless Session Bean within a JBoss service. When I include the interface class file into the SAR, I get ClassCastException, but when I don't, I get NoClassDefFound Exception. What should I do? View the original post :

[JBoss-user] [EJB 3.0] - SecurityDomain with EJB3.0

2006-01-09 Thread yantriki
Hi, I am trying to write an application with the following characteristics: 1. The Session Beans are secured using annotation @SecurityDomain(library) 2. I have written a custom login module which derives from org.jboss.security.auth.spi.UsernamePasswordLoginModule. The login module sar is

[JBoss-user] [EJB 3.0] - Re: SecurityDomain with EJB3.0

2006-01-09 Thread yantriki
Ok, I figured that with 4.0.3 JBoss server the jboss-service.xml defines mechanism to define the application-policy in the SAR deployment xml file itself, which seems to be working for me. So now I get messages that the security is being implemented during deployment time. However I have two

[JBoss-user] [EJB 3.0] - Re: ClassCastException/Entity Bean Remoting

2005-12-20 Thread yantriki
I am getting the same ClassCastException when using entity Bean in JBoss 4.0.3SP1. This only happens when I do a find on primary key using EntityManager's find method. It seems like the object is retrieved appropriately in the ejb-tier, however when returning to the Web-tier there is

[JBoss-user] [EJB 3.0] - Re: Using @Service annotation in eclipse; JBoss EJB 3.0 Serv

2005-12-17 Thread yantriki
Thanks Bill. I appreciate your help. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3913268#3913268 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3913268 --- This SF.net

[JBoss-user] [EJB 3.0] - Re: Using @Service annotation in eclipse; JBoss EJB 3.0 Serv

2005-12-16 Thread yantriki
Kabir, I am unable to deploy the service. When I use the extension .sar, the SARDeployer expects to find jboss-service.xml file. However, if I deploy the file as .ejb3, the service never starts,although it deploys fine. Please, also note that I have renamed the PollingService to

[JBoss-user] [EJB 3.0] - Re: Correct Syntax for Service Bean

2005-12-16 Thread yantriki
I am having the same problem with my EJB 3.0 Service. 1. When I package my Service classes as .ejb3 and deploy it. There is no error, however the lifecycle methods are never called, so I am not sure if my service is getting deployed at all. 2 . When I package the Service classes as .sar file

[JBoss-user] [EJB 3.0] - Re: Using @Service annotation in eclipse; JBoss EJB 3.0 Serv

2005-12-16 Thread yantriki
Amazingly, it was the jboss-ejb3.jar file, which apparently does not have org.jboss.annotation classes available. Once I got these files from the EJB3Trail tutorial, the service deployed smoothly. The Eclipse IDE did not show any error at all about these missing annotation classes and compiled

[JBoss-user] [JBoss Eclipse IDE (users)] - Re: eclipse Jboss IDE + ejb3.0 -- annotation pop-up window

2005-12-10 Thread yantriki
To get the annotation to work, you need JdtApt for annotation processing. Which you can install from: http://www.eclipse.org/jdt/apt/JdtAptUpdateSite Then in the Project-Properties expand Java Compiler and Annotation Processor-Factory Path. Now you need to add the EJB 3.0 annotation processing

[JBoss-user] [EJB 3.0] - EJB 3.0: annotation processing factories

2005-12-10 Thread yantriki
Can anyone tell me which EJB 3.0 jar files contain the annotation processing factories for EJB 3.0 and JBoss extension. You input much appreciated. Regards View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3911929#3911929 Reply to the post :

[JBoss-user] [Beginners Corner] - Re: JBoss as a RMI Server

2005-12-09 Thread yantriki
You need the following: 1. rmi.policy file with the following content grant { // Allow everything for now permission java.security.AllPermission; }; 2. You will need the jboss-client.jar available in JBOSS_HOME/client folder. The jar provides JNDI lookups. 3. In the client

[JBoss-user] [JBoss Eclipse IDE (users)] - Error adding new JBoss configuration in Eclipse

2005-12-09 Thread yantriki
Hi, I am unable to add JBoss configuration. I installed a fresh eclipse IDE from eclipse.org, Updated the JBoss IDE from the sourceforge URL, copied the xdoclet and refreshed it. Now when I went in to add a new JBoss Configuration, if shows up an exception saying Error adding new JBoss

[JBoss-user] [Beginners Corner] - Re: Service in JBoss

2005-12-09 Thread yantriki
Thanks Scott. Ok, so I started reading about JBoss microkernal and realize that I need to write a ServiceMBean. Now the AS document mentions org.jboss.naming.NonSerializableFactory for binding the beans. I could not find the class in any jar file. I searched, albeit, I don't know how good is

[JBoss-user] [JBoss Eclipse IDE (users)] - Re: Error adding new JBoss configuration in Eclipse

2005-12-09 Thread yantriki
Following is the entry in the log file: -- !ENTRY org.eclipse.jface 4 2 2005-12-09 12:51:58.484 !MESSAGE Problems occurred when invoking code from plug-in: org.eclipse.jface. !STACK 0 java.lang.NoSuchMethodError:

[JBoss-user] [JBoss Eclipse IDE (users)] - Re: Error adding new JBoss configuration in Eclipse

2005-12-09 Thread yantriki
OK, so I disabled the JBoss IDE J2EE 1.4 version and installed the development version based on the new update site as mentioned in announcement by Marshall Culpepper. It seems to work. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3911802#3911802 Reply to

[JBoss-user] [EJB 3.0] - Using @Service annotation in eclipse; JBoss EJB 3.0 Service

2005-12-09 Thread yantriki
I don't get any intellisence in Eclipse with the @Service and related annotations. I have JBoss IDE 1.5.0RC1 installed. I assume that intellisence probably is not implemented. However I have following questions: Q1. I am trying to write a JBoss Service using EJB 3.0, where can I read up more

[JBoss-user] [EJB 3.0] - Re: Using @Service annotation in eclipse; JBoss EJB 3.0 Serv

2005-12-09 Thread yantriki
Please help with writing EJB 3.0 Service. I can't get it to deploy. I wrote the following EJB 3.0 Service: | @Service(objectName = ejb3:service=PollingService) | @Management(PollingServiceManagement.class) | public class PollingService implements PollingServiceManagement { | |

[JBoss-user] [Beginners Corner] - Re: Service in JBoss

2005-12-09 Thread yantriki
Need help to understand how to write service using EJB 3.0. Have posted the code in the EJB 3.0 forum: http://www.jboss.org/index.html?module=bbop=viewtopict=73769 Would appreciate any help. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3911876#3911876

[JBoss-user] [Beginners Corner] - Service in JBoss

2005-12-08 Thread yantriki
I want to write an application which is supposed to run as a service and it needs to do periodic tasks [poll some object and collect statistics]. I have following questions: 1. Can I write such an application as service in JBoss. 2. If yes, what happens to lifecycle management am I allowed to

[JBoss-user] [JBoss Portal] - User Portlet and Page Menu portlet on all pages

2005-08-11 Thread yantriki
Is there a way that I can configure the JBoss Portal so that the page menu portlet and the User Portlet is displayed on all the pages. I have installed JBoss forum portlet and when I access the forum, I want to still have access to the user and menu portlets. View the original post :

[JBoss-user] [JBoss Portal] - Re: User Portlet and Page Menu portlet on all pages

2005-08-11 Thread yantriki
I get the following message on the JBoss logs: 11:17:34,390 WARN [RegionTagHandler] requested page has no region [left] Also I tried to minimize the forum portlet, but that's the only portlet on the page. Where is the page layout defined? View the original post :

[JBoss-user] [Installation, Configuration Deployment] - How to test the Mail Service

2005-08-11 Thread yantriki
I have changed the mail-services.xml file to appropriate values, I however would like to test it and make sure that it works. How can I do that? Please don't ask me to write programs. View the original post : http://www.jboss.org/index.html?module=bbop=viewtopicp=3889551#3889551 Reply to the

[JBoss-user] [EJB/JBoss] - need help: JBoss service start before database server causes

2004-10-11 Thread yantriki
Hi All, I am developing a EJB application and plan to deploy JBoss as service. I am using MS SQL as database server. Whenever the JBoss starts earlier than the MS SQL server, it throws createBeanClassInstanceCommand == null exception, cause the database server is not up and any subsequent call

[JBoss-user] [EJB/JBoss] - Please help: Problem with Timestamp datatype in CMP key

2004-08-10 Thread yantriki
Hi All, I am stuck up with a desparate problem. I can write data using my bean but can't read data back (Please see the exception attached). My CMP has a java.sql.Timestamp data in the composit primary key. I think I am doing something wrong with the jdbc-type sql-type mapping, but even after

[JBoss-user] [EJB/JBoss] - Re: Please help: Problem with Timestamp datatype in CMP key

2004-08-10 Thread yantriki
Oops! Following is my EJB finder definitions for CardHistory CMP: * @ejb.finder * signature = java.util.Collection findAllByParamAndCard(java.lang.Integer cardHistoryParamID, java.lang.String serialNo) * query = SELECT OBJECT(p) FROM CardHistory as p WHERE

[JBoss-user] [Beginners Corner] - Is there is News Server for JBoss Forum?

2004-08-10 Thread yantriki
Can I setup a NNTP client like outlook express or Netscape to read the forums listed here? View the original post : http://www.jboss.org/index.html?module=bbop=viewtopicp=3844712#3844712 Reply to the post : http://www.jboss.org/index.html?module=bbop=postingmode=replyp=3844712

[JBoss-user] [EJB/JBoss] - Re: Please help: Problem with Timestamp datatype in CMP key

2004-08-10 Thread yantriki
Another thing I noticed. When I have just one record, I am able to use the CMP bean to read the data. however it throws this exception as soon as there are more than 1 record. View the original post : http://www.jboss.org/index.html?module=bbop=viewtopicp=3844714#3844714 Reply to the post :

[JBoss-user] [EJB/JBoss] - Re: Please help: Problem with Timestamp datatype in CMP key

2004-08-10 Thread yantriki
Hi, I changed the timestamp column to BIGINT and still get the same error. So I think there must be some other problem with my code. 16:26:50,399 ERROR [LogInterceptor] TransactionRolledbackLocalException in method: public abstract java.lang.Long optinel.iface.CardHistoryLocal.getPollTime(),

[JBoss-user] [Persistence CMP/JBoss] - Re: Composite key -CMP Bean

2004-08-10 Thread yantriki
Hi anil, Did you find the solution to your composite key problem. I am also having the same problem. I however can write records to table, but it crashes on me whenever I try to read the record. I struggled with it for a while before I realized it's the composite key problem. I was for a long