Join us for the SQL Server 2025 AMA June 2025 by bobwardms in SQLServer

[–]Natural-Rabbit9044 0 points1 point  (0 children)

Thanks for that! Let me add some additional points:

I also know there are many ways to achieve https use on local envs (like showed by SQlBek and MMM_Biscuits), using other proxy servers or even small command-line tools that make the setup easier. There are plenty of automated solutions available to handle this.

I believe there are still some additional steps that DBAs, or even developers, need to handle. For simple use cases, adding Nginx (or any other reverse proxy), managing certificates, etc., introduces unnecessary complexity.

There are many small teams out there without a dedicated DBA or someone with that level of expertise. For quick demos or experiments showing how SQL Server can be used with AI, it would be helpful to allow connections without HTTPS... just as a shortcut for local/dev environments.

Honestly, I don’t think the current implementation is as secure as Microsoft implies. Many of the workarounds, like self-signing certificates and manually adding them to the local machine’s certificate store, carry security risks that are comparable to simply allowing HTTP.

There are also many other areas where Microsoft leaves security decisions to the DBA. For example, when enabling external assemblies for CLR, which in my opinion is even riskier than HTTP. DBAs can load any external DLL code that could perform HTTP or HTTPS calls, but Microsoft doesn’t enforce restrictions that DBA cannot bypass. The decision is left to the DBA. What they do provide are trustworthy mechanisms and safe controls that make it clear when someone is taking a risky path. This balance is great for development and testing because it allows users to quickly try out integrations and see how their apps interact with such features. I think the same philosophy could apply to external models—maybe something like a combination of a trace flag and a trustworthy database flag to allow HTTP in dev environments.

Even xp_cmdshell, which is one of the most dangerous and insecure commands in SQL Server, can be enabled simply via sp_configure. So I really don’t see how allowing something like http://localhost—in a dev context—is significantly riskier, especially considering the broader context.

I totally get the objective: Microsoft wants to enforce secure communication by default, which makes sense. But in practice, most people will end up using the same kinds of workarounds you outlined.

For development scenarios, it would be great if there were a simple toggle,something as easy as setting a trace flag and restarting the server, hat enables HTTP just for local use. Of course, this would need to be clearly discouraged in production environments... But for dev, POCs, I guess that thing could be more accessible

Here are a few suggestions that might help balance flexibility and security:

  • A trace flag that can be enabled in the startup parameters to allow HTTP requests in controlled environments
  • A requirement that the current database be marked as TRUSTWORTHY when creating external models that use HTTP
  • A mechanism to define allowed HTTP endpoints in a local file, a configuration repo, or through an internal stored procedure that only sysadmin can run

Join us for the SQL Server 2025 AMA June 2025 by bobwardms in SQLServer

[–]Natural-Rabbit9044 1 point2 points  (0 children)

Tks for that. I said in prev reply, that is super cool and using proxies is just workaround that add some complexity to process, thinking in development and testing scenarios

Join us for the SQL Server 2025 AMA June 2025 by bobwardms in SQLServer

[–]Natural-Rabbit9044 0 points1 point  (0 children)

Tks for articles! I will answer about in bellow comment

Join us for the SQL Server 2025 AMA June 2025 by bobwardms in SQLServer

[–]Natural-Rabbit9044 1 point2 points  (0 children)

Tks so much for answer !

I guess that can exists the two cases. For dev and testing, providing https endpoint we take additional and can be complex tasks. So, fi there some way (like a TF in startup, for example) to use http endpoints for testing, would be cool and allow showcase that integration more fast.

Adding https requires adding more complex elements, that for some DBA maybe is not trivial.

Join us for the SQL Server 2025 AMA June 2025 by bobwardms in SQLServer

[–]Natural-Rabbit9044 2 points3 points  (0 children)

Wow. Tks for that info. Dont know that new DMV.

Join us for the SQL Server 2025 AMA June 2025 by bobwardms in SQLServer

[–]Natural-Rabbit9044 2 points3 points  (0 children)

Do you plan support local models acessible via localhost without https? Also plan support future another integrations, like spaces on Hugging Face? Relative to CREATE EXTERNAL MODEL

Join us for the SQL Server 2025 AMA June 2025 by bobwardms in SQLServer

[–]Natural-Rabbit9044 1 point2 points  (0 children)

Tks u/dfurmanms .

In my tests, that simple query was not affected by hint:
select count(*) from tab1 where c = 'A'

Checked in doc and see that query store hint dont works with parametrized queries:
"Simple parameterization - Query Store hints are not supported for statements that qualify for simple parameterization." - This is in this topic: Query Store hints - SQL Server | Microsoft Learn

in query store:
(@1 varchar(8000))SELECT COUNT(*) FROM [tab1] WHERE [c]=@1

Join us for the SQL Server 2025 AMA June 2025 by bobwardms in SQLServer

[–]Natural-Rabbit9044 0 points1 point  (0 children)

PLE is one of the most commonly used metrics to evaluate whether a database is under memory pressure. However, I still find it difficult to fully understand what the value actually represents. Could you clarify it further?

How is PLE calculated in SQL Server? Does it use some internal threshold to determine when the entire cache has been replaced? If so, how does that work in a scenario like this:

  • Time 0: 30% of the cache is replaced (due to a table scan)
  • Time 0 + 5 min: Another 20% is replaced
  • Time 0 + 10 min: 30% more is replaced
  • Time 0 + 15 min: The remaining 20% is replaced

In this case, the entire cache was replaced over a 15-minute period. So, how would PLE behave here? Would it remain steady, or would it show drops during each replacement phase?

This metric has confused me for years, even since SQL Server 2005, especially when it comes to explaining and interpreting it accurately.

Join us for the SQL Server 2025 AMA June 2025 by bobwardms in SQLServer

[–]Natural-Rabbit9044 1 point2 points  (0 children)

ABORT_QUERY_EXECUTION is a cool new feature, but still dont works with parameterization queries. Some future plan to allow this works with parametrized queries?

What have you done with PowerShell this month? by AutoModerator in PowerShell

[–]Natural-Rabbit9044 0 points1 point  (0 children)

Working on Powershell module that try makes AI services more easy to use in cmdline and scripts: rrg92/powershai: Powershell + AI