Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot create a kv-memory datasource using lb4 datasource #1697

Closed
bajtos opened this issue Sep 11, 2018 · 1 comment · Fixed by #1700
Closed

Cannot create a kv-memory datasource using lb4 datasource #1697

bajtos opened this issue Sep 11, 2018 · 1 comment · Fixed by #1700
Assignees

Comments

@bajtos
Copy link
Member

bajtos commented Sep 11, 2018

Description / Steps to reproduce / Feature proposal

Create an LB4 app, e.g. via lb4 app.

Try to create a datasource backed by kv-memory connector by running lb4 datasource.

Current Behavior

The process crashes.

$ lb4 datasource
? Datasource name: keyvalue
? Select the connector for keyvalue: In-memory key-value connector (supported by StrongLoop)
events.js:167
      throw er; // Unhandled 'error' event
      ^

TypeError: Cannot convert undefined or null to object
    at Function.entries (<anonymous>)
    at DataSourceGenerator.promptConnectorConfig (/Users/bajtos/src/loopback/next/packages/cli/generators/datasource/index.js:159:12)
    at Object.<anonymous> (/Users/bajtos/src/loopback/next/packages/cli/node_modules/yeoman-generator/lib/index.js:424:27)
    at /Users/bajtos/src/loopback/next/packages/cli/node_modules/run-async/index.js:25:25
    at new Promise (<anonymous>)
    at /Users/bajtos/src/loopback/next/packages/cli/node_modules/run-async/index.js:24:19
    at self.env.runLoop.add.completed (/Users/bajtos/src/loopback/next/packages/cli/node_modules/yeoman-generator/lib/index.js:425:13)
    at runCallback (timers.js:694:18)
    at tryOnImmediate (timers.js:665:5)
    at processImmediate (timers.js:647:5)
Emitted 'error' event at:
    at Immediate.setImmediate (/Users/bajtos/src/loopback/next/packages/cli/node_modules/yeoman-generator/lib/index.js:433:22)
    at runCallback (timers.js:694:18)
    at tryOnImmediate (timers.js:665:5)
    at processImmediate (timers.js:647:5)

Expected Behavior

The datasource is created.

See Reporting Issues for more tips on writing good issues

@bajtos
Copy link
Member Author

bajtos commented Sep 11, 2018

When I select the kv-redis connector, everything works as expected.

@bajtos bajtos added the p1 label Sep 11, 2018
marioestradarosa added a commit to marioestradarosa/loopback-next that referenced this issue Sep 12, 2018
@marioestradarosa marioestradarosa self-assigned this Sep 12, 2018
marioestradarosa added a commit to marioestradarosa/loopback-next that referenced this issue Sep 12, 2018
marioestradarosa added a commit to marioestradarosa/loopback-next that referenced this issue Sep 12, 2018
marioestradarosa added a commit to marioestradarosa/loopback-next that referenced this issue Sep 12, 2018
marioestradarosa added a commit to marioestradarosa/loopback-next that referenced this issue Sep 12, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants