Message:

   The following issue has been closed.

---------------------------------------------------------------------
View the issue:
  http://issues.apache.org/jira/browse/HIVEMIND-41

Here is an overview of the issue:
---------------------------------------------------------------------
        Key: HIVEMIND-41
    Summary: No bounds checking in SchemaProcessorImpl stack
       Type: Bug

     Status: Closed
   Priority: Major
 Resolution: FIXED

    Project: HiveMind
 Components: 
             framework
   Versions:
             1.0

   Assignee: Howard M. Lewis Ship
   Reporter: Steve Gibson

    Created: Fri, 6 Aug 2004 10:28 AM
    Updated: Wed, 11 Aug 2004 11:49 AM

Description:
org.apache.hivemind.impl.SchemaProcessorImpl aggregates stack functionality 
along with its other functions. This is achieved by a java.util.List and some 
public methods.
Unfortunately, these methods do not perform bounds checking or a way to check 
the size of thist stack. Java does do this, and throws 
ArrayIndexOutOfBoundsException, but the resulting exception seen in client code 
looks like:
2004-08-06 13:22:31,959 com.cowww.test.commons.hivemind.RegistryFactoryTestCase 
[ERROR] org.apache.hivemind.ApplicationRuntimeException: Unable to construct 
configuration cowww.HibernateConfiguration: -1
java.util.Stack throws an EmptyStackException in this case, which is a lot 
easier to diagnose without having to check the rootCause.

My opinion is that:
1. EmptyStackException is thrown
2. A method for checking the stack depth is added.
It may be easier to just use a Stack internally and make the pertinent methods 
available to calling classes.



---------------------------------------------------------------------
JIRA INFORMATION:
This message is automatically generated by JIRA.

If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa

If you want more information on JIRA, or have a bug to report see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to