-
Notifications
You must be signed in to change notification settings - Fork 6.3k
Feeling Brave? #1750
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: dev
Are you sure you want to change the base?
Feeling Brave? #1750
Conversation
b7ad029 to
539f061
Compare
|
I have had some new thoughts on this one, I will tweak and see how it goes |
57e4cbe to
d7a2fe6
Compare
a063149 to
a4c72af
Compare
|
Re-worked this a bunch as to not play with the current file structure while also ensuring that the tests folder is excluded from the built module but instead just copied to the same location for existing functions to continue working |
|
Just need to go over the description section for listing the api endpoints for RBAC stuff and then it’ll be good to go. |
This pull request introduces significant improvements to the build pipeline and optimizes how function metadata and permissions are loaded and used within the PowerShell modules. The main focus is on leveraging a pre-built metadata cache for function permissions and descriptions, which enhances performance and maintainability. Additionally, the CI workflow is updated to automate the build and caching of this metadata, and detailed timing/debug information is added for access checks.
The most important changes are:
CI/CD Pipeline Enhancements:
.github/workflows/dev_api.ymlworkflow now builds and caches PowerShell modules, generates permission and function metadata caches, and replaces source modules with their built versions as part of the CI process. This ensures that up-to-date metadata is always available and modules are consistently built.Performance and Metadata Loading Improvements:
Test-CIPPAccess.ps1andGet-CIPPHttpFunctions.ps1are updated to load function permissions and metadata from the newConfig/function-metadata.jsoncache instead of querying each function individually. This reduces runtime overhead and improves reliability. [1] [2]Debugging and Timing Instrumentation:
Test-CIPPAccess.ps1, making it easier to diagnose performance bottlenecks and understand the flow of permission checks. [1] [2] [3]Fallbacks and Robustness:
Get-Helpto retrieve function information, ensuring continued reliability. [1] [2]