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 "John Storta Jr. (JIRA)" <ji...@apache.org> on 2010/01/01 00:44:29 UTC

[jira] Created: (DERBY-4501) CLASSPATH scripts do not work as defined in Getting Started in Derby Guide

CLASSPATH scripts do not work as defined in Getting Started in Derby Guide
--------------------------------------------------------------------------

                 Key: DERBY-4501
                 URL: https://issues.apache.org/jira/browse/DERBY-4501
             Project: Derby
          Issue Type: Bug
          Components: Documentation
    Affects Versions: 10.5.3.0
         Environment: Unix platforms
            Reporter: John Storta Jr.
            Priority: Minor


On pages 13 and 14 of the 'Getting Started in Derby Guide', there are 3
scripts referenced that can be used to set the CLASSPATH environment
variable.  setEmbeddedCP, setNetworkServerCP, & setNetworkClientCP.  The
documentation indicates that the appropriate script should be run
depending on your needs.

Running the scripts like any other script does not work.

When a script is run, it launches a new shell for that script.  The
CLASSPATH is set within that shell.  Once the script is complete, that
shell exits and you are returned to your shell.  The CLASSPATH is only
changed for the shell that the script was running in.  The CLASSPATH in
your shell is unchanged.

$ ${DERBY_HOME}/bin/setNetworkClientCP
Will result in your CLASSPATH being unchanged.

In order for CLASSPATH in your shell to be updated, you have to run the
script from within your shell (not launch a new shell).  This is done by
'sourcing' the script.

$ . ${DERBY_HOME}/bin/setNetworkClientCP
Will run the script within your shell resulting in your CLASSPATH being
updated.

The documentation is not clear on this.

Bug DERBY-4500 has been opened to address a related issue that will arise if/when the documentation is updated to reflect that the scripts should be sourced rather than run.


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


[jira] Commented: (DERBY-4501) CLASSPATH scripts do not work as defined in Getting Started in Derby Guide

Posted by "Dag H. Wanvik (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DERBY-4501?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12806081#action_12806081 ] 

Dag H. Wanvik commented on DERBY-4501:
--------------------------------------

I think updating the docs as you suggest is OK for now, Bryan. 

> CLASSPATH scripts do not work as defined in Getting Started in Derby Guide
> --------------------------------------------------------------------------
>
>                 Key: DERBY-4501
>                 URL: https://issues.apache.org/jira/browse/DERBY-4501
>             Project: Derby
>          Issue Type: Bug
>          Components: Documentation
>    Affects Versions: 10.5.3.0
>         Environment: Unix platforms
>            Reporter: John Storta Jr.
>            Assignee: Bryan Pendleton
>            Priority: Minor
>         Attachments: docs.diff, docs.diff, tgs26250.html, tgs26250.html
>
>
> On pages 13 and 14 of the 'Getting Started in Derby Guide', there are 3
> scripts referenced that can be used to set the CLASSPATH environment
> variable.  setEmbeddedCP, setNetworkServerCP, & setNetworkClientCP.  The
> documentation indicates that the appropriate script should be run
> depending on your needs.
> Running the scripts like any other script does not work.
> When a script is run, it launches a new shell for that script.  The
> CLASSPATH is set within that shell.  Once the script is complete, that
> shell exits and you are returned to your shell.  The CLASSPATH is only
> changed for the shell that the script was running in.  The CLASSPATH in
> your shell is unchanged.
> $ ${DERBY_HOME}/bin/setNetworkClientCP
> Will result in your CLASSPATH being unchanged.
> In order for CLASSPATH in your shell to be updated, you have to run the
> script from within your shell (not launch a new shell).  This is done by
> 'sourcing' the script.
> $ . ${DERBY_HOME}/bin/setNetworkClientCP
> Will run the script within your shell resulting in your CLASSPATH being
> updated.
> The documentation is not clear on this.
> Bug DERBY-4500 has been opened to address a related issue that will arise if/when the documentation is updated to reflect that the scripts should be sourced rather than run.

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


[jira] Commented: (DERBY-4501) CLASSPATH scripts do not work as defined in Getting Started in Derby Guide

Posted by "Kim Haase (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DERBY-4501?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12806113#action_12806113 ] 

Kim Haase commented on DERBY-4501:
----------------------------------

I agree with Dag. Helping with the shells that the scripts work with is fine. Users don't really need the scripts -- starting the tools using the java command as described in the Getting Started tasks works fine.

> CLASSPATH scripts do not work as defined in Getting Started in Derby Guide
> --------------------------------------------------------------------------
>
>                 Key: DERBY-4501
>                 URL: https://issues.apache.org/jira/browse/DERBY-4501
>             Project: Derby
>          Issue Type: Bug
>          Components: Documentation
>    Affects Versions: 10.5.3.0
>         Environment: Unix platforms
>            Reporter: John Storta Jr.
>            Assignee: Bryan Pendleton
>            Priority: Minor
>         Attachments: docs.diff, docs.diff, tgs26250.html, tgs26250.html
>
>
> On pages 13 and 14 of the 'Getting Started in Derby Guide', there are 3
> scripts referenced that can be used to set the CLASSPATH environment
> variable.  setEmbeddedCP, setNetworkServerCP, & setNetworkClientCP.  The
> documentation indicates that the appropriate script should be run
> depending on your needs.
> Running the scripts like any other script does not work.
> When a script is run, it launches a new shell for that script.  The
> CLASSPATH is set within that shell.  Once the script is complete, that
> shell exits and you are returned to your shell.  The CLASSPATH is only
> changed for the shell that the script was running in.  The CLASSPATH in
> your shell is unchanged.
> $ ${DERBY_HOME}/bin/setNetworkClientCP
> Will result in your CLASSPATH being unchanged.
> In order for CLASSPATH in your shell to be updated, you have to run the
> script from within your shell (not launch a new shell).  This is done by
> 'sourcing' the script.
> $ . ${DERBY_HOME}/bin/setNetworkClientCP
> Will run the script within your shell resulting in your CLASSPATH being
> updated.
> The documentation is not clear on this.
> Bug DERBY-4500 has been opened to address a related issue that will arise if/when the documentation is updated to reflect that the scripts should be sourced rather than run.

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


[jira] Updated: (DERBY-4501) CLASSPATH scripts do not work as defined in Getting Started in Derby Guide

Posted by "Bryan Pendleton (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/DERBY-4501?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Bryan Pendleton updated DERBY-4501:
-----------------------------------

    Attachment: docs.diff
                tgs26250.html

I agree that the different behavior of these scripts on Windows versus Unix/Linux
systems can be quite confusing. I tried to improve the documentation to
make this more clear.

Attached is a docs patch proposal ('docs.diff') and an HTML-formatted
version of the relevant page from the Getting Started guide.

I'm interested in whether people feel this makes the behavior more clear.


> CLASSPATH scripts do not work as defined in Getting Started in Derby Guide
> --------------------------------------------------------------------------
>
>                 Key: DERBY-4501
>                 URL: https://issues.apache.org/jira/browse/DERBY-4501
>             Project: Derby
>          Issue Type: Bug
>          Components: Documentation
>    Affects Versions: 10.5.3.0
>         Environment: Unix platforms
>            Reporter: John Storta Jr.
>            Assignee: Bryan Pendleton
>            Priority: Minor
>         Attachments: docs.diff, tgs26250.html
>
>
> On pages 13 and 14 of the 'Getting Started in Derby Guide', there are 3
> scripts referenced that can be used to set the CLASSPATH environment
> variable.  setEmbeddedCP, setNetworkServerCP, & setNetworkClientCP.  The
> documentation indicates that the appropriate script should be run
> depending on your needs.
> Running the scripts like any other script does not work.
> When a script is run, it launches a new shell for that script.  The
> CLASSPATH is set within that shell.  Once the script is complete, that
> shell exits and you are returned to your shell.  The CLASSPATH is only
> changed for the shell that the script was running in.  The CLASSPATH in
> your shell is unchanged.
> $ ${DERBY_HOME}/bin/setNetworkClientCP
> Will result in your CLASSPATH being unchanged.
> In order for CLASSPATH in your shell to be updated, you have to run the
> script from within your shell (not launch a new shell).  This is done by
> 'sourcing' the script.
> $ . ${DERBY_HOME}/bin/setNetworkClientCP
> Will run the script within your shell resulting in your CLASSPATH being
> updated.
> The documentation is not clear on this.
> Bug DERBY-4500 has been opened to address a related issue that will arise if/when the documentation is updated to reflect that the scripts should be sourced rather than run.

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


[jira] Commented: (DERBY-4501) CLASSPATH scripts do not work as defined in Getting Started in Derby Guide

Posted by "Kim Haase (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DERBY-4501?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12806348#action_12806348 ] 

Kim Haase commented on DERBY-4501:
----------------------------------

Thanks, Bryan -- this looks good now. +1 from this end.

> CLASSPATH scripts do not work as defined in Getting Started in Derby Guide
> --------------------------------------------------------------------------
>
>                 Key: DERBY-4501
>                 URL: https://issues.apache.org/jira/browse/DERBY-4501
>             Project: Derby
>          Issue Type: Bug
>          Components: Documentation
>    Affects Versions: 10.5.3.0
>         Environment: Unix platforms
>            Reporter: John Storta Jr.
>            Assignee: Bryan Pendleton
>            Priority: Minor
>         Attachments: docs.diff, docs.diff, docs.diff, tgs26250.html, tgs26250.html, tgs26250.html
>
>
> On pages 13 and 14 of the 'Getting Started in Derby Guide', there are 3
> scripts referenced that can be used to set the CLASSPATH environment
> variable.  setEmbeddedCP, setNetworkServerCP, & setNetworkClientCP.  The
> documentation indicates that the appropriate script should be run
> depending on your needs.
> Running the scripts like any other script does not work.
> When a script is run, it launches a new shell for that script.  The
> CLASSPATH is set within that shell.  Once the script is complete, that
> shell exits and you are returned to your shell.  The CLASSPATH is only
> changed for the shell that the script was running in.  The CLASSPATH in
> your shell is unchanged.
> $ ${DERBY_HOME}/bin/setNetworkClientCP
> Will result in your CLASSPATH being unchanged.
> In order for CLASSPATH in your shell to be updated, you have to run the
> script from within your shell (not launch a new shell).  This is done by
> 'sourcing' the script.
> $ . ${DERBY_HOME}/bin/setNetworkClientCP
> Will run the script within your shell resulting in your CLASSPATH being
> updated.
> The documentation is not clear on this.
> Bug DERBY-4500 has been opened to address a related issue that will arise if/when the documentation is updated to reflect that the scripts should be sourced rather than run.

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


[jira] Commented: (DERBY-4501) CLASSPATH scripts do not work as defined in Getting Started in Derby Guide

Posted by "Kim Haase (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DERBY-4501?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12805545#action_12805545 ] 

Kim Haase commented on DERBY-4501:
----------------------------------

This is very useful info to have -- thanks, Bryan.

I have a couple of language suggestions -- 

Being kind of a stickler about "differently than" I would suggest changing the sentence to either

"Note that these scripts behave slightly differently on UNIX systems and on Windows systems."

or

"Note that these scripts behave slightly differently on UNIX systems from the way they behave on Windows systems."

Also, the long sentence starting with "Otherwise" might better be broken into separate sentences -- perhaps the UNIX and Windows info can be in separate paragraphs.

"On UNIX systems, you need to use the "dot" or "source" command to ensure that the script is run in the calling shell's environment. Otherwise, when a script is run, it launches a new shell for that script. The CLASSPATH is set within that shell. Once the script is complete, that shell exits and you are returned to your shell. The CLASSPATH is changed only for the shell that the script was running in. The CLASSPATH in your shell is unchanged."

That said, I happen to be running in a C shell on Solaris, and I can't make the scripts work at all, even if I switch to a Bourne shell. Neither source nor dot seems to work. This may be of no concern to anybody, things being how they are ...

I already have the classpath set, so that I can build the Derby docs -- you probably do too.

 jdench 49 =>setenv DERBY_HOME /home/chaase/db-derby-10.5.3.0-bin
 jdench 50 =>echo $CLASSPATH
.:./lib/fop.jar:./lib/avalon-framework-cvs-20020806.jar:./lib/batik.jar
 jdench 51 =>echo $DERBY_HOME
/home/chaase/db-derby-10.5.3.0-bin
 jdench 52 =>source $DERBY_HOME/bin/setEmbeddedCP
Missing ]
 jdench 53 =>. $DERBY_HOME/bin/setEmbeddedCP
/home/chaase/javaee6-sdk/glassfish/bin/.: Permission denied
 jdench 54 =>echo $CLASSPATH
.:./lib/fop.jar:./lib/avalon-framework-cvs-20020806.jar:./lib/batik.jar

 jdench 56 =>/bin/sh
$ echo $CLASSPATH
.:./lib/fop.jar:./lib/avalon-framework-cvs-20020806.jar:./lib/batik.jar
$ echo $DERBY_HOME
/home/chaase/db-derby-10.5.3.0-bin
$ . $DERBY_HOME/bin/setEmbeddedCP
CLASSPATH=/home/chaase/db-derby-10.5.3.0-bin/lib/derby.jar:/home/chaase/db-derby-10.5.3.0-bin/lib/derbytools.jar:.:./lib/fop.jar:./lib/avalon-framework-cvs-20020806.jar:./lib/batik.jar: is not an identifier
$ echo $CLASSPATH
.:./lib/fop.jar:./lib/avalon-framework-cvs-20020806.jar:./lib/batik.jar


> CLASSPATH scripts do not work as defined in Getting Started in Derby Guide
> --------------------------------------------------------------------------
>
>                 Key: DERBY-4501
>                 URL: https://issues.apache.org/jira/browse/DERBY-4501
>             Project: Derby
>          Issue Type: Bug
>          Components: Documentation
>    Affects Versions: 10.5.3.0
>         Environment: Unix platforms
>            Reporter: John Storta Jr.
>            Assignee: Bryan Pendleton
>            Priority: Minor
>         Attachments: docs.diff, docs.diff, tgs26250.html, tgs26250.html
>
>
> On pages 13 and 14 of the 'Getting Started in Derby Guide', there are 3
> scripts referenced that can be used to set the CLASSPATH environment
> variable.  setEmbeddedCP, setNetworkServerCP, & setNetworkClientCP.  The
> documentation indicates that the appropriate script should be run
> depending on your needs.
> Running the scripts like any other script does not work.
> When a script is run, it launches a new shell for that script.  The
> CLASSPATH is set within that shell.  Once the script is complete, that
> shell exits and you are returned to your shell.  The CLASSPATH is only
> changed for the shell that the script was running in.  The CLASSPATH in
> your shell is unchanged.
> $ ${DERBY_HOME}/bin/setNetworkClientCP
> Will result in your CLASSPATH being unchanged.
> In order for CLASSPATH in your shell to be updated, you have to run the
> script from within your shell (not launch a new shell).  This is done by
> 'sourcing' the script.
> $ . ${DERBY_HOME}/bin/setNetworkClientCP
> Will run the script within your shell resulting in your CLASSPATH being
> updated.
> The documentation is not clear on this.
> Bug DERBY-4500 has been opened to address a related issue that will arise if/when the documentation is updated to reflect that the scripts should be sourced rather than run.

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


[jira] Commented: (DERBY-4501) CLASSPATH scripts do not work as defined in Getting Started in Derby Guide

Posted by "Dag H. Wanvik (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DERBY-4501?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12805917#action_12805917 ] 

Dag H. Wanvik commented on DERBY-4501:
--------------------------------------

Actually, we don't provide a csh/tcsh sourcable setting script right now. We may consider adding that, though.

As for your second attempt, I notice that the current UNIX shell script uses the bash syntax for combined setting and exporting an environment variable, i.e.

    export CLASSPATH= .....

In a classic Bourne shell, this is not allowed, one needs to write this in two statements:

    CLASSPATH=....
    export CLASSPATH

which also works in bash, btw. So, for maximum usability I suggest we use the latter form.
The scripts also contain a misleading "bang" header: "#!/bin/sh" indicating Borne shell syntax,
when the syntax is reall bash. But the "bang" header should probably omitted anyway, since the script is not meant for running but for sourcing?

Do the docs call for bash or just sh (Borne shell)?


> CLASSPATH scripts do not work as defined in Getting Started in Derby Guide
> --------------------------------------------------------------------------
>
>                 Key: DERBY-4501
>                 URL: https://issues.apache.org/jira/browse/DERBY-4501
>             Project: Derby
>          Issue Type: Bug
>          Components: Documentation
>    Affects Versions: 10.5.3.0
>         Environment: Unix platforms
>            Reporter: John Storta Jr.
>            Assignee: Bryan Pendleton
>            Priority: Minor
>         Attachments: docs.diff, docs.diff, tgs26250.html, tgs26250.html
>
>
> On pages 13 and 14 of the 'Getting Started in Derby Guide', there are 3
> scripts referenced that can be used to set the CLASSPATH environment
> variable.  setEmbeddedCP, setNetworkServerCP, & setNetworkClientCP.  The
> documentation indicates that the appropriate script should be run
> depending on your needs.
> Running the scripts like any other script does not work.
> When a script is run, it launches a new shell for that script.  The
> CLASSPATH is set within that shell.  Once the script is complete, that
> shell exits and you are returned to your shell.  The CLASSPATH is only
> changed for the shell that the script was running in.  The CLASSPATH in
> your shell is unchanged.
> $ ${DERBY_HOME}/bin/setNetworkClientCP
> Will result in your CLASSPATH being unchanged.
> In order for CLASSPATH in your shell to be updated, you have to run the
> script from within your shell (not launch a new shell).  This is done by
> 'sourcing' the script.
> $ . ${DERBY_HOME}/bin/setNetworkClientCP
> Will run the script within your shell resulting in your CLASSPATH being
> updated.
> The documentation is not clear on this.
> Bug DERBY-4500 has been opened to address a related issue that will arise if/when the documentation is updated to reflect that the scripts should be sourced rather than run.

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


[jira] Resolved: (DERBY-4501) CLASSPATH scripts do not work as defined in Getting Started in Derby Guide

Posted by "Bryan Pendleton (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/DERBY-4501?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Bryan Pendleton resolved DERBY-4501.
------------------------------------

       Resolution: Fixed
    Fix Version/s: 10.6.0.0

Updated the docs and committed to the docs trunk as revision 904693.


> CLASSPATH scripts do not work as defined in Getting Started in Derby Guide
> --------------------------------------------------------------------------
>
>                 Key: DERBY-4501
>                 URL: https://issues.apache.org/jira/browse/DERBY-4501
>             Project: Derby
>          Issue Type: Bug
>          Components: Documentation
>    Affects Versions: 10.5.3.0
>         Environment: Unix platforms
>            Reporter: John Storta Jr.
>            Assignee: Bryan Pendleton
>            Priority: Minor
>             Fix For: 10.6.0.0
>
>         Attachments: docs.diff, docs.diff, docs.diff, tgs26250.html, tgs26250.html, tgs26250.html
>
>
> On pages 13 and 14 of the 'Getting Started in Derby Guide', there are 3
> scripts referenced that can be used to set the CLASSPATH environment
> variable.  setEmbeddedCP, setNetworkServerCP, & setNetworkClientCP.  The
> documentation indicates that the appropriate script should be run
> depending on your needs.
> Running the scripts like any other script does not work.
> When a script is run, it launches a new shell for that script.  The
> CLASSPATH is set within that shell.  Once the script is complete, that
> shell exits and you are returned to your shell.  The CLASSPATH is only
> changed for the shell that the script was running in.  The CLASSPATH in
> your shell is unchanged.
> $ ${DERBY_HOME}/bin/setNetworkClientCP
> Will result in your CLASSPATH being unchanged.
> In order for CLASSPATH in your shell to be updated, you have to run the
> script from within your shell (not launch a new shell).  This is done by
> 'sourcing' the script.
> $ . ${DERBY_HOME}/bin/setNetworkClientCP
> Will run the script within your shell resulting in your CLASSPATH being
> updated.
> The documentation is not clear on this.
> Bug DERBY-4500 has been opened to address a related issue that will arise if/when the documentation is updated to reflect that the scripts should be sourced rather than run.

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


[jira] Commented: (DERBY-4501) CLASSPATH scripts do not work as defined in Getting Started in Derby Guide

Posted by "Bryan Pendleton (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DERBY-4501?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12806011#action_12806011 ] 

Bryan Pendleton commented on DERBY-4501:
----------------------------------------

Thanks Kim and Dag for the good suggestions and extra testing.

I feel that we should treat the issue of changing the scripts to run in more UNIX shells as a separate
enhancement, and as part of this change we should just try to document the current scripts as
well as we can.

Unfortunately, on my system (RedHat Linux-based), the current scripts work fine when running /bin/sh,
which perhaps is just another way of saying that /bin/sh on my system is actually BASH, not Bourne shell,
so I don't really have access to an environment where I can work on improving the scripts.

But if others want to work on the scripts to improve their portability to other shells, I think that would be wonderful!

In the meantime, I'll update the docs to incorporate the good suggestions above, and will also add
a sentence along the lines of:

  The UNIX shell scripts are known to run successfully in the Bash shell, and you may need to
  modify them slightly if you are using a different UNIX shell.

I think I should probably reword the information that I added about the Bourne shell in the previous patch,
because I can't tell if it's correct or not, since I don't think I have a true Bourne shell to try. Instead, I'll
label the alternate sections as "using the "dot" command" and "using the "source" command".

> CLASSPATH scripts do not work as defined in Getting Started in Derby Guide
> --------------------------------------------------------------------------
>
>                 Key: DERBY-4501
>                 URL: https://issues.apache.org/jira/browse/DERBY-4501
>             Project: Derby
>          Issue Type: Bug
>          Components: Documentation
>    Affects Versions: 10.5.3.0
>         Environment: Unix platforms
>            Reporter: John Storta Jr.
>            Assignee: Bryan Pendleton
>            Priority: Minor
>         Attachments: docs.diff, docs.diff, tgs26250.html, tgs26250.html
>
>
> On pages 13 and 14 of the 'Getting Started in Derby Guide', there are 3
> scripts referenced that can be used to set the CLASSPATH environment
> variable.  setEmbeddedCP, setNetworkServerCP, & setNetworkClientCP.  The
> documentation indicates that the appropriate script should be run
> depending on your needs.
> Running the scripts like any other script does not work.
> When a script is run, it launches a new shell for that script.  The
> CLASSPATH is set within that shell.  Once the script is complete, that
> shell exits and you are returned to your shell.  The CLASSPATH is only
> changed for the shell that the script was running in.  The CLASSPATH in
> your shell is unchanged.
> $ ${DERBY_HOME}/bin/setNetworkClientCP
> Will result in your CLASSPATH being unchanged.
> In order for CLASSPATH in your shell to be updated, you have to run the
> script from within your shell (not launch a new shell).  This is done by
> 'sourcing' the script.
> $ . ${DERBY_HOME}/bin/setNetworkClientCP
> Will run the script within your shell resulting in your CLASSPATH being
> updated.
> The documentation is not clear on this.
> Bug DERBY-4500 has been opened to address a related issue that will arise if/when the documentation is updated to reflect that the scripts should be sourced rather than run.

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


[jira] Updated: (DERBY-4501) CLASSPATH scripts do not work as defined in Getting Started in Derby Guide

Posted by "Bryan Pendleton (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/DERBY-4501?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Bryan Pendleton updated DERBY-4501:
-----------------------------------

    Attachment: docs.diff
                tgs26250.html

OK, here's another try at the patch, and the corresponding HTML-formatted page.

I feel that the docs are significantly better than they were before, and they now
address the issues raised in the description of this problem, as well as several
related issues raised during the discussion. Thanks to all for the contributions!


> CLASSPATH scripts do not work as defined in Getting Started in Derby Guide
> --------------------------------------------------------------------------
>
>                 Key: DERBY-4501
>                 URL: https://issues.apache.org/jira/browse/DERBY-4501
>             Project: Derby
>          Issue Type: Bug
>          Components: Documentation
>    Affects Versions: 10.5.3.0
>         Environment: Unix platforms
>            Reporter: John Storta Jr.
>            Assignee: Bryan Pendleton
>            Priority: Minor
>         Attachments: docs.diff, docs.diff, docs.diff, tgs26250.html, tgs26250.html, tgs26250.html
>
>
> On pages 13 and 14 of the 'Getting Started in Derby Guide', there are 3
> scripts referenced that can be used to set the CLASSPATH environment
> variable.  setEmbeddedCP, setNetworkServerCP, & setNetworkClientCP.  The
> documentation indicates that the appropriate script should be run
> depending on your needs.
> Running the scripts like any other script does not work.
> When a script is run, it launches a new shell for that script.  The
> CLASSPATH is set within that shell.  Once the script is complete, that
> shell exits and you are returned to your shell.  The CLASSPATH is only
> changed for the shell that the script was running in.  The CLASSPATH in
> your shell is unchanged.
> $ ${DERBY_HOME}/bin/setNetworkClientCP
> Will result in your CLASSPATH being unchanged.
> In order for CLASSPATH in your shell to be updated, you have to run the
> script from within your shell (not launch a new shell).  This is done by
> 'sourcing' the script.
> $ . ${DERBY_HOME}/bin/setNetworkClientCP
> Will run the script within your shell resulting in your CLASSPATH being
> updated.
> The documentation is not clear on this.
> Bug DERBY-4500 has been opened to address a related issue that will arise if/when the documentation is updated to reflect that the scripts should be sourced rather than run.

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


[jira] Commented: (DERBY-4501) CLASSPATH scripts do not work as defined in Getting Started in Derby Guide

Posted by "Dag H. Wanvik (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DERBY-4501?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12805075#action_12805075 ] 

Dag H. Wanvik commented on DERBY-4501:
--------------------------------------

Thanks for tackling this, Bryan! Looks like a clear improvement to me.
Instead of "dot", you might consider "dot" or "source"; bash allows both use of the dot-syntax and the source keyword.
As for the example, do you presume that the user has done a cd to the directory containing the scripts or added it to the PATH environement variable? Would it perhaps be even more helpful to write something like this:

UNIX Bourne shell:

> DERBY_HOME=/derby/db-derby-10.5.3.0-bin
> . $DERBY_HOME/bin/setEmbeddedCP

or with Bash:

> DERBY_HOME=/derby/db-derby-10.5.3.0-bin
> source $DERBY_HOME/bin/setEmbeddedCP 



> CLASSPATH scripts do not work as defined in Getting Started in Derby Guide
> --------------------------------------------------------------------------
>
>                 Key: DERBY-4501
>                 URL: https://issues.apache.org/jira/browse/DERBY-4501
>             Project: Derby
>          Issue Type: Bug
>          Components: Documentation
>    Affects Versions: 10.5.3.0
>         Environment: Unix platforms
>            Reporter: John Storta Jr.
>            Assignee: Bryan Pendleton
>            Priority: Minor
>         Attachments: docs.diff, tgs26250.html
>
>
> On pages 13 and 14 of the 'Getting Started in Derby Guide', there are 3
> scripts referenced that can be used to set the CLASSPATH environment
> variable.  setEmbeddedCP, setNetworkServerCP, & setNetworkClientCP.  The
> documentation indicates that the appropriate script should be run
> depending on your needs.
> Running the scripts like any other script does not work.
> When a script is run, it launches a new shell for that script.  The
> CLASSPATH is set within that shell.  Once the script is complete, that
> shell exits and you are returned to your shell.  The CLASSPATH is only
> changed for the shell that the script was running in.  The CLASSPATH in
> your shell is unchanged.
> $ ${DERBY_HOME}/bin/setNetworkClientCP
> Will result in your CLASSPATH being unchanged.
> In order for CLASSPATH in your shell to be updated, you have to run the
> script from within your shell (not launch a new shell).  This is done by
> 'sourcing' the script.
> $ . ${DERBY_HOME}/bin/setNetworkClientCP
> Will run the script within your shell resulting in your CLASSPATH being
> updated.
> The documentation is not clear on this.
> Bug DERBY-4500 has been opened to address a related issue that will arise if/when the documentation is updated to reflect that the scripts should be sourced rather than run.

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


[jira] Updated: (DERBY-4501) CLASSPATH scripts do not work as defined in Getting Started in Derby Guide

Posted by "Bryan Pendleton (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/DERBY-4501?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Bryan Pendleton updated DERBY-4501:
-----------------------------------

    Attachment: docs.diff
                tgs26250.html

Thanks Dag, I think that is a good suggestion. I took another stab at the
page, including information about both shell styles. 

> CLASSPATH scripts do not work as defined in Getting Started in Derby Guide
> --------------------------------------------------------------------------
>
>                 Key: DERBY-4501
>                 URL: https://issues.apache.org/jira/browse/DERBY-4501
>             Project: Derby
>          Issue Type: Bug
>          Components: Documentation
>    Affects Versions: 10.5.3.0
>         Environment: Unix platforms
>            Reporter: John Storta Jr.
>            Assignee: Bryan Pendleton
>            Priority: Minor
>         Attachments: docs.diff, docs.diff, tgs26250.html, tgs26250.html
>
>
> On pages 13 and 14 of the 'Getting Started in Derby Guide', there are 3
> scripts referenced that can be used to set the CLASSPATH environment
> variable.  setEmbeddedCP, setNetworkServerCP, & setNetworkClientCP.  The
> documentation indicates that the appropriate script should be run
> depending on your needs.
> Running the scripts like any other script does not work.
> When a script is run, it launches a new shell for that script.  The
> CLASSPATH is set within that shell.  Once the script is complete, that
> shell exits and you are returned to your shell.  The CLASSPATH is only
> changed for the shell that the script was running in.  The CLASSPATH in
> your shell is unchanged.
> $ ${DERBY_HOME}/bin/setNetworkClientCP
> Will result in your CLASSPATH being unchanged.
> In order for CLASSPATH in your shell to be updated, you have to run the
> script from within your shell (not launch a new shell).  This is done by
> 'sourcing' the script.
> $ . ${DERBY_HOME}/bin/setNetworkClientCP
> Will run the script within your shell resulting in your CLASSPATH being
> updated.
> The documentation is not clear on this.
> Bug DERBY-4500 has been opened to address a related issue that will arise if/when the documentation is updated to reflect that the scripts should be sourced rather than run.

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


[jira] Assigned: (DERBY-4501) CLASSPATH scripts do not work as defined in Getting Started in Derby Guide

Posted by "Bryan Pendleton (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/DERBY-4501?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Bryan Pendleton reassigned DERBY-4501:
--------------------------------------

    Assignee: Bryan Pendleton

> CLASSPATH scripts do not work as defined in Getting Started in Derby Guide
> --------------------------------------------------------------------------
>
>                 Key: DERBY-4501
>                 URL: https://issues.apache.org/jira/browse/DERBY-4501
>             Project: Derby
>          Issue Type: Bug
>          Components: Documentation
>    Affects Versions: 10.5.3.0
>         Environment: Unix platforms
>            Reporter: John Storta Jr.
>            Assignee: Bryan Pendleton
>            Priority: Minor
>
> On pages 13 and 14 of the 'Getting Started in Derby Guide', there are 3
> scripts referenced that can be used to set the CLASSPATH environment
> variable.  setEmbeddedCP, setNetworkServerCP, & setNetworkClientCP.  The
> documentation indicates that the appropriate script should be run
> depending on your needs.
> Running the scripts like any other script does not work.
> When a script is run, it launches a new shell for that script.  The
> CLASSPATH is set within that shell.  Once the script is complete, that
> shell exits and you are returned to your shell.  The CLASSPATH is only
> changed for the shell that the script was running in.  The CLASSPATH in
> your shell is unchanged.
> $ ${DERBY_HOME}/bin/setNetworkClientCP
> Will result in your CLASSPATH being unchanged.
> In order for CLASSPATH in your shell to be updated, you have to run the
> script from within your shell (not launch a new shell).  This is done by
> 'sourcing' the script.
> $ . ${DERBY_HOME}/bin/setNetworkClientCP
> Will run the script within your shell resulting in your CLASSPATH being
> updated.
> The documentation is not clear on this.
> Bug DERBY-4500 has been opened to address a related issue that will arise if/when the documentation is updated to reflect that the scripts should be sourced rather than run.

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