You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-dev@db.apache.org by "Mamta A. Satoor (JIRA)" <ji...@apache.org> on 2007/11/27 09:36:43 UTC

[jira] Issue Comment Edited: (DERBY-3151) Reduce dependency on NetworkServerControl in TestConfiguration

    [ https://issues.apache.org/jira/browse/DERBY-3151?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12545741 ] 

mamtas edited comment on DERBY-3151 at 11/27/07 12:35 AM:
-------------------------------------------------------------------

Once we reach a resolution to this jira entry, we should provide a similar central mechanism to start and stop network server in 10.3 codeline. Currently, in 10.3 codeline,  tests like TestConnectionMethods.java and OutBufferedStream.java have their own code to start and stop network server. I will be soon committing changes(in 10.3 codeline) into jdbcapi.DataSourceTest and jdbc4.DataSourceTest which will also have code to start and stop network server. It will be good for the some base class in 10.3 to provide start and stop network server functionality so specific tests can rely on that functionality rather than duplicating code.

      was (Author: mamtas):
    Once we need a resolution to this jira entry, we should provide a similar central mechanism to start and stop network server in 10.3 codeline. Currently, in 10.3 codeline,  tests like TestConnectionMethods.java and OutBufferedStream.java have their own code to start and stop network server. I will be soon committing changes(in 10.3 codeline) into jdbcapi.DataSourceTest and jdbc4.DataSourceTest which will also have code to start and stop network server. It will be good for the some base class in 10.3 to provide start and stop network server functionality so specific tests can rely on that functionality rather than duplicating code.
  
> Reduce dependency on NetworkServerControl in TestConfiguration
> --------------------------------------------------------------
>
>                 Key: DERBY-3151
>                 URL: https://issues.apache.org/jira/browse/DERBY-3151
>             Project: Derby
>          Issue Type: Improvement
>          Components: Test
>    Affects Versions: 10.4.0.0
>            Reporter: Kristian Waagan
>            Priority: Minor
>         Attachments: derby-3151-1a-proposal.diff
>
>
> Code has been added in TestConfiguration to allow for starting and stopping a Derby network server.
> Even if you know will not need this functionality, or you simply don't want to have this functionality available, you must include derbynet.jar (or point to classes/).
> I think this dependency should be reduced, by not having any instance variables and by not importing the class with an explicit import statement. The existing instance variables are not used.
> With this planned change, you can run tests without including derbynet.jar on the classpath, as long as they don't call 'startNetworkServer' or 'stopNetworkServer'. Most often these methods will be called by a decorator.
> The downside of this change, is that you won't get any error messages before the mentioned methods are actually executed.
> A typical error message:
> Failed to invoke suite():java.lang.NoClassDefFoundError: org/apache/derby/drda/NetworkServerControl
> I'm sure there are other solutions as well, but this one is really easy.
> Any opinions on this change?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.