Commit Graph

1026 Commits

Author SHA1 Message Date
Azure SDK Bot
54872294f9
Increment package version after release of azure-core (#6168)
---------

Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-11-01 16:21:12 -07:00
Anton Kolesnyk
0180c8ee5c
HttpShared::GenerateUserAgent() (#6163)
* Rename UserAgentGenerator

* Update includes

* Clang-format

* Move GenerateUserAgent() to HttpShared class

* Update invocations

* Update invocations

* Clang-format

* Drop unnecessary include

* Update release dates

---------

Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-11-01 14:07:45 -07:00
Anton Kolesnyk
99e0895a5d
Move UserAgentGenerator to _internal (#6067)
* Move UserAgentGenerator to _internal

* Clang-format

* Update release date to November release (Core)

* Update release date to November release (EventHubs)

* _MSVC_LANG

* Move comment up

* Add /Zc:__cplusplus when building the SDK, and add unittest

---------

Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-10-31 10:00:12 -07:00
Ahson Khan
064fcad72f
Set token to be expired if response comes back as unauthorized, within BeareTokenAuthenticationPolicy. (#6151)
* Set token to be expired if response comes back as unauthorized.

* Add CL entry.

* Update CL.

* Use trc MinimumExpiration to invalidate the credential's token cache.

* Add test.

* Address PR feedback.

* Remove comment as it is no longer relevant.

* Use initializer list syntax to see if posix compilers are okay with that.

* Keep the bool field as non-atomic.

* Revert "Keep the bool field as non-atomic."

This reverts commit 1b8c7622d5234b010bb0a4eb5db8a436de5a2adf.
2024-10-30 14:00:42 -07:00
Anton Kolesnyk
bf550f2544
Acknowledge community contribution to Core (#6091)
* Acknowledge community contribution to Core

* Update CHANGELOG.md

---------

Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-10-11 21:06:40 +00:00
James Le Cuirot
a091f4c8e0
Set VERSION property against all libraries to write versioned SONAME (#6087)
The SONAME currently written to shared libraries is unversioned, e.g.
libazure-core.so. The SDK's ABI is unstable, so replacing these .so
files with newer versions will immediately break any consumers.

Setting the VERSION property results in libazure-core.so being a symlink
that is used at build time to point to the versioned library, e.g.
libazure-core.so.1.14.0. Consumers point directly to the versioned
library and continue to work against the older version when the library
is upgraded. Once rebuilt, they then point to the newer version instead.

It is more common to use an ABI version that is separate to the library
version, but it makes sense to use the latter when the ABI is unstable.
The Boost libraries do exactly this.

This change has no effect on static libraries, which is the more common
use case. See the CMake documentation for its wider effects.

https://cmake.org/cmake/help/latest/prop_tgt/VERSION.html
2024-10-11 11:42:13 -07:00
Ahson Khan
8f8d24280f
Fixed warning for an unused function in curl.cpp when building the SDK using a version of libcurl older than 7.77.0 (#6073) 2024-10-07 16:28:25 -07:00
Azure SDK Bot
4722e3df3c
Increment package version after release of azure-core (#6062)
Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-10-03 19:50:04 -07:00
Anton Kolesnyk
9aa25a063d
UserAgentGenerator compatibility for previously published EventHubs (#6063)
Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-10-03 19:48:47 -07:00
Anton Kolesnyk
1289063cc2
Azure Core October GA Release (#6053)
* Azure Core October GA Release

* Change to re-trigger CI

* Undo change, still re-trigger CI

* Update sdk/core/azure-core/CHANGELOG.md

Co-authored-by: Larry Osterman <LarryOsterman@users.noreply.github.com>

* Also update wording in the previous release

* Spelling

---------

Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
Co-authored-by: Larry Osterman <LarryOsterman@users.noreply.github.com>
2024-10-03 11:29:28 -07:00
Ahson Khan
5a6176706d
Add basic input validation to ResourceIdentifier for ensuring the prefix match what is expected. (#6056)
* Initial verification and tests.

* Simplify validation checks to what's needed.

* Update changelog entry.

* Fix typo and disable cspell for a test line.

* Address PR feedback.
2024-10-02 06:42:01 +00:00
Anton Kolesnyk
171386533a
Fix/unify links in CHANGELOG.md files (#6048)
Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-09-30 12:35:55 -07:00
Anton Kolesnyk
488b65e6a2
Acknowledge community contributions in Changelog (#6047)
* Acknowledge community contributions in Changelog

* Update cspell.json

* Update sdk/core/azure-core/CHANGELOG.md

---------

Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
Co-authored-by: Ahson Khan <ahkha@microsoft.com>
2024-09-27 17:00:43 -07:00
Ahson Khan
aa728eed6d
Use code snippets from managed identity credential samples in identity readme doc and fix minor generation issues (#6020)
* Use code snippets from managed identity credential samples in identity readme doc.

* Generate readme from snippets.

* Update snippet generation script to remove unnecessary indentation and extra new line at eof.

* Update Snippet Generation doc to show a concrete example on how to run it.

* Update other repo READMEs with the generation fixes.

* Fix KeyVault Secrets sample and use the snippets in its README

* Use the added sample snippet.
2024-09-25 16:56:57 -07:00
Ahson Khan
23729124bd
Make the HTTP transport behavior consistent between WinHTTP and libcurl by disabling automatically following redirects on Windows. (#6018)
* Make the HTTP transport behavior consistent between WinHTTP and libCurl by disabling automatically following redirects on Windows.

* Re-enable APC test.

* Fix casing in changelog.

* Add http bin based unit test and fix typo in doc comment for curl.

* Update test name to avoid 'dont'

* Fix typo.
2024-09-24 13:14:08 -07:00
James Le Cuirot
7fea3ff677
Fix etag.hpp comment that breaks Doxygen 1.12.0 (#6014)
Unfortunately, "*" breaks Doxygen 1.12.0 with the following error:

    error: end of comment block while expecting command </em>

I have no idea why. Anything else like '*' or "x" works, but "*" was
clearly intended here. The best I can suggest is: * in quotes.
2024-09-20 08:51:25 -07:00
Azure SDK Bot
da2ea2113d
Increment version for core releases (#5980)
* Increment package version after release of azure-core-amqp

* Increment package version after release of azure-core

---------

Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-09-12 11:22:35 -07:00
Anton Kolesnyk
cfbe21ca82
Azure Core September Releases (#5975)
* Azure Core September Releases

* Update CHANGELOG.md

---------

Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-09-12 07:38:49 -07:00
Larry Osterman
b45276fc24
Update CHANGELOG.md for September release (#5976) 2024-09-11 15:40:39 -07:00
Ahson Khan
c3265d3e5b
Fix input validation check for TimeFractionFormat in the DateTime ToString method (#5927)
* Fix input validation check for TimeFractionFormat in the DateTime ToString() method.

* Add changelog entry.

* Use switch-case instead of static casting the enum values.

* Address CL PR feedback.

* Fix the features added CL to put ResourceIdentifier in the right release.

* Address PR feedback - use type traits
2024-09-10 14:35:07 -07:00
Ahson Khan
ea3f1442b2
Move the ResourceIdentifier type from Azure::Identity to Azure::Core. (#5864)
* Move the ResourceIdentifier type from Identity to Azure::Core.

* Fix the namespace in the source cpp file.

* Fix managed identity credential tests.

* Fix clang format.
2024-09-05 15:22:18 -04:00
Anton Kolesnyk
6ae78faec8
Update Uuid parameter name, and improve tests (#5943)
* Update Uuid parameter name, and improve tests

* Update sdk/core/azure-core/inc/azure/core/uuid.hpp

Co-authored-by: Rick Winter <rick.winter@microsoft.com>

---------

Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
Co-authored-by: Rick Winter <rick.winter@microsoft.com>
2024-08-27 18:40:54 -07:00
Anton Kolesnyk
91608bb5dc
Uuid::operator==(): self-comparison optimization, and more tests (#5939)
Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-08-27 14:22:21 -07:00
Anton Kolesnyk
ee0c7565df
Uuid: add default ctor and Parse() (#5935)
* Uuid: add default ctor and Parse()

* Fix merge, integrate better

* nano-optimization for IsNil()

* Changelog

* Pedantism

* GCC fix

* GCC fix (include <stdexcept>)

* PR feedback

* Update sdk/core/azure-core/test/ut/uuid_test.cpp

Co-authored-by: Rick Winter <rick.winter@microsoft.com>

* Comments for bad tests

* Add doxygen comments

* One more constexpr, and clang-format

---------

Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
Co-authored-by: Rick Winter <rick.winter@microsoft.com>
2024-08-23 23:15:24 -07:00
Ahson Khan
d8b555a670
Optimize Uuid.ToString() by avoiding using sprintf to do the basic string transformation (#5925)
* Optimize Uuid.ToString() to use a cached value on multiple calls.

* Add tests which call ToString() multiple times.

* Optimize Uuid::ToString by avoiding using sprintf.

* Assert all byte values will fit into a hex character.

* Update comment in test.
2024-08-22 17:34:17 -07:00
Larry Osterman
ef538101f2
V2 of integrating uAMQP vixes into vendored copy (#5931) 2024-08-21 12:19:31 -07:00
Larry Osterman
d74b08f8b3
AMQP static analysis fixes (#5918)
* AMQP static analysis fixes?
2024-08-16 20:49:06 -07:00
Ahson Khan
54a7bc363b
Add support for providing an object ID to ManagedIdentityCredential. (#5910)
* Add support for providing an object ID to ManagedIdentityCredential.

* Update cspell checks.

* Add support for creating a Uuid from a string, and use that as the
MICred overload for objectId.

* Add a remark comment to make it clear that object and client ids are not interchangeable.

* Remove the non-const ToString() as that isn't required.

* Update tests to use valid hex Uuid values.

* Use a discriminated union design approach with a ManagedIdentityType
object and ManagedIdentityIdType enum.

* Fix typo and remove Uuid CreateFromString.

* Address PR feedback.

* Update doc comment.

* Update comments and exception message to consistently use hyphens
between user/system and assigned.
2024-08-16 20:47:05 -07:00
Larry Osterman
863e2b2b91
Ported uAMQP changes to vendored copy of uAMQP (#5917) 2024-08-15 22:28:08 -07:00
George Arama
70dc0ebecb
Log policy extra headers (#5868)
* log policy extra headers

* failing test

* adding back WWW-Authenticate

* changelog update

* Update sdk/core/azure-core/CHANGELOG.md

Co-authored-by: Ahson Khan <ahkha@microsoft.com>

---------

Co-authored-by: Ahson Khan <ahkha@microsoft.com>
2024-08-07 17:40:37 +00:00
Azure SDK Bot
cd385362f9
Increment package version after release of azure-core (#5870)
Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-08-01 22:38:35 +00:00
Anton Kolesnyk
8fdb1fcd57
Azure Core August Beta Release (#5858)
Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-08-01 14:11:08 -07:00
George Arama
34c2441523
Enable UseFederatedAuth by default (#5852)
* enable use federated

* 401 unauthorized

* 401

* cleanup readmes

* DISABLE RUN

* Remove UseFederatedAuth overrides from ci.yml

* DISABLE RUN for admin samples,
2024-07-31 17:10:39 -07:00
Anton Kolesnyk
2c0a35dad4
Undo unnecessary Core vcpkg dependency version bump (#5860)
Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-07-31 22:23:29 +00:00
Anton Kolesnyk
d32aab96eb
Acknowledge community contributions in changelogs (#5850)
* Acknowledge cusomer contributions

* Update cspell

* Add more contributors

* More cspell

* Update contributions

---------

Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-07-31 13:44:28 -07:00
Robert Schulze
401b97e0ac
Remove unneeded <regex> includes (#5851)
* Remove unneeded <regex> includes

* Fix build (hopefully)
2024-07-31 13:07:47 -07:00
Anton Kolesnyk
0f62b3aa63
Add consumption-time value of __cplusplus to User-Agent (#5662)
* Add consumption-time value of __cplusplus to User-Agent

---------

Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-07-29 18:31:51 -07:00
Larry Osterman
90089ad326
Cleaned up Azure::Core::Context API surface (#5676)
* Deprecated Azure::Core::ApplicationContext because its use is confusing and inconsistent with the original design. 

---------

Co-authored-by: Rick Winter <rick.winter@microsoft.com>
Co-authored-by: Anton Kolesnyk <41349689+antkmsft@users.noreply.github.com>
Co-authored-by: Ahson Khan <ahkha@microsoft.com>
2024-07-17 12:38:30 -07:00
Larry Osterman
2b987eeed8
Improve code coverage numbers by excluding some options (#5805)
* Potentially improve code coverage numbers by excluding some options

* Removed dead lines; replicated switches to both gcovr executions

* added link to gcovr branch coverage faq
2024-07-17 18:36:10 +00:00
Anton Kolesnyk
e47e3168fe
Acknowledge community contribution in the changelog (#5797)
* Mention community contribution in the changelog

* cspell

* Remove double spaces

---------

Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-07-15 18:45:06 +00:00
Azure SDK Bot
fb6c039f5e
Increment package version after release of azure-core (#5794) 2024-07-12 21:34:14 +00:00
Anton Kolesnyk
6b9e1cc691
Revert commits related to the new RetryPolicy method (#5793)
* Revert "Update the RetryPolicy for the GA release, keeping ShouldRetry extension point hidden. (#5771)"

This reverts commit 9ccd206ff8.

* Revert "Update the RetryPolicy and ShouldRetry customization logic to allow loosening the retry condition. (#5656)"

This reverts commit f1d95520d1.

* Do not remove changelog entry from a previous beta release

* Revert "Add a virtual ShouldRetry method to the RetryPolicy for customization. (#5584)"

This reverts commit ab90ef68b0.

---------

Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-07-12 12:03:43 -07:00
Anton Kolesnyk
e8c7c559d9
Azure Core July GA Release (#5792)
Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-07-12 10:24:12 -07:00
Ahson Khan
9ccd206ff8
Update the RetryPolicy for the GA release, keeping ShouldRetry extension point hidden. (#5771)
* Update the RetryPolicy for the GA release, keeping ShouldRetry extension
point hidden.

* Mark test helper virtual functions private, so they aren't
accessible/callable by callers.

* Update the changelog.

* Update CL.
2024-07-11 17:39:37 -07:00
George Arama
313fb0e58f
Move tests to use azure pipeline credentials (#5754)
* test1

* hgdfchg

* remove the remnants of azure client secret

* test KV with federated auth

* UseFederatedAuth

* fdsa

* kv template with managed

* try try again

* retry permissions

* add net acls

* blunt force replace the resource json

* put back stuff

* trey again with new method

* attempt

* missed something

* flip if else

* Temporarily use empty sub config file path for preview cloud

* remove client secret

* try to fix the identity tests

* live skip failing tests and return in samples

* samples for identity fix

* disable failing samples in identity

* fix winhttp failing test

* comment out code

* remove managed identity

* restore version from main

* revert readme changes

* PR comments

* test 2

* clang

* attempt default creds with pipeline chanined

* clangs

* identity test and clangs

* oops

* live

* cleanup

* reter

* test

* revert the DAC change

* missed one

* taking the samples to a farm upstate

* PR comments

* Fix bad merge

---------

Co-authored-by: Daniel Jurek <djurek@microsoft.com>
Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
Co-authored-by: Anton Kolesnyk <41349689+antkmsft@users.noreply.github.com>
2024-07-11 17:38:19 -07:00
Anton Kolesnyk
22f5135d4c
Update vcpkg SHA (#5772) 2024-07-11 22:57:06 +00:00
Robert Schulze
8f26ebb8a8
Add missing include (#5766) 2024-07-08 09:17:46 -07:00
George Arama
0b5b5ac951
Json library update and Xcode15 (#5681)
* Move up macos and xcode version

* first pass

* to trigger builds, some other issue

* rewrwe

* Remove MSVC compiler warning suppressions in KeyVault

The code within the `mocked_transport_adapter_test.hpp` file, specifically within the `Azure::Security::KeyVault::Keys` namespace, has been updated. The `#if defined(_MSC_VER)` preprocessor directive along with its associated `#pragma warning(push)` and `#pragma warning(disable : 4996)` directives have been removed. The corresponding `#pragma warning(pop)` directive has also been removed. The lines of code that were between these preprocessor directives remain unchanged. These changes remove specific compiler warning suppressions for MSVC compilers, but do not alter the functional behavior of the code.

* dassa

* Add UseDotNet@2 where test proxy might run on a macos agent

* test CI

* fsd

* dasdas

* gregre

* gerregr

* ffdsfsd

* fwefew

* fewfwew

* reter

* fewfew

* fwefwe

* rewrw

* rwe

* temp move build step to exec faster

* gdfgd

* fsdfd

* fdsfs

* dgdf

* Roll forward instead of installing .NET 6

* remove manual install

* rewrew

* gfdffg

* rewrwe

* gfdgd

* fdsfs

* gfdgdf

* tertre

* dasda

* try http for test proxy

* revert readmes

* rew

* rew

* fdsfsd

* ewrew

* revert storages

* KV

* opentelemetry

* remove warnbing

* anton comments

* unit tests

* clangs

* clang

* comment out some asserts

* restore originals

* updated tests

* clangs

* restore cmake

* test

* Remove manual workaround (eng/common change fixes this)

* test2

* the fix doesn't work, need to put back

* Remove DOTNET_ROLL_FORWARD

* annotate macro , put back DOTNET_ROLL_FORWARD

* remove leftover files

* reww

* update changelog

* remove left over file

* remove some doxygen comments

---------

Co-authored-by: Daniel Jurek <djurek@microsoft.com>
2024-06-18 08:26:28 -07:00
Anton Kolesnyk
ef9d2a5e18
Remove 'include windows.h' from inc/* (#5691)
* Remove 'include windows.h' from inc/*

* Clang format

* Qualify namespace

* Clean up includes a bit further

* Fix errors

* Clang format

* move out _detail definitions

---------

Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-06-07 03:07:10 -07:00
Azure SDK Bot
c5d0549cb5
Increment version for core releases (#5700)
* Increment package version after release of azure-core

* Increment package version after release of azure-core-amqp
2024-06-07 00:07:00 +00:00
Anton Kolesnyk
b43174a05b
Core June Beta Release (#5696)
Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-06-06 14:42:09 -07:00
Larry Osterman
803ad17e9a
Prepare for June AMQP release (#5697)
* Prepare for June AMQP release

* Update sdk/core/azure-core-amqp/CHANGELOG.md

Co-authored-by: Anton Kolesnyk <41349689+antkmsft@users.noreply.github.com>

---------

Co-authored-by: Anton Kolesnyk <41349689+antkmsft@users.noreply.github.com>
2024-06-06 14:41:42 -07:00
Ahson Khan
f1d95520d1
Update the RetryPolicy and ShouldRetry customization logic to allow loosening the retry condition. (#5656)
* Update the RetryPolicy and ShouldRetry customization logic to allow
loosen the retry condition.

* Add CL entry and update doc comment.

* Move WasLastAttempt check out, and add more tests.

* Address PR feedback, remove use of void and unused params.
2024-05-30 11:08:56 +08:00
Larry Osterman
a9526d9375
Minor tweaks to HTTP tests found during Rust HTTP testing (#5658)
* Minor tweaks to HTTP tests found during Rust HTTP testing

* PR feedback
2024-05-23 04:15:05 +00:00
Larry Osterman
4de01d6ed7
Updated AMQP changelog (#5655)
* Updated AMQP changelog

---------

Co-authored-by: Ahson Khan <ahkha@microsoft.com>
2024-05-22 21:27:09 +00:00
Larry Osterman
4fcf09d4ec
Fixed #5536, fixed a test deadlock discovered while testing the fix for 5536, added some diagnostics for uAMQP to help track the problem. (#5651)
* Fixed 5536, cleaned up a bunch of test bugs found during testing of 5536 fix
2024-05-22 11:39:03 -07:00
Ahson Khan
7db4f3ac1c
Remove redundant calls to gtest_discover_tests with default args in AMQP tests (#5644)
* Disable AMQP LinkAttachDetachMultipleOneSession test until it has been investigated.

* Line Coverage is now at 87.8049%.

* Remove redundant calls to gtest_discover_tests with default args in AMQP
tests.

* Revert "Line Coverage is now at 87.8049%."

This reverts commit deb07e74cde7f3e915bbf0de1310d964d60d3154.

* Revert "Disable AMQP LinkAttachDetachMultipleOneSession test until it has been investigated."

This reverts commit 89c8096c906691826d35f6bd0f58d10bdffb6939.
2024-05-21 18:43:41 +00:00
Anton Kolesnyk
fdb8657f41
Add HTTP request version logging, and scope the variables (#5643)
Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-05-20 14:06:55 -07:00
Anton Kolesnyk
597d12fd6a
Update CHANGELOG acknowledgements with customer contribution (#5640)
Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-05-20 11:04:35 -07:00
Ahson Khan
f517aabb98
Clean-up the HTTP versions check in response parsing, and don't reuse connections on any response other than HTTP/1.1 (#5608)
* Harden the HTTP versions check in response parsing, validating specifically for 1.1 or 1.0, and throwing otherwise.

* Address feedback - comment was confusing.

* Update sdk/core/azure-core/src/http/curl/curl.cpp

Co-authored-by: Rick Winter <rick.winter@microsoft.com>

* Clarify the http version check and set keep-alive as false instead of throwing for non-http1.x.

* Address PR feedback - add comment snippet, and update log message.

---------

Co-authored-by: Rick Winter <rick.winter@microsoft.com>
2024-05-20 00:23:48 -07:00
Larry Osterman
260ae116cc
Switched blob checkpoint store to use both connection string and token credentials. (#5632)
* Switched blob checkpoint store to use both connection string and token credentials; re-recorded tests using token credentials

* Added environment variable to ci.yml

* Try a slightly different storage url
2024-05-17 19:51:27 +00:00
Ahson Khan
741a71ceee
Update core changelog with attribution for a curl endless loop bug fix. (#5626)
* Update core changelog with attribution for a curl endless loop bug fix.

* Update cspell for contributor github alias.

* Fix typo in json, add a comma.
2024-05-16 12:02:50 -07:00
Anton Popov
5d3f95535a
fix possible endless loop while polling curl socket (#5589) 2024-05-16 12:02:01 -07:00
Ahson Khan
b7ae7b8987
Add retries to DisableCrlValidation test to improve reliability (#5537)
* Add retries to DisableCrlValidation test to improve reliability

* Add some test logging to CurlConnection ctor.

* Fix log level

* Revert changes to curl.cpp

* Reduce attempts to 3 and validate at least one passes.

* Remove unnecessary commented out code to reset CI.

* Remove unnecessary assert that won't fail.

* Remove unused variable.
2024-05-16 18:31:59 +00:00
Ahson Khan
d895f82ef8
Add basic tests for GetMajor/Minor HTTP versions in the response. (#5613)
* Add basic tests for GetMajor/Minor HTTP versions in the response.

* Make the tests parameterized.

* Address PR feedback - add more test cases.
2024-05-16 10:51:50 -07:00
Ahson Khan
6b5a8d1e36
Update CURLCode error to the non-obsoleted value. (#5545) 2024-05-16 17:49:09 +00:00
Ahson Khan
ab90ef68b0
Add a virtual ShouldRetry method to the RetryPolicy for customization. (#5584)
* Add a virtual ShouldTry method to the RetryPolicy for customization.

* Make test hooks virtual again.

* Add unit test for ShouldRetry.

* Fix typo.

* Address PR feedback.

* Revert making the mock'd functions private for non-test builds.

* Add new line.
2024-05-14 01:09:02 +00:00
Azure SDK Bot
3b9574c610
Increment package version after release of azure-core (#5614) 2024-05-13 15:42:57 -07:00
Azure SDK Bot
52737ee6ae
Increment package version after release of azure-core-amqp (#5602) 2024-05-13 17:23:46 +00:00
Anton Kolesnyk
a0cb5dd55c
Core May GA Release (#5572)
* Core May GA Release

* Add azure-core-amqp to release

* Update date on the core changelog.

---------

Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
Co-authored-by: Ahson Khan <ahkha@microsoft.com>
2024-05-09 20:01:52 +00:00
Ahson Khan
9e80a87519
Core AMQP May beta Release (#5601) 2024-05-06 17:30:39 -07:00
George Arama
8db62bf8da
reenable the global cleanup test (#5590) 2024-05-01 14:02:09 -07:00
Larry Osterman
ec9ffac6af
Support EventHubs emulator; Added support for both connection string and azure credentials across the entire eventhubs test suite. (#5567)
* Added support for EventHubs Emulator; reworked eventhubs tests to run with ConnectionString and DefaultAzureCredential

* Don't run emulator variants
2024-04-25 10:00:36 -07:00
Scott Beddall
fd021f468c
Pin Newest Version of test-proxy in CI (#5568)
* pin version to proxy with common sanitizers added
* fixes for keyvault, storage, core, other misc packages to deal with new common proxy version
2024-04-24 15:57:50 -07:00
George Arama
9f30ba4a9a
one more set of patterns (#5535)
* one more set of patterns

* tr

* ads

* add signed Oid

* clangs
2024-04-15 13:25:10 -07:00
Larry Osterman
3f6543d2a9
Fixed test deadlock in processor test (#5513)
* Fixed test deadlock in processor test

* Updated changelog; Changed fatal to error in test logs

* Update sdk/core/azure-core-amqp/CHANGELOG.md

Co-authored-by: Anton Kolesnyk <41349689+antkmsft@users.noreply.github.com>

---------

Co-authored-by: Anton Kolesnyk <41349689+antkmsft@users.noreply.github.com>
2024-04-12 13:34:20 -07:00
George Arama
c7f2767d6a
headers sanitize (#5518)
* headers sanitize

* test-proxy client id

* Liveonly storage tests and a couple of disables

* typo

* cover

---------

Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-04-12 12:09:52 -07:00
WangWeiLin-MV
e148d89745
Update sdk vcpkg portfile with VERSION and HEAD_REF (#5516)
* Update vcpkg portfile.cmake of sdk to add parameter HEAD_REF

* Update vcpkg portfile.cmake of sdk to use variable VERSION

* Update eng\scripts\Initialize-VcpkgRelease.ps1 regex for quoted REF

* Re-trigger CI

* Revert unnecessary change

---------

Co-authored-by: Anton Kolesnyk <41349689+antkmsft@users.noreply.github.com>
Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-04-12 10:25:19 -07:00
Azure SDK Bot
a74ecaad3d
Increment package version after release of azure-core (#5511) 2024-04-10 15:55:55 -07:00
Anton Kolesnyk
145f6dbdb6
Fixed libcurl connection pool to use Connection response header values (#5473)
* Fixed libcurl connection pool to use `Connection` response header values

---------

Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-04-10 08:01:29 -07:00
Azure SDK Bot
7f2f593b30
Increment version for core releases (#5503)
* Increment package version after release of azure-core-amqp

* Increment package version after release of azure-core
2024-04-09 14:39:30 -07:00
Larry Osterman
68d88eb80a
Updated azure core dependency to the new 1.11.3 version (#5501) 2024-04-09 18:58:17 +00:00
Ahson Khan
0bdec1e3c9
Core April GA Release (#5491)
* Azure Core 1.12.0 April Release

* Update Core's CHANGELOG.md

* Update Core's package_version.hpp

* Update AMQPCHANGELOG.md

* Update ci.tests.yml

* Re-enable coverage checks

---------

Co-authored-by: Anton Kolesnyk <41349689+antkmsft@users.noreply.github.com>
Co-authored-by: Daniel Jurek <djurek@microsoft.com>
2024-04-09 10:45:25 -07:00
Ahson Khan
da1513977a
Rename the TESTING_BUILD macro to be _azure_TESTING_BUILD to highlight this is internal only and reduce chances of collision. (#5419)
* Remove the use of ifdef for TESTING_BUILD in KeyVault clients, where they are not needed.

* Rename the TESTING_BUILD macro to be _azure_TESTING_BUILD to highlight this is internal only and reduce chances of collision.

* Update remaining macro names and add comments.

* Revert rename change which was using BUILD_TESTING cmake flag in source.
2024-04-05 12:05:04 -07:00
Ahson Khan
ce6b3bd124
Strengthen the client_secret sanitizer regex (#5474)
* Strengthen the client_secret sanitizer regex

* clang-format update
2024-04-04 15:04:15 -07:00
Anton Kolesnyk
d62b0d6669
Revert "Move the connection back to the connection pool when HTTP error 404 was received (#5308)" (#5472)
* Revert "Move the connection back to the connection pool when HTTP error 404 was received (#5308)"

This reverts commit 79cc06d004.

* Changelog

---------

Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-04-02 17:08:34 -07:00
George Arama
84e4a81947
Api view comments (#5408)
* mroe quotes

* dssf

* listTables -> queryTables

* move create/delete to the tableservice

* one more batch

* small refactor, added default data types

* oops

* clangs

* table sas builder

* sas test

* cspell

* add more test

* cspell

* hjhjh

* clang

* rename table-> tables

* clang

* partition and row key

* clang why?

* constructors, update tests

* IT WORKSSSSS

* PR comments

* wqe

* ewr

* enum operator

* clang

* dsaada

* sada

* assets.json

* clang

* Update sdk/tables/azure-data-tables/inc/azure/data/tables/enum_operators.hpp

Co-authored-by: Anton Kolesnyk <41349689+antkmsft@users.noreply.github.com>

* Update sdk/core/azure-core/test/ut/string_test.cpp

Co-authored-by: Anton Kolesnyk <41349689+antkmsft@users.noreply.github.com>

* the = enums

* assert and remove empty

* compact string tests

* clangs

* complement

* azureSasCredentials

* PR cpmments

* some extra

* clang 11

---------

Co-authored-by: Anton Kolesnyk <41349689+antkmsft@users.noreply.github.com>
2024-03-15 14:30:45 -07:00
Larry Osterman
d7bd238560
Added blocking Open for message sender (#5374)
* Added blocking Open for message sender

* Blocking message sender open; added AZURE_NODISCARD to help ensure APIs that are likely to fail have their returns checked

* Update eventhubs stress test to use DefaultAzureCredential instead of ClientSecretCredential; Fixed stress test to correctly request client parameters; Removed hard coded resource name from producer client test

* Pull request feedback with link events; renamed AZURE_NODISCARD to _azure_NODISCARD

---------

Co-authored-by: Rick Winter <rick.winter@microsoft.com>
2024-03-13 12:44:41 -07:00
Scott Beddall
3658df22db
1ES Template Refactor (#5441)
* All eng/ folder changes necessary to enable 1es-templates for the azure-sdk-for-cpp
* Includes updates to all ci.yml files to reflect new syntax requirements from 1es-template changes to archetype-sdk-client
2024-03-12 15:20:45 -07:00
Anton Kolesnyk
aad2299dcd
Revert commits related to _azure_BUILD_FOR_TESTING and _azure_*_FOR_TESTS (#5416)
* Revert "Remove the use of ifdef for TESTING_BUILD in KeyVault clients, where (#5406)"

This reverts commit 2d8c940f55.

* Revert "Rename the TESTING_BUILD macro to be _azure_TESTING_BUILD to highlight (#5390)"

This reverts commit 256c2df8b5.

* Revert "Use new macros in existing surface area, so that classes marked as final don't have virtual methods. (#5389)"

This reverts commit 3d7eaddb9d.

* Revert "For new surface area, classes marked as final should not have virtual methods. (#5331)"

This reverts commit ddd0f4bd07.

---------

Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-03-07 04:03:35 +00:00
Anton Kolesnyk
e4002aeff7
Fix warnings that block the Live CI pipeline (#5398)
* Fix warnings that block the Live CI pipeline

---------

Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-03-05 08:17:56 +00:00
Ahson Khan
256c2df8b5
Rename the TESTING_BUILD macro to be _azure_TESTING_BUILD to highlight (#5390)
this is internal only and reduce chances of collision.
2024-03-01 05:45:36 +00:00
Ahson Khan
3d7eaddb9d
Use new macros in existing surface area, so that classes marked as final don't have virtual methods. (#5389)
* Use new macros in existing surface area, so that classes marked as final don't have virtual methods.

* Update doc comments.

* Use DOXYGEN_PREDEFINED to expand only the macros we want expanded.

* Add the compile definition for more projects.

* Address PR feedback.

* Make TestableTokenCache a friend class of TokenCache.
2024-02-29 20:48:12 -08:00
Morten Ofstad
93d8c12e4c
Fix use of namespace qualifiers that have not been explicitly introduced (#5371)
* Fix use of namespace qualifiers that have not been explicitly introduced.

* Format (sort usings alphabetically)

* Update CHANGELOG.md

* Update cspell.json

---------

Co-authored-by: Morten Ofstad <morten.ofstad@bluware.com>
Co-authored-by: Anton Kolesnyk <41349689+antkmsft@users.noreply.github.com>
2024-02-29 02:51:42 +00:00
Larry Osterman
c707769604
Updated tests to support -UserAuth test resources switch to enable non-corpnet access. (#5387)
* Updated tests to support -UserAuth test resources switch to enable non-corpnet access.

* Try setting sample environment variables in sample script pipeline
2024-02-28 01:36:54 +00:00
Anton Kolesnyk
00b30e3d86
AMQP: do not use scope.MinimumExpiration when getting SAS Token (#5376)
* AMQP: do not use scope.MinimumExpiration when getting SAS Token

* Remove unused parameters

* Match style

---------

Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com>
2024-02-23 15:11:40 -08:00
Larry Osterman
aadd25dcd1
Reworked EventHubs Stress test to export information to OpenTelemetry (#5370)
# Significant rewrite of Eventhubs stress test.

## Cleaned up implementation of EventHubs stress/reliability test

* Reworked stress test layout to isolate stress test implementation from stress deployment elements.
* Added ability of stress test scenarios to be independently configured.
* Rewrote stress test app to be closer to the Go equivalent app.
* added apparg.hpp for command line parsing
* added scope_guard to test for scope_guard implementation.

## Added close methods to Consumer client and Producer client.

They don't do much currently, but will eventually.

## AI Generated summary of pull request

This pull request primarily focuses on the `azure-core-amqp` and `azure-messaging-eventhubs` packages, introducing changes to improve code efficiency and maintainability. The most significant changes include the removal of unnecessary `#include` directives in various files in the `azure-core-amqp` package, the addition of `Close` methods in `consumer_client.hpp` and `producer_client.hpp` in the `azure-messaging-eventhubs` package, and modifications to the `cgmanifest.json` files in the `azure-messaging-eventhubs-checkpointstore-blob` and `azure-messaging-eventhubs` directories.

Removal of unnecessary `#include` directives:

* [`sdk/core/azure-core-amqp/src/amqp/claim_based_security.cpp`](diffhunk://#diff-5acd7049cef5955540cc4253f264207e5a7d2701612e148c736ca5781e69d224L12-L14): Removed unnecessary `#include` directives for `iostream` and `sstream`.
* [`sdk/core/azure-core-amqp/src/amqp/connection.cpp`](diffhunk://#diff-fc3a6e5b11f1254c4fd344bcd1846c83ad4ca8e2a8a23b7db0657c2846f43937L18): Removed unnecessary `#include` directive for `azure/core/url.hpp`.
* [`sdk/core/azure-core-amqp/src/amqp/connection_string_credential.cpp`](diffhunk://#diff-14cf130dc5f0b51f698cca57724b733591d48fad0e5beb4745fc1cd78cbdaa72L7-L20): Removed unnecessary `#include` directives for `azure/core/amqp/internal/models/amqp_protocol.hpp`, `azure_c_shared_utility/azure_base64.h`, `azure_c_shared_utility/buffer_.h`, and `iostream`.
* [`sdk/core/azure-core-amqp/src/amqp/link.cpp`](diffhunk://#diff-249643f29ca2c0b1226e9d22ce90be83c77105f55221a1092fb605a5c7ead356L10-L21): Removed unnecessary `#include` directives for `azure/core/amqp/internal/message_receiver.hpp`, `azure/core/amqp/internal/message_sender.hpp`, `azure/core/amqp/internal/models/messaging_values.hpp`, and `azure_uamqp_c/amqp_definitions_sequence_no.h`.
* [`sdk/core/azure-core-amqp/src/amqp/management.cpp`](diffhunk://#diff-b03544340ff264961e045648c2c274dde9fa7ceb33b07b0c41a708128e28d40fL6-L16): Removed unnecessary `#include` directives for `azure/core/amqp/internal/connection.hpp`, `azure/core/amqp/internal/session.hpp`, and `azure_uamqp_c/amqp_management.h`.

Addition of `Close` methods:

* [`sdk/eventhubs/azure-messaging-eventhubs/inc/azure/messaging/eventhubs/consumer_client.hpp`](diffhunk://#diff-fad00d7bec0f12ef5e7d36387e866ab5291c6f5f57568845dfabe3f23320c899R152-R159): Added a `Close` method to the `ConsumerClient` class.
* [`sdk/eventhubs/azure-messaging-eventhubs/inc/azure/messaging/eventhubs/producer_client.hpp`](diffhunk://#diff-cba1fbd1d786b763c27123a2284476e1cc8093753abe6e3a6af9ca78aae4d594R96-R113): Added a `Close` method to the `ProducerClient` class.

Modification of `cgmanifest.json` files:

* [`sdk/eventhubs/azure-messaging-eventhubs-checkpointstore-blob/cgmanifest.json`](diffhunk://#diff-465b096c14ed240a8f14180f16e0924e3df69bd1c95934dca435c0b3c97468a0R1-R37): Added a new `cgmanifest.json` file specifying development dependencies.
* [`sdk/eventhubs/azure-messaging-eventhubs/cgmanifest.json`](diffhunk://#diff-f3e86a1f7be148625ac80b2151504461f3faff4d0564db588c6df9d0d9eb0986R1-R48): Added a new `cgmanifest.json` file specifying development dependencies.
* 

---------

Co-authored-by: Rick Winter <rick.winter@microsoft.com>
2024-02-22 20:41:18 -08:00
George Arama
8ef815dc6a
Install test proxy and enable all tests (#5365)
* mroe quotes

* dssf

* compact the tests in the proper folder

* 2 more tests

* eqwq

* enabled all except http

* endline

* fhg

* oops

* new teests

* update

* update defaults

* hdg
2024-02-21 10:58:35 -08:00
Azure SDK Bot
c0c7f88e65
Increment package version after release of azure-core (#5366) 2024-02-16 17:13:53 -08:00
George Arama
2a9934a596
Core perf tests consolidation (#5363)
* mroe quotes

* dssf

* compact the tests in the proper folder

* 2 more tests

* eqwq

* enabled all except http

* endline
2024-02-16 15:15:36 -08:00