[jboss-cvs] JBossAS SVN: r62545 - in branches/Branch_4_2: ejb3/src/main/org/jboss/ejb3/security and 5 other directories.

jboss-cvs-commits at lists.jboss.org jboss-cvs-commits at lists.jboss.org
Wed Apr 25 09:59:14 EDT 2007


Author: wolfc
Date: 2007-04-25 09:59:14 -0400 (Wed, 25 Apr 2007)
New Revision: 62545

Removed:
   branches/Branch_4_2/ejb3x/src/main/javax/ejb/AccessMode.java
Modified:
   branches/Branch_4_2/ejb3/src/main/org/jboss/ejb/InitImpl.java
   branches/Branch_4_2/ejb3/src/main/org/jboss/ejb3/security/Ejb3AuthenticationInterceptor.java
   branches/Branch_4_2/ejb3/src/main/org/jboss/ejb3/security/RoleBasedAuthorizationInterceptor.java
   branches/Branch_4_2/ejb3/src/main/org/jboss/ejb3/tx/Ejb3TxPolicy.java
   branches/Branch_4_2/ejb3x/
   branches/Branch_4_2/ejb3x/src/main/javax/ejb/ActivationConfigProperty.java
   branches/Branch_4_2/ejb3x/src/main/javax/ejb/EJB.java
   branches/Branch_4_2/ejb3x/src/main/javax/ejb/EJBAccessException.java
   branches/Branch_4_2/ejb3x/src/main/javax/ejb/EJBTransactionRolledbackException.java
   branches/Branch_4_2/ejb3x/src/main/javax/ejb/Init.java
   branches/Branch_4_2/j2ee/
   branches/Branch_4_2/j2ee/src/main/javax/ejb/SessionContext.java
Log:
EJBTHREE-950: merged trunk

Modified: branches/Branch_4_2/ejb3/src/main/org/jboss/ejb/InitImpl.java
===================================================================
--- branches/Branch_4_2/ejb3/src/main/org/jboss/ejb/InitImpl.java	2007-04-25 13:53:31 UTC (rev 62544)
+++ branches/Branch_4_2/ejb3/src/main/org/jboss/ejb/InitImpl.java	2007-04-25 13:59:14 UTC (rev 62545)
@@ -21,7 +21,7 @@
  */
 package org.jboss.ejb;
 
-import java.util.ArrayList;
+import java.lang.annotation.Annotation;
 
 /**
  * // *
@@ -31,28 +31,25 @@
  */
 public class InitImpl implements javax.ejb.Init
 {
-   private ArrayList values = new ArrayList();
+   private String value = "";
 
    public InitImpl()
    {
 
    }
 
-   public void addValue(String value)
+   public String value()
    {
-      values.add(value);
+      return value;
    }
 
-   public String[] value()
+   public Class<? extends Annotation> annotationType()
    {
-      String[] result = new String[values.size()];
-      values.toArray(result);
-
-      return result;
+      return javax.ejb.Init.class;
    }
-
-   public Class annotationType()
+   
+   public void setValue(String s)
    {
-      return javax.ejb.Init.class;
+      this.value = s;
    }
 }
\ No newline at end of file

Modified: branches/Branch_4_2/ejb3/src/main/org/jboss/ejb3/security/Ejb3AuthenticationInterceptor.java
===================================================================
--- branches/Branch_4_2/ejb3/src/main/org/jboss/ejb3/security/Ejb3AuthenticationInterceptor.java	2007-04-25 13:53:31 UTC (rev 62544)
+++ branches/Branch_4_2/ejb3/src/main/org/jboss/ejb3/security/Ejb3AuthenticationInterceptor.java	2007-04-25 13:59:14 UTC (rev 62545)
@@ -64,7 +64,8 @@
 
    protected void handleGeneralSecurityException(GeneralSecurityException gse)
    {
-      throw new EJBAccessException("Authentication failure", gse);
+      log.debug("Authentication failure", gse);
+      throw new EJBAccessException("Authentication failure");
    }
 
    public Object invoke(org.jboss.aop.joinpoint.Invocation invocation) throws Throwable

Modified: branches/Branch_4_2/ejb3/src/main/org/jboss/ejb3/security/RoleBasedAuthorizationInterceptor.java
===================================================================
--- branches/Branch_4_2/ejb3/src/main/org/jboss/ejb3/security/RoleBasedAuthorizationInterceptor.java	2007-04-25 13:53:31 UTC (rev 62544)
+++ branches/Branch_4_2/ejb3/src/main/org/jboss/ejb3/security/RoleBasedAuthorizationInterceptor.java	2007-04-25 13:59:14 UTC (rev 62545)
@@ -109,7 +109,8 @@
       }
       catch (SecurityException throwable)
       {
-         throw new EJBAccessException("Authorization failure", throwable);
+         log.debug("Authorization failure", throwable);
+         throw new EJBAccessException("Authorization failure");
       } finally {
       }
    }

Modified: branches/Branch_4_2/ejb3/src/main/org/jboss/ejb3/tx/Ejb3TxPolicy.java
===================================================================
--- branches/Branch_4_2/ejb3/src/main/org/jboss/ejb3/tx/Ejb3TxPolicy.java	2007-04-25 13:53:31 UTC (rev 62544)
+++ branches/Branch_4_2/ejb3/src/main/org/jboss/ejb3/tx/Ejb3TxPolicy.java	2007-04-25 13:59:14 UTC (rev 62545)
@@ -84,7 +84,7 @@
       if (t instanceof EJBTransactionRolledbackException)
          throw t;
       else
-         throw new EJBTransactionRolledbackException((Exception) t);
+         throw new EJBTransactionRolledbackException(t.getMessage(), (Exception) t);
    }
 
 }


Property changes on: branches/Branch_4_2/ejb3x
___________________________________________________________________
Name: subclipse:tags
   - 60181,Branch_4_2,/branches/Branch_4_2,branch
60191,JBoss_5_EJB3_RC10,/branches/JBoss_5_EJB3_RC10,branch
   + 60181,Branch_4_2,/branches/Branch_4_2,branch
60191,JBoss_5_EJB3_RC10,/branches/JBoss_5_EJB3_RC10,branch
62539,trunk,/trunk/ejb3x,branch

Deleted: branches/Branch_4_2/ejb3x/src/main/javax/ejb/AccessMode.java
===================================================================
--- branches/Branch_4_2/ejb3x/src/main/javax/ejb/AccessMode.java	2007-04-25 13:53:31 UTC (rev 62544)
+++ branches/Branch_4_2/ejb3x/src/main/javax/ejb/AccessMode.java	2007-04-25 13:59:14 UTC (rev 62545)
@@ -1,34 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source.
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors
- * as indicated by the @author tags. See the copyright.txt file in the
- * distribution for a full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package javax.ejb;
-
-/**
- * The enum for the type of EJB Home interface
- * 
- * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
- * @version $Revision$
- */
-public enum AccessMode
-{
-   LOCAL,
-   REMOTE
-}

Modified: branches/Branch_4_2/ejb3x/src/main/javax/ejb/ActivationConfigProperty.java
===================================================================
--- branches/Branch_4_2/ejb3x/src/main/javax/ejb/ActivationConfigProperty.java	2007-04-25 13:53:31 UTC (rev 62544)
+++ branches/Branch_4_2/ejb3x/src/main/javax/ejb/ActivationConfigProperty.java	2007-04-25 13:59:14 UTC (rev 62545)
@@ -21,14 +21,20 @@
  */
 package javax.ejb;
 
+import java.lang.annotation.Retention;
+import static java.lang.annotation.RetentionPolicy.*;
+import java.lang.annotation.Target;
 
 
+
 /**
  * Annotation for adding properties to messaging bean annotations (i.e. @MessageDriven, @Consumer)
  * 
  * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
  * @version $Revision$
  */
+ at Retention(RUNTIME)
+ at Target({})
 public @interface ActivationConfigProperty
 {
    String propertyName();

Modified: branches/Branch_4_2/ejb3x/src/main/javax/ejb/EJB.java
===================================================================
--- branches/Branch_4_2/ejb3x/src/main/javax/ejb/EJB.java	2007-04-25 13:53:31 UTC (rev 62544)
+++ branches/Branch_4_2/ejb3x/src/main/javax/ejb/EJB.java	2007-04-25 13:59:14 UTC (rev 62545)
@@ -21,18 +21,19 @@
  */
 package javax.ejb;
 
-import java.lang.annotation.ElementType;
+import static java.lang.annotation.ElementType.*;
 import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
+import static java.lang.annotation.RetentionPolicy.*;
 import java.lang.annotation.Target;
 
 /**
  * The EJB annotation denotes a reference to an EJB 3.0 session bean.
  * 
  * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
- * @version $Revision: 46096 $
+ * @version $Revision$
  */
- at Target({ElementType.METHOD, ElementType.TYPE, ElementType.FIELD, ElementType.PARAMETER}) @Retention(RetentionPolicy.RUNTIME)
+ at Retention(RUNTIME)
+ at Target({TYPE, METHOD, FIELD}) 
 public @interface EJB
 {
    String name() default "";

Modified: branches/Branch_4_2/ejb3x/src/main/javax/ejb/EJBAccessException.java
===================================================================
--- branches/Branch_4_2/ejb3x/src/main/javax/ejb/EJBAccessException.java	2007-04-25 13:53:31 UTC (rev 62544)
+++ branches/Branch_4_2/ejb3x/src/main/javax/ejb/EJBAccessException.java	2007-04-25 13:59:14 UTC (rev 62545)
@@ -43,15 +43,4 @@
   public EJBAccessException(String message) {
     super(message);
   }
-
-  /**
-   * Constructs an AccessLocalException with the specified detail message and a nested exception.
-   *
-   * @param message - The detailed message
-   * @param ex - The nested exception
-   */
-  public EJBAccessException(String message,
-                              Exception ex) {
-    super(message,ex);
-  }
 }

Modified: branches/Branch_4_2/ejb3x/src/main/javax/ejb/EJBTransactionRolledbackException.java
===================================================================
--- branches/Branch_4_2/ejb3x/src/main/javax/ejb/EJBTransactionRolledbackException.java	2007-04-25 13:53:31 UTC (rev 62544)
+++ branches/Branch_4_2/ejb3x/src/main/javax/ejb/EJBTransactionRolledbackException.java	2007-04-25 13:59:14 UTC (rev 62545)
@@ -57,15 +57,4 @@
   public EJBTransactionRolledbackException(String message,Exception ex) {
     super(message,ex);
   }
-
-   /**
-    * Constructs a TransactionRolledbackLocalException with the specified detail
-    * message and a nested exception.
-    *
-    * @param message - The detailed message.
-    * @param ex - The originally thrown exception.
-    */
-   public EJBTransactionRolledbackException(Exception ex) {
-     super(ex);
-   }
 }

Modified: branches/Branch_4_2/ejb3x/src/main/javax/ejb/Init.java
===================================================================
--- branches/Branch_4_2/ejb3x/src/main/javax/ejb/Init.java	2007-04-25 13:53:31 UTC (rev 62544)
+++ branches/Branch_4_2/ejb3x/src/main/javax/ejb/Init.java	2007-04-25 13:59:14 UTC (rev 62545)
@@ -34,5 +34,5 @@
  */
 @Target({ElementType.METHOD}) @Retention(RetentionPolicy.RUNTIME)
 public @interface Init{
-   String[] value() default {};
+   String value() default "";
 }


Property changes on: branches/Branch_4_2/j2ee
___________________________________________________________________
Name: subclipse:tags
   + 62539,trunk,/trunk/j2ee,branch

Modified: branches/Branch_4_2/j2ee/src/main/javax/ejb/SessionContext.java
===================================================================
--- branches/Branch_4_2/j2ee/src/main/javax/ejb/SessionContext.java	2007-04-25 13:53:31 UTC (rev 62544)
+++ branches/Branch_4_2/j2ee/src/main/javax/ejb/SessionContext.java	2007-04-25 13:59:14 UTC (rev 62545)
@@ -77,14 +77,14 @@
     */ 
    public MessageContext getMessageContext() throws IllegalStateException;
 
-   /** Returns the session bean’s business interface. Only session beans with an EJB 3.0 business interface
+   /** Returns the session bean's business interface. Only session beans with an EJB 3.0 business interface
     * can call this method.
     * 
     * @return The business interface associated with the instance.
     * @throws IllegalStateException - Thrown if this method is invoked while
     * the instance is in a state that does not allow access to this method.
     */ 
-   public Object getBusinessObject(Class businessInterface) throws IllegalStateException;
+   public <T> T getBusinessObject(Class<T> businessInterface) throws IllegalStateException;
    
    /** Returns the session bean business interface through which the bean was invoked.
     * 




More information about the jboss-cvs-commits mailing list