Uploaded image for project: 'WildFly'
  1. WildFly
  2. WFLY-11548

RemoteExceptions and subclasses treated as ApplicationExceptions

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open (View Workflow)
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: 13.0.0.Final
    • Fix Version/s: None
    • Component/s: EJB
    • Labels:
      None
    • Steps to Reproduce:
      Hide

      I honestly think the git branch gives you the best idea on how to recreate it, it's a small change, but it requires you to somewhat violate the spec by extending a RemoteException with one of your own. This bug happens in CMTTxInterceptor.java:239 in conjunction with EJBComponent.java:266

      Show
      I honestly think the git branch gives you the best idea on how to recreate it, it's a small change, but it requires you to somewhat violate the spec by extending a RemoteException with one of your own. This bug happens in CMTTxInterceptor.java:239 in conjunction with EJBComponent.java:266

      Description

      Remote Exceptions should be treated as if they are System Exceptions

      So in very old projects where they used to extend RemoteException for their own exceptions, code was written under the assumption that when one of these is caught in the container, the transaction should be rolled back as per the spec (system exceptions cause a rollback).

      Currently if an ejb method throws a remote exception, this will be translated to be an Application Exception (on line 275 in EJBComponent.java) and transactions that are currently happening will no longer be rolled back; which was against the old spec, I'm unsure of what ejb 3.X says about this, but currently I felt it would make sense to mimic what happened in older application containers.

        Attachments

          Activity

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            hefnawio Omar Hefnawi (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated: