epermana / tungsten-replicator

Automatically exported from code.google.com/p/tungsten-replicator
1 stars 0 forks source link

The tpm command and other scripts drop space characters #854

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?

1. Provide an argument with a space in it
2. Check the stored value

What is the expected output?

The value with spaces is stored

What do you see instead?

The value without spaces is stored

What is the possible cause?

There is a section at the beginning of the script to remove unknown characters. 
It needs to include ascii code 32.

unless b.getbyte(0)<33  ....

What is the proposed solution?

...

Additional information

...

Use labels and text to provide additional information.

Original issue reported on code.google.com by jeff.m...@continuent.com on 17 Mar 2014 at 1:26

GoogleCodeExporter commented 9 years ago
The RubyGem needs to be rebuilt after this is done.

Original comment by jeff.m...@continuent.com on 17 Mar 2014 at 1:26

GoogleCodeExporter commented 9 years ago

Original comment by jeff.m...@continuent.com on 17 Mar 2014 at 1:35

GoogleCodeExporter commented 9 years ago

Original comment by jeff.m...@continuent.com on 8 May 2014 at 9:22

GoogleCodeExporter commented 9 years ago
Tested build 3.0.0-361. Can't handle space characters.

tpm install cookbook \
...
--repl-svc-applier-filters=colnames \
--property=replicator.filter.colnames.password='one space' \
...
ERROR >> There was a problem parsing the arguments
ERROR >> Unable to parse the following arguments: space'

Original comment by csaba.si...@continuent.com on 19 Sep 2014 at 9:15

GoogleCodeExporter commented 9 years ago
This issue was updated by revision r2574.

Update the tpm script to properly pass along arguments that have spaces in them

Original comment by jeffm...@gmail.com on 22 Sep 2014 at 7:26

GoogleCodeExporter commented 9 years ago
tools/tpm configure defaults --reset '--home-directory=/opt/continuent' 
'--user=tun gsten'

Original comment by jeff.m...@continuent.com on 22 Sep 2014 at 7:27

GoogleCodeExporter commented 9 years ago
This issue was updated by revision r2575.

Fix command escaping issues

Original comment by jeffm...@gmail.com on 22 Sep 2014 at 8:29

GoogleCodeExporter commented 9 years ago
Verified with build 3.0.0-393.

Original comment by csaba.si...@continuent.com on 24 Sep 2014 at 7:57

GoogleCodeExporter commented 9 years ago
A note has been added to the 3.0 release notes: 

tpm and other scripts may have failed to correctly parse arguments or options 
that contained a space, even when properly escaped.

Original comment by mc.br...@continuent.com on 7 Oct 2014 at 11:41

GoogleCodeExporter commented 9 years ago
Tested build 3.0.1-37. Can't hanlde space characters in a directory or a 
filename such as --home-direcotry and --datasource-mysql-conf.

./tpm configure defaults --reset '--home-directory=/opt/continuent\ software/'
ERROR >> Unable to parse "--install-directory": Value must be a valid filename
ERROR >> There was a problem parsing the arguments

./tpm configure defaults --reset '--home-directory=/opt/continuent software/'
ERROR >> Unable to parse "--install-directory": Value must be a valid filename
ERROR >> There was a problem parsing the arguments

Original comment by welly....@gmail.com on 23 Dec 2014 at 2:08

GoogleCodeExporter commented 9 years ago
This issue is still present in 3.0.1 GA.

./tools/tpm --home-directory='/opt/continuent/name with spaces'

Incidentally, note that changing the current code from

b.getbyte(0) < 32

to

b.getbyte(0) < 33

will let tpm see the option as expected. 

The previous fix should be reviewed

Original comment by g.maxia on 23 Dec 2014 at 3:24

GoogleCodeExporter commented 9 years ago

Original comment by linas.vi...@continuent.com on 19 Jan 2015 at 2:20