Issue Details (XML | Word | Printable)

Key: DIRSERVER-322
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Minor Minor
Assignee: Trustin Lee
Reporter: Tony Blanchard
Votes: 0
Watchers: 1
Operations

If you were logged in you would be able to see more operations.
Directory ApacheDS

Problem with the shutdown sequence.

Created: 08/Jul/05 07:10 PM   Updated: 21/Apr/07 11:13 AM
Return to search
Component/s: None
Affects Version/s: None
Fix Version/s: None

Time Tracking:
Not Specified

Resolution Date: 12/Aug/05 04:42 PM


 Description  « Hide
In AbstractContextFactory:getInitialContext

1-gets the DefaultContextFactoryService and asks it to shutdown.
    1-1-DefaultContextFactoryService shuts down and reset startupConfiguration field
2- asks the DefaultContextFactoryService to getInitialContext and uses checkSecuritySettings before returning DeadContext
  2-1 checkSecuritySettings uses startupConfiguration field and throws NullPointerException...

To pass this problem I made a temporary change to the DefaultContextFactoryService by commenting the startupConfiguration = null; in the finally block of shutdown() method.

Instead, I putted this code in the getJNDIContext method :
"checkSecuritySettings[...]

if (!started)
{
   startupConfiguration = null; //New code
  return DeadContext();
}"

 I made this because using afterShutdown hook is to early in sequence and I think only an authentified guy should shutdown the server...

On more thing is that it seams there is no test about shutdowning server and then make a call to an operation on it to produce an exception.
Best regards,
Tony

 All   Comments   Work Log   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Alex Karasulu added a comment - 12/Aug/05 12:12 AM
Trustin can you take a look into this if it has not been corrected already. I suspect this issue is over and done with and can just be closed. Perhaps Tony can comment on this.

Trustin Lee added a comment - 12/Aug/05 04:42 PM
Yes, Tony's patch is already applied to trunk. I added some check code, too.

Emmanuel Lecharny added a comment - 21/Apr/07 11:13 AM
Closing all issues created in 2005 and before which are marked resolved