简体   繁体   English

Cloud Explorer等效调试VS2022用于上传到存储的压缩发布代码?

[英]Cloud Explorer Equivalent Debug VS2022 for zipped published code uploaded to storage?

Cloud explorer in VS2022 has been removed. VS2022 中的云资源管理器已被删除。 I publish & zip the code and upload it to Azure in a private azure storage account that then runs Function Apps (running from a package file).我发布并压缩代码并将其上传到 Azure 中的私有 azure 存储帐户,然后运行 ​​Function Apps(从包文件运行)。 How can I debug remotely like I used to do with clould explorer?如何像以前使用 cloud explorer 一样进行远程调试?

Publish does not offer the Hosting option. Publish 不提供托管选项。 so the Stackoverflow answers don't work for me.所以Stackoverflow 的答案对我不起作用。 Also I have connected the Function App to Connected Services and I click on Attach debuger but it does not stop the code when executed, ie step-in code to debug doesn't work like Cloud Explorer did.此外,我已将函数应用程序连接到连接的服务,然后单击附加调试器,但它不会在执行时停止代码,即调试的步入代码不像 Cloud Explorer 那样工作。

在此处输入图像描述

在此处输入图像描述

After deployment checks some settings.部署后检查一些设置。

  1. Check Remote debugging is ON on azure portal and Select the Remote Visual Studio version, if not selected.检查 Azure 门户上的远程调试是否已打开,如果未选择,请选择远程 Visual Studio 版本。

在此处输入图像描述

  1. Go to visual studio and go-to tool and select get tool and features.转到 Visual Studio 和转到工具,然后选择获取工具和功能。 You just need to take Azure development.您只需要进行 Azure 开发。 after this Storage Emulator is automatically installed if not installed go to the Microsoft site and install this.如果未安装此 Storage Emulator 会自动安装后,请转到 Microsoft 站点并安装它。在此处输入图像描述

  2. If installed you can run it by using this command.如果已安装,您可以使用此命令运行它。 AzureStorageEmulator.exe start . AzureStorageEmulator.exe start More information about Azure Storage Emulator for Development and testing by Microsoft Document on Microsoft 文档中有关用于开发和测试的 Azure 存储模拟器的更多信息

  3. Change Configuration from Release to Debug.将配置从发布更改为调试。 在此处输入图像描述

在此处输入图像描述

  1. Start Azure Storage Emulator below cmds.在 cmds 下启动 Azure 存储模拟器。 if not installed in your system click here to Download from the Microsoft site.如果您的系统中未安装,请 单击此处从 Microsoft 站点下载
C:\Program Files (x86)\Microsoft SDKs\Azure\Storage Emulator>AzureStorageEmulator.exe
Windows Azure Storage Emulator 5.10.0.0 command line tool
Error: Expected command as first argument.
Usage:
    AzureStorageEmulator.exe init            : Initialize the emulator database and configuration.
    AzureStorageEmulator.exe start           : Start the emulator.
    AzureStorageEmulator.exe stop            : Stop the emulator.
    AzureStorageEmulator.exe status          : Get current emulator status.
    AzureStorageEmulator.exe clear           : Delete all data in the emulator.
    AzureStorageEmulator.exe help [command]  : Show general or command-specific help.

See the following URL for more command line help: http://go.microsoft.com/fwlink/?LinkId=392235

C:\Program Files (x86)\Microsoft SDKs\Azure\Storage Emulator>AzureStorageEmulator.exe start
Windows Azure Storage Emulator 5.10.0.0 command line tool
Autodetect requested. Autodetecting SQL Instance to use.
Looking for a LocalDB Installation.
Probing SQL Instance: '(localdb)\MSSQLLocalDB'.
Found a LocalDB Installation.
Probing SQL Instance: '(localdb)\MSSQLLocalDB'.
Found SQL Instance (localdb)\MSSQLLocalDB.
Creating database AzureStorageEmulatorDb510 on SQL instance '(localdb)\MSSQLLocalDB'.

Granting database access to user FAREAST\v-pusharma.
Database access for user FAREAST\v-pusharma was granted.

Initialization successful. The storage emulator is now ready for use.
Error: Unable to start the storage emulator.

C:\Program Files (x86)\Microsoft SDKs\Azure\Storage Emulator>netstat -p tcp -ano | findstr :10000
  TCP    127.0.0.1:10000        0.0.0.0:0              LISTENING       9764

C:\Program Files (x86)\Microsoft SDKs\Azure\Storage Emulator>taskkill /F /PID 9764
SUCCESS: The process with PID 9764 has been terminated.

C:\Program Files (x86)\Microsoft SDKs\Azure\Storage Emulator>AzureStorageEmulator.exe start
Windows Azure Storage Emulator 5.10.0.0 command line tool
The storage emulator was successfully started.

C:\Program Files (x86)\Microsoft SDKs\Azure\Storage Emulator>
  1. Check whether Storage Emulator show is connected or not.检查 Storage Emulator show 是否已连接。在此处输入图像描述

  2. Then add break point on visiual studio and run function .然后在视觉工作室添加断点并运行功能。 it's working,它正在工作,在此处输入图像描述

Using this option to attach debug remotely.使用此选项远程附加调试。 because in visual studio 2022 not show Cloud Explorer.因为在 Visual Studio 2022 中不显示 Cloud Explorer。在此处输入图像描述

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何使 azure function 使用 VS2022 发布的最新代码 - how to make azure function use the latest code published from VS2022 Azure 功能:Blob 存储模拟器在移动到 VS2022 后停止工作 - Azure Functions: Blob Storage emulator stopped working after moving to VS2022 使用 .Net6 (VS2022) 创建的持久 Azure 函数在本地进行调试,导致找不到源 - Durable Azure Function created with .Net6 (VS2022) debugging locally giving Source Not Found 你能直接从 VS2022 发布一个新的独立 Angular 项目 (esproj) 到 Azure 吗? - Can you publish a new standalone Angular project (esproj) directly from VS2022 to Azure? VS2022 中的发布目标缺少部署到 Azure 容器应用程序 - Deploy To Azure Container Apps is Missing from Publish Targets in VS2022 VS2022 配置 Azure keyvault 看不到本地 secrets.json - VS2022 Configure Azure keyvault not seeing local secrets.json 通过AJAX上传到Azure云存储的文件已损坏 - Files Uploaded Via AJAX to Azure Cloud Storage are corrupted 上传到存储帐户的潜在恶意软件与上传到存储 Blob 容器的潜在恶意软件 - Potential malware uploaded to a storage account vs Potential malware uploaded to a storage blob container ARM 模板 - 在 Azure 存储 Blob 中使用 MSDeploy 和压缩代码部署函数 - ARM Template - Deploying function using MSDeploy with zipped code in Azure Storage Blob 在Visual Studio Server Explorer中访问存储时,Azure Cloud Service停止保存到表存储 - Azure Cloud Service stops saving to table storage when storage is accessed in visual studio server explorer
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM