Azure-docs: Can't execute a stored procedure using Emulator

Created on 2 Apr 2018  Â·  24Comments  Â·  Source: MicrosoftDocs/azure-docs

I am running emulator V1.20.108.4 and I don't have the option to "Execute" a stored proc on it, though I can still execute the same using the Azure Portal (or via SDKs ofcourse!). Is this something that can/will be added in the future in emulator as well ? Also can the docs be updated ?


Document Details

⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

assigned-to-author cosmos-dsvc product-question triaged

Most helpful comment

@Ramji-S @wpitallo
Hi there,

I'm the dev owner of the emulator and available to chat here and by Skype, if you prefer. We are actively working on updates to the Emulator's Web UI for greater parity with cloud. The effort's on going. Let me open this up for discussion by a wider audience. What new features would you like to see in the Web UI?

  • Execute stored procedures
  • Access console logs (a favorite of mine because it helps me to troubleshoot your issues)
  • Release information, download link (for the running version), and update link (for the latest version)

What else would you like to see and how would you stack rank the features?

All 24 comments

@Ramji-S Thanks for the feedback. We are actively investigating and will get back to you soon.

1.21.0.6 Released on March 27, 2018

"In addition to updating Emulator services for parity with Cosmos DB cloud services, we've included one new feature and two bug fixes in this release."

Upgrading to this latest emulator revision should provide you the functionality you are seeking. In terms of product feedback, this link will allow you the ability to request features or functionality that has not already been requested.

What specifically is the ask for documentation to be updated?

@Mike-Ubezzi-MSFT Thanks for the update. I just downloaded and I seem be getting the V 1.21.0.0. I still do not see the option to "Execute".

Also I was referring to documentation mentioning that when using emulator, the option to execute will be via SDK. This doesn't block me currently but without the ability to view console logs in SP, its not easy to debug.

@Ramji-S Can you point out the specific documentation pain points, as I can have the content clarified by the documentation author. Thank you.

@Ramji-S We will now proceed to close this thread. If there are further questions regarding this matter, please reopen it and we will gladly continue the discussion. Please also leverage the Cosmos DB Emulator User Voice for any future release or road map related questions.
Regards,
Mike

@Mike-Ubezzi-MSFT Please can we re-open this, we need to be able to execute stored procedures from inside the explorer not via sdk. Also need to get console logs, how else do you expect us to properly debug?

This functionality is available on the portal so why not in the emulator. console.log in UDF on the portal also does not work? Who is working on this that I can chat to?

@wpitallo The best forum for those particular requests is through Cosmos DB User Voice customer feedback.
These GitHub issues are intended to point out and correct the documentation and the tutorials and code samples they reference. The User Voice is best for requesting features and functionality.

@Ramji-S @wpitallo
Hi there,

I'm the dev owner of the emulator and available to chat here and by Skype, if you prefer. We are actively working on updates to the Emulator's Web UI for greater parity with cloud. The effort's on going. Let me open this up for discussion by a wider audience. What new features would you like to see in the Web UI?

  • Execute stored procedures
  • Access console logs (a favorite of mine because it helps me to troubleshoot your issues)
  • Release information, download link (for the running version), and update link (for the latest version)

What else would you like to see and how would you stack rank the features?

I am reopening this GitHub issue for further discussion.

Thanks for the update @David-Noble-at-work. That pretty much summarizes my expectation with Emulator. I still access my console logs using SDK by enabling "ScriptLogging" in requestOptions but with emulator having this feature with "Execute" it would be much helpful for local dev as pointed by you. Adding one more request (minor though) is my other feedback I raised via user voice here.
Waiting for the updated version :-)

Hi, @David-Noble-at-work thanks would like to participate, intend on using cosmos db a lot so far its great but there are few things that would help a lot.

You hit the nail on the head, with those features they will greatly help. Especially the console logging. Currently the the console log is only logging to one line and does not log objects well, example: "%5Bobject%20Object%5D"

And even if it is stringified first... "%7b%22gameinstancekey%22%3a

First class logging is must please :) also the logging inside the UDF does not work at all.

Not sure if you the right person to chat about this with, but it would also be awesome if there was a DataAnnotation class similar to System.ComponentModel.DataAnnotations.Schema;. I am currently mapping documents to models in c# and it would be great if I could annotate the model with [NotMapped] so that when saving those properties will not be saved to the document.

Thanks so much, cosmos db looks awesome so far :)

Another thing that would also be quite cool would be to be able to connect to the same collection with different 'connectors'. What I mean by that is that if I want to connect to a graph db through the explorer I need to specify that it is a graph db when creating the collection. It would be great if I created a SQL collection if I could still connect to it via a graph explorer without having to create a new collection. Hope that makes sense?

A black theme would also be great extra touch.

Currently when a exception is thrown there is also no log, would be nice to see the logs even if there is an exception.

@David-Noble-at-work It might also be nice if we could increase the size of the stored procedure body window and reduce output window size. So a pane re-sizer between the two.

Its also quite frustrating that some java script commands are not supported.
eval() for example and even more frustrating, setTimeout. I am trying to put together some concurrency tests and using setTimeout that is standard in JavaScript is not available (sigh). Any reason why these are not supported?

@David-Noble-at-work, collapse/expand methods inside stored procedures

@David-Noble-at-work @Mike-Ubezzi-MSFT, so I have some use cases for cosmos db around bulk transaction processing that I would like to hopefully chat to someone about if possible. I have looked online but the documentation around this is very limited. Any idea you could point me to the best person or place to discuss this?

@wpitallo If there is a specific document that does not provide adequate details about a topic or needs some enhancements, it is best to use the 'Provide document feedback' link at the bottom of that specific content. This ensures the feedback goes to the content owner(s).
If there is a set of features or functionality that is desired then selecting the 'Provide product feedback' will take you to a User Voice forum that allows for requesting enhancements:

github_feedback

This is the desired process, unless there is an exception made, like in the case where the documentation hasn't been migrated over to GitHub just yet or the product owner is also the content owner, as is the case here with the Cosmos DB Emulator.

Thanks,
Mike

Awesome, Thanks Mike!

@David-Noble-at-work Line numbers would also be quite cool, linked to the exceptions

Emulator requires admin consent to start up. This makes it difficult to use as part of unit testing automation on our builds. Is there a reason this requires admin consent while the Azure Storage Emulator which has similar DB functionality for Azure Storage does not require admin consent. Would be great to run unit testing against the emulator for continuous builds and the only run against real thing for Integration and System testing down the pipeline.

@David-Noble-at-work I see you are already handling the issues where most of them correspond to product enhancement. As you handling them offline, we will now proceed to closing this issue.

please-close

Was this page helpful?
0 / 5 - 0 ratings

Related issues

monteledwards picture monteledwards  Â·  3Comments

behnam89 picture behnam89  Â·  3Comments

spottedmahn picture spottedmahn  Â·  3Comments

bdcoder2 picture bdcoder2  Â·  3Comments

mrdfuse picture mrdfuse  Â·  3Comments