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

Command './setup.sh YOURSECRET "dashdb-for-transactions"' partially fails #11

Closed
lee-zhg opened this issue Oct 13, 2020 · 6 comments
Closed
Assignees
Labels
help wanted Extra attention is needed

Comments

@lee-zhg
Copy link
Contributor

lee-zhg commented Oct 13, 2020

When running command
./setup.sh YOURSECRET "dashdb-for-transactions"

It partially fails. It fails to create table and add sample data. It returns

ok: created namespace slackbot
If you are using any deprecated action runtimes, update them to continue receiving updates and support. Deprecated runtimes might be disabled in future.
For more information see https://ibm.biz/Functions-Runtimes
ok: whisk namespace set to slackbot
ok: created package slackdemo
ok: created action slackdemo/db2Setup
Credentials 'slackbotkey' from 'dashdb-for-transactions' service instance 'eventDB' bound to 'slackdemo/db2Setup'.
{
"dberror": {}
}
{
"dberror": {}
}
ok: created action slackdemo/dispatch
Credentials 'slackbotkey' from 'dashdb-for-transactions' service instance 'eventDB' bound to 'slackdemo/dispatch'.

@lee-zhg
Copy link
Contributor Author

lee-zhg commented Oct 13, 2020

dsn=params.__bx_creds[Object.keys(params.__bx_creds)[0]].dsn;

"dsn" returned by the above code is "undefined"

@data-henrik
Copy link
Contributor

This is my result. I assume the error you are seeing is related to #10. It could be that provisioning your database service was not successful. Hence you have trouble accessing the Db2 management console and see the error caused by missing credentials.

My recommendation is to recreate the Db2 service, i.e., delete it, then create it again.

$ sh setup.sh foobar "dashdb-for-transactions"
ok: created namespace slackbot
If you are using any deprecated action runtimes, update them to continue receiving updates and support. Deprecated runtimes might be disabled in future.
For more information see <https://ibm.biz/Functions-Runtimes>
ok: whisk namespace set to slackbot
ok: created package slackdemo
ok: created action slackdemo/db2Setup
Credentials 'slackbotkey' from 'dashdb-for-transactions' service instance 'eventDB' bound to 'slackdemo/db2Setup'.
{
    "result": []
}
{
    "result": []
}
ok: created action slackdemo/dispatch
Credentials 'slackbotkey' from 'dashdb-for-transactions' service instance 'eventDB' bound to 'slackdemo/dispatch'.

@data-henrik data-henrik self-assigned this Oct 14, 2020
@data-henrik data-henrik added the help wanted Extra attention is needed label Oct 14, 2020
@data-henrik
Copy link
Contributor

I am closing this issue. Please reopen if my recommendation does not solve the issue.

@lee-zhg
Copy link
Contributor Author

lee-zhg commented Oct 14, 2020

@data-henrik what data center did you use to provision the DB2 instance when testing? Thank you

@data-henrik
Copy link
Contributor

@lee-zhg let's communicate via #10

@lee-zhg
Copy link
Contributor Author

lee-zhg commented Oct 14, 2020

@data-henrik, This morning I run everything again in IBM Cloud Shell as you did not encounter the same issue. And, I got the same result as I did on my local machine yesterday.

Could you please try it in Cloud Shell? It can ensure we run the process in the same environment. I feel we may have a diff CLI env as we see diff result. I am interesting to see if it works for you in Cloud Shell.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants