Project: springxd
Issue XD-702: stack overflow when trying to create a stream with the same name as a module
(NOTE: even if we do want to prevent the use of module names for stream names, we obviously need to avoid a StackOverflowError) to reproduce: start the xd-singlenode container start the xd-shell, and type the following: {code} xd:>stream create time --definition "time | log" {code} that should produce an Internal Server Error output message check the xd-singlenode console, and find: {code} SEVERE: Servlet.service() for servlet [xd] in context with path [] threw exception [Handler processing failed; nested exception is java.lang.StackOverflowError] with root cause java.lang.StackOverflowError java.lang.StringValue.from(StringValue.java:24) java.lang.String.(String.java:178) org.springframework.xd.dirt.stream.dsl.Token.(Token.java:46) org.springframework.xd.dirt.stream.dsl.Tokenizer.lexIdentifier(Tokenizer.java:195) org.springframework.xd.dirt.stream.dsl.Tokenizer.process(Tokenizer.java:62) org.springframework.xd.dirt.stream.dsl.Tokenizer.(Tokenizer.java:41) org.springframework.xd.dirt.stream.dsl.StreamConfigParser.parse(StreamConfigParser.java:65) org.springframework.xd.dirt.stream.dsl.StreamConfigParser.parse(StreamConfigParser.java:55) org.springframework.xd.dirt.stream.dsl.StreamConfigParser.lookupStream(StreamConfigParser.java:545) org.springframework.xd.dirt.stream.dsl.StreamNode.resolveModuleNodes(StreamNode.java:135) org.springframework.xd.dirt.stream.dsl.StreamNode.resolve(StreamNode.java:122) org.springframework.xd.dirt.stream.dsl.StreamsNode.resolve(StreamsNode.java:53) org.springframework.xd.dirt.stream.dsl.StreamConfigParser.parse(StreamConfigParser.java:74) org.springframework.xd.dirt.stream.dsl.StreamConfigParser.parse(StreamConfigParser.java:55) org.springframework.xd.dirt.stream.dsl.StreamConfigParser.lookupStream(StreamConfigParser.java:545) org.springframework.xd.dirt.stream.dsl.StreamNode.resolveModuleNodes(StreamNode.java:135) org.springframework.xd.dirt.stream.dsl.StreamNode.resolve(StreamNode.java:122) org.springframework.xd.dirt.stream.dsl.StreamsNode.resolve(StreamsNode.java:53) org.springframework.xd.dirt.stream.dsl.StreamConfigParser.parse(StreamConfigParser.java:74) org.springframework.xd.dirt.stream.dsl.StreamConfigParser.parse(StreamConfigParser.java:55) org.springframework.xd.dirt.stream.dsl.StreamConfigParser.lookupStream(StreamConfigParser.java:545) org.springframework.xd.dirt.stream.dsl.StreamNode.resolveModuleNodes(StreamNode.java:135) org.springframework.xd.dirt.stream.dsl.StreamNode.resolve(StreamNode.java:122) org.springframework.xd.dirt.stream.dsl.StreamsNode.resolve(StreamsNode.java:53)	...ad nauseum	{code}
Story points: 2