0

I have permissions, and can create Databases/Tables in the console just fine. but when i make code using the aws-sdk it fails with an InternalServerException: Internal Server Error. Is this only supported in the v3 api?

    const params = {
        DatabaseName,
        Tags: getDefaultTags(customer,username)
    };
    console.log(params);
    const promise = writeClient.createDatabase(params).promise();

to repeat, this is not a permissions issue, I have the region specified, I just get an internal error if I try to use the SDK:

   InternalServerException: Internal Server Error
    at Request.extractError (<<coderoot>>\node_modules\aws-sdk\lib\protocol\json.js:52:27)
    at Request.callListeners (<<coderoot>>\node_modules\aws-sdk\lib\sequential_executor.js:106:20)
    at Request.emit (<<coderoot>>\node_modules\aws-sdk\lib\sequential_executor.js:78:10)
    at Request.emit (<<coderoot>>\node_modules\aws-sdk\lib\request.js:686:14)
    at Request.transition (<<coderoot>>\node_modules\aws-sdk\lib\request.js:22:10)
    at AcceptorStateMachine.runTo (<<coderoot>>\node_modules\aws-sdk\lib\state_machine.js:14:12)
    at <<coderoot>>\node_modules\aws-sdk\lib\state_machine.js:26:10
    at Request.<anonymous> (<<coderoot>>\node_modules\aws-sdk\lib\request.js:38:9)
    at Request.<anonymous> (<<coderoot>>\node_modules\aws-sdk\lib\request.js:688:12)
    at Request.callListeners (<<coderoot>>\node_modules\aws-sdk\lib\sequential_executor.js:116:18)

if I use the v3, I get the same error eventually, this example is creating a table, but it's the same idea:

InternalServerException: Internal Server Error
    at deserializeAws_json1_0InternalServerExceptionResponse (<<coderoot>>\node_modules\@aws-sdk\client-timestream-write\dist-cjs\protocols\Aws_json1_0.js:899:23)
    at deserializeAws_json1_0CreateTableCommandError (<<coderoot>>\node_modules\@aws-sdk\client-timestream-write\dist-cjs\protocols\Aws_json1_0.js:239:25)
    at processTicksAndRejections (node:internal/process/task_queues:96:5)
    at async <<coderoot>>\node_modules\@aws-sdk\middleware-serde\dist-cjs\deserializerMiddleware.js:7:24
    at async <<coderoot>>\node_modules\@aws-sdk\middleware-signing\dist-cjs\middleware.js:13:20
    at async StandardRetryStrategy.retry (<<coderoot>>\node_modules\@aws-sdk\middleware-retry\dist-cjs\StandardRetryStrategy.js:51:46)
    at async <<coderoot>>\node_modules\@aws-sdk\middleware-logger\dist-cjs\loggerMiddleware.js:6:22
    at async Object.createTable (<<coderoot>>\timestream.db.js:228:22)
    at async handleCustomerCreation (<<coderoot>>\router.js:60:21)
    at async router (<<coderoot>>\router.js:266:13)
Dave
  • 867
  • 6
  • 11

0 Answers0