Micronaut Application Framework
| 文件 | 最后提交记录 | 最后更新时间 |
|---|---|---|
Update common files (#12848) | 10 天前 | |
use Jspecify annotations in APIs (#12200) | 9 个月前 | |
Upgrade GraalPy for Python modules (#12903) Updates the Core Python integration to the GraalPy 25.2.4 innovation release. - Bumps the managed GraalPy dependency from 25.1.3 to 25.2.4. - Updates the Python GitHub Actions job to provision GraalVM 25.2. | 10 天前 | |
Merge branch '5.1.x' into python-support | 2 个月前 | |
Optimize Python compilation processing | 1 个月前 | |
Fix quadratic response body assembly in NettyReadBufferFactory.compose (#12891) * Fix quadratic response body assembly in NettyReadBufferFactory.compose NettyReadBufferFactory.compose(Iterable<ReadBuffer>) added components to the CompositeByteBuf one at a time via addComponent(boolean, ByteBuf), which calls consolidateIfNeeded() after every component. Each consolidation copies everything accumulated so far, making aggregation of a body of size S in chunks of size c cost roughly S^2 / (2 * maxNumComponents * c) bytes of copying - about 19 GB for a 200 MB response at the default 16 components and 64 KB socket reads, all of it on the Netty event loop. Extract all ByteBufs first, then hand the complete list to CompositeByteBuf.addComponents(boolean, Iterable<ByteBuf>), which consolidates at most once, at the end. The extraction and handover are split into separate try blocks because ownership of each ByteBuf moves in stages: if extraction fails partway, the already-extracted buffers have no owner and must be released explicitly, whereas addComponents takes ownership of everything it is given (releasing what it did not add), so afterwards only the composite itself needs releasing. The returned buffer shape is unchanged: allocator.compositeBuffer() (no-arg) is kept, along with the size 0/1 shortcuts, so this remains safe for the server and proxy paths that write the composite back to a socket. Adds regression coverage for composing many small buffers, for consolidating only once, and for releasing all inputs when one buffer in the middle has already been consumed. --------- Co-authored-by: Joe Athman <joseph.athman@connectivehealth.io> Co-authored-by: Junie <junie@jetbrains.com> | 13 天前 | |
Merge remote-tracking branch 'core/5.2.x' into python-support | 1 个月前 | |
Merge branch '5.1.x' into python-support | 2 个月前 | |
fix(http-client): preserve PropagatedContext for client filters with micrometer context-propagation (#12858) When io.micrometer:context-propagation enables Reactor automatic context propagation, ThreadLocals may be cleared across Kotlin coroutine resumes even though PropagatedContext remains in the coroutine context. Re-apply the coroutine PropagatedContext during declarative HTTP client setup so client filters consistently see server-set context elements. Fixes #12851 --------- Co-authored-by: arimu1 <19286898+arimu1@users.noreply.github.com> | 25 天前 | |
fix checks | 1 个月前 | |
exclude transitive bc dep (#12904) | 10 天前 | |
Merge remote-tracking branch 'core/5.2.x' into python-support | 1 个月前 | |
Update jackson monorepo (#12833) * Update jackson monorepo * Adapt missing creator property test to Jackson 3.2 Co-Authored-By: multicode <multicode@yawk.at> --------- Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: yawkat <jonas.konrad@oracle.com> Co-authored-by: multicode <multicode@yawk.at> | 26 天前 | |
Merge branch '5.1.x' into 5.2.x | 11 天前 | |
Propagation context - scope values (#12509) | 5 个月前 | |
Allow disabling ImageSingletons lookups (#12894) * Allow disabling ImageSingletons lookups * Expose ImageSingletons availability utility * Use StringUtils for ImageSingletons property | 12 天前 | |
Fix Python support checks | 2 个月前 | |
Integrate NullAway for whole project (#12368) | 6 个月前 | |
Add `@NullMarked` to all packages in more modules (#12342) | 7 个月前 | |
don’t cache failures until the context is running (#12397) * untrack buildSrc/gradle.properties * don’t cache failures until the context is running Fixed with the help of AI > Two changes in DefaultBeanDefinitionService.java BeanDefinitionProducer: > 1. getReferenceIfEnabled (line 659): Only permanently null out this.reference when context.isRunning(). Before startup, the reference is preserved so conditions can be re-evaluated later. > 2. getDefinitionIfEnabled (line 690): Only set this.definition = DEFINITION_DISABLED_SENTINEL when context.isRunning(). Same rationale. > Why this works: Before start(), the environment hasn't processed property sources into the resolver catalog, so property-based @Requires conditions fail incorrectly. By not caching these failures permanently, the conditions are re-evaluated after start() when properties are available. The performance impact is negligible — the checkEnabledBeans ForkJoinTask and normal bean lookups after startup will still permanently cache results as before. | 6 个月前 | |
Add `@NullMarked` to all packages in more modules (#12342) | 7 个月前 | |
Upgrade GraalPy for Python modules (#12903) Updates the Core Python integration to the GraalPy 25.2.4 innovation release. - Bumps the managed GraalPy dependency from 25.1.3 to 25.2.4. - Updates the Python GitHub Actions job to provision GraalVM 25.2. | 10 天前 | |
fix(http-client): preserve PropagatedContext for client filters with micrometer context-propagation (#12858) When io.micrometer:context-propagation enables Reactor automatic context propagation, ThreadLocals may be cleared across Kotlin coroutine resumes even though PropagatedContext remains in the coroutine context. Re-apply the coroutine PropagatedContext during declarative HTTP client setup so client filters consistently see server-set context elements. Fixes #12851 --------- Co-authored-by: arimu1 <19286898+arimu1@users.noreply.github.com> | 25 天前 | |
New bean definition API (#12429) • New builder-based bean definition pipeline replaces the previous visitor/writer flow, aligning compile-time processors and runtime AOP with a shared abstraction. Core Builder API - Declared a complete builder contract under inject/src/main/java/io/micronaut/context/bean/definition/builder/ (e.g. `BeanDefinitionBuilder`, `ConstructorDefinition`) giving processors/runtime a stable way to register constructors, injections, lifecycle hooks, and proxies. - Provided `BeanDefinitionInjectionPoint.`to model value and bean injection metadata so downstream writers no longer synthesize this info ad hoc. Compile-Time Processor Changes - Replaced direct writer usage with the new builder via `ElementBeanDefinitionBuilder` and `DefaultElementBeanDefinitionBuilderFactory`, letting annotation visitors assemble definitions through uniform helper methods. - Added `BeanInjectionUtils` for shared creation of constructor/field/method definitions, consolidating logic previously scattered across creators. - Updated major generators (`BeanDefinitionWriter`, `AbstractBeanDefinitionBuilder`, `DispatchWriter`) to implement the builder interface, trimming legacy APIs (`ProxyingBeanDefinitionVisitor` removed) and clarifying state handling. - Adjusted visitors (`IntrospectedTypeElementVisitor`, `DeclaredBeanElementCreator`, `ConfigurationReaderBeanElementCreator`) to consume the new factory, ensuring configuration beans and introspections emit through the same pathway. AOP Runtime Integration - Added intercepted bean definition implementations (`aop/src/main/java/io/micronaut/aop/beandefinition/InterceptedInstantiateBeanDefinition`, `ProxyInterceptedInstantiateBeanDefinition`) that wrap the new builder output for constructor, initialize, and dispose flows. - Refactored `AopProxyWriter`, `ProxyingBeanDefinitionWriter`, and `RuntimeProxyBeanDefinitionWriter` to build proxies from the shared builder contract, retaining interceptor metadata while reducing duplication. - Minor tweaks in chains/registries (`ConstructorInterceptorChain`, `DefaultInterceptorRegistry`) to accommodate the new bean-definition shapes. --------- Co-authored-by: Graeme Rocher <graeme.rocher@oracle.com> | 2 个月前 | |
New bean definition API (#12429) • New builder-based bean definition pipeline replaces the previous visitor/writer flow, aligning compile-time processors and runtime AOP with a shared abstraction. Core Builder API - Declared a complete builder contract under inject/src/main/java/io/micronaut/context/bean/definition/builder/ (e.g. `BeanDefinitionBuilder`, `ConstructorDefinition`) giving processors/runtime a stable way to register constructors, injections, lifecycle hooks, and proxies. - Provided `BeanDefinitionInjectionPoint.`to model value and bean injection metadata so downstream writers no longer synthesize this info ad hoc. Compile-Time Processor Changes - Replaced direct writer usage with the new builder via `ElementBeanDefinitionBuilder` and `DefaultElementBeanDefinitionBuilderFactory`, letting annotation visitors assemble definitions through uniform helper methods. - Added `BeanInjectionUtils` for shared creation of constructor/field/method definitions, consolidating logic previously scattered across creators. - Updated major generators (`BeanDefinitionWriter`, `AbstractBeanDefinitionBuilder`, `DispatchWriter`) to implement the builder interface, trimming legacy APIs (`ProxyingBeanDefinitionVisitor` removed) and clarifying state handling. - Adjusted visitors (`IntrospectedTypeElementVisitor`, `DeclaredBeanElementCreator`, `ConfigurationReaderBeanElementCreator`) to consume the new factory, ensuring configuration beans and introspections emit through the same pathway. AOP Runtime Integration - Added intercepted bean definition implementations (`aop/src/main/java/io/micronaut/aop/beandefinition/InterceptedInstantiateBeanDefinition`, `ProxyInterceptedInstantiateBeanDefinition`) that wrap the new builder output for constructor, initialize, and dispose flows. - Refactored `AopProxyWriter`, `ProxyingBeanDefinitionWriter`, and `RuntimeProxyBeanDefinitionWriter` to build proxies from the shared builder contract, retaining interceptor metadata while reducing duplication. - Minor tweaks in chains/registries (`ConstructorInterceptorChain`, `DefaultInterceptorRegistry`) to accommodate the new bean-definition shapes. --------- Co-authored-by: Graeme Rocher <graeme.rocher@oracle.com> | 2 个月前 | |
Add Netty activation controls (#12842) - Add global, server, and client Netty activation annotations and properties. - Gate Netty bean packages while preserving enabled-by-default behavior. - Document the switches and test global and component-specific combinations. --------- Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> | 1 个月前 | |
Integrate NullAway for whole project (#12368) | 6 个月前 | |
Add Netty activation controls (#12842) - Add global, server, and client Netty activation annotations and properties. - Gate Netty bean packages while preserving enabled-by-default behavior. - Document the switches and test global and component-specific combinations. --------- Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> | 1 个月前 | |
Merge branch '5.1.x' into 5.2.x | 11 天前 | |
Merge branch '5.1.x' into 5.2.x | 11 天前 | |
fix(cors): replace reference equality with value equality in isAny and isAnyMethod (#12627) * fix(cors): replace reference equality with value equality in isAny and isAnyMethod * "fix(cors): use Objects.equals in isAny and add tests" * fix(cors): remove wildcard imports * Update http-server-netty/src/test/groovy/io/micronaut/http/server/netty/cors/CorsFilterSpec.groovy Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * Update http-server/src/main/java/io/micronaut/http/server/cors/CorsFilter.java Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * fix(cors): use Objects.equals for isAnyMethod * fix(cors): add missing private network imports --------- Co-authored-by: Sergio del Amo <sergio.delamo@softamo.com> Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> | 1 个月前 | |
[core] Update common files for branch 5.0.x (#12643) | 3 个月前 | |
Merge branch '5.0.x' into 5.1.x | 2 个月前 | |
Merge branch '5.1.x' into 5.2.x | 1 个月前 | |
Upgrade to Groovy 5 (#12170) * Upgrade to Groovy 5.0.2. This commit is a major upgrade to Groovy 5. There are some noticeable changes around default methods handling, which makes the behavior closer to the Java behavior. Some tests had to be adjusted, and sometimes the visitor code itself. * It mentions to Apache Groovy 5 in breaking change * It sets to [Spock 2.4-M7-groovy-5.0](https://github.com/spockframework/spock/releases/tag/spock-2.4-M7) --------- Co-authored-by: Denis Stepanov <denis.s.stepanov@oracle.com> Co-authored-by: Sergio del Amo <sergio.delamo@softamo.com> | 8 个月前 | |
Merge remote-tracking branch 'core/5.2.x' into python-support | 1 个月前 | |
Use standardized project names (#11354) * Use standardized project names This will make it easier to use Micronaut Core as an included build. This also simplifies some dependency substitution rules which were a bit awkward. * Convert all build scripts to Kotlin DSL For consistency and better IDE support. | 1 年前 | |
Use standardized project names (#11354) * Use standardized project names This will make it easier to use Micronaut Core as an included build. This also simplifies some dependency substitution rules which were a bit awkward. * Convert all build scripts to Kotlin DSL For consistency and better IDE support. | 1 年前 | |
Fix bean introspection for OpenAPI generated $ref properties (#12823) * Fix bean introspection for OpenAPI generated $ref properties Fixes #12742. | 26 天前 | |
Merge branch '5.1.x' into 5.2.x | 11 天前 | |
Fix KSP2 crash writing aggregating outputs (#12805) Dependencies.ALL_FILES walks every KSFile under incremental KSP2 and can throw KaInvalidLifetimeOwnerAccessException once PSI is invalidated (e.g. empty .kt files, or symbols after finish()). Use empty sources with aggregating=true instead. Fixes #12677 * Add KSP2 empty source regression test --------- Co-authored-by: dstepanov <denis.s.stepanov@oracle.com> | 1 个月前 | |
fix(ksp): treat Kotlin internal types as public for exposed types (#12857) Kotlin `internal` is public on the JVM. Element.isPublic() previously only recognized Visibility.PUBLIC, so isAccessibleFromBeanDefinition dropped internal interfaces from $EXPOSED_TYPES when the bean lived in another package. Treat Visibility.INTERNAL as public and add a KSP regression test from the #12854 reproducer. Fixes #12854 Co-authored-by: arimu1 <19286898+arimu1@users.noreply.github.com> | 26 天前 | |
Update dependency jakarta.data:jakarta.data-api to v1.1.0-M3 (#12905) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> | 9 天前 | |
exclude transitive bc dep (#12904) | 10 天前 | |
Use standardized project names (#11354) * Use standardized project names This will make it easier to use Micronaut Core as an included build. This also simplifies some dependency substitution rules which were a bit awkward. * Convert all build scripts to Kotlin DSL For consistency and better IDE support. | 1 年前 | |
Merge branch '5.1.x' into 5.2.x | 11 天前 | |
Fix Python support checks | 2 个月前 | |
Guard Jackson constructType against incomplete generics (#12558) * Guard Jackson constructType against incomplete generics Add a regression test for GenericType<Map<String, String>> arguments. Co-Authored-By: multicode <multicode@yawk.at> * Fix regression test classpath usage Avoid depending on JAX-RS GenericType in jackson-databind tests and use Micronaut's DefaultArgument capture pattern instead. Co-Authored-By: multicode <multicode@yawk.at> * Increase constructType branch coverage Cover the new raw map, collection, and reference fallback branches so Sonar new-code coverage reflects the defensive fix. Co-Authored-By: multicode <multicode@yawk.at> --------- Co-authored-by: multicode <multicode@yawk.at> | 5 个月前 | |
Add SCIM JSON media type support (#12835) Introduce the application/scim+json media type and register it with Micronaut's JSON message handlers and codec. Extend media type coverage tests to verify the new type. https://datatracker.ietf.org/doc/html/rfc7644#section-8.1 | 1 个月前 | |
Handle health status for endpoint base paths (#12812) Fixes #12637 | 1 个月前 | |
Update icns icon | 8 年前 | |
Add `@NullMarked` to all packages in more modules (#12342) | 7 个月前 | |
Integrate NullAway for whole project (#12368) | 6 个月前 | |
Fix flaky HttpClientTraceLoggingSpec log assertion (#12442) Snapshot the ListAppender entries before scanning formatted messages to avoid ConcurrentModificationException in CI and keep related style fixes required by current branch checks. | 5 个月前 | |
Make @Retryable capture Exception by default (#12141) * Make @Retryable capture Exception by default * Update breaks.adoc | 4 个月前 | |
Add RFC 10008 support (QUERY Method) (#12780) Fixes #12772 This change adds support for RFC 10008, the HTTP QUERY Method. --------- Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> | 1 个月前 | |
Remove remaining NonNull on NullMarked packages (#12369) | 6 个月前 | |
Add config import support and importer SPI (#12571) ## Summary - add config import traversal with file, classpath, classpath*, env, and configtree protocols - introduce the PropertySourceImporter SPI and reusable ConnectionString parsing helpers - document custom importers and harden connection string paths against parent traversal references - Fixes https://github.com/micronaut-projects/micronaut-core/issues/10436 --------- Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com> Co-authored-by: graemerocher <66626+graemerocher@users.noreply.github.com> Co-authored-by: Denis Stepanov <denis.s.stepanov@oracle.com> | 4 个月前 | |
Merge branch '5.1.x' into 5.2.x | 11 天前 | |
Use standardized project names (#11354) * Use standardized project names This will make it easier to use Micronaut Core as an included build. This also simplifies some dependency substitution rules which were a bit awkward. * Convert all build scripts to Kotlin DSL For consistency and better IDE support. | 1 年前 | |
Update native-gradle-plugin version (#12378) Updated native-gradle-plugin version from 0.11.3 to 0.11.4. | 6 个月前 | |
Use standardized project names (#11354) * Use standardized project names This will make it easier to use Micronaut Core as an included build. This also simplifies some dependency substitution rules which were a bit awkward. * Convert all build scripts to Kotlin DSL For consistency and better IDE support. | 1 年前 | |
Merge branch '5.0.x' into 5.1.x | 2 个月前 | |
Use standardized project names (#11354) * Use standardized project names This will make it easier to use Micronaut Core as an included build. This also simplifies some dependency substitution rules which were a bit awkward. * Convert all build scripts to Kotlin DSL For consistency and better IDE support. | 1 年前 | |
Update managed-groovy version to 5.0.6 (#12669) * Update managed-groovy version to 5.0.6 * Attempt to make SslRefreshSpec not flaky https://ge.micronaut.io/scans/tests?search.startTimeMax=1778536799999&search.startTimeMin=1777845600000&search.timeZoneId=Europe%2FMadrid&tests.container=io.micronaut.http.client.jdk.SslRefreshSpec&tests.test=test%20ssl%20refresh > • I reproduced the failure. The cause is JDK HTTP client connection reuse: after the first request, java.net.http.HttpClient returns the TLS connection to its internal pool, and the second request can reuse the same TCP/TLS session. SSL refresh updates the server SSL context for new connections, but an existing SslHandler keeps the old enabled ciphers and certificate. That matches your failure: both ciphers and subjectDN stayed at the original values. > I left a minimal test fix in test-suite-http-client-jdk-ssl/src/test/groovy/io/micronaut/http/client/jdk/ SslRefreshSpec.groovy:102: the test controller now sends Connection: close, forcing the old TLS connection to close before the post-refresh request | 3 个月前 | |
Merge commit from fork | 2 个月前 | |
Change propagated context default to thread local (#12605) * Change propagated context default to thread local Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> | 4 个月前 | |
Use management refresh endpoint in CORS TCKs (#12880) * Use management refresh endpoint in CORS TCKs Update CORS TCK scenarios to exercise the management refresh endpoint, configure endpoint sensitivity consistently, and verify refresh events are triggered only for allowed requests. Add the Micronaut management module to the JDK and Netty HTTP server TCK test suites, and simplify test setup by removing the embedded refresh controllers. * use private visibility modifiers * make it final | 16 天前 | |
Use management refresh endpoint in CORS TCKs (#12880) * Use management refresh endpoint in CORS TCKs Update CORS TCK scenarios to exercise the management refresh endpoint, configure endpoint sensitivity consistently, and verify refresh events are triggered only for allowed requests. Add the Micronaut management module to the JDK and Netty HTTP server TCK test suites, and simplify test setup by removing the embedded refresh controllers. * use private visibility modifiers * make it final | 16 天前 | |
Update native-gradle-plugin version (#12378) Updated native-gradle-plugin version from 0.11.3 to 0.11.4. | 6 个月前 | |
Allow visiting imported classes + Mixin (#11845) | 1 年前 | |
Drop support for Kotlin 1.9 (#12164) * WIP * Remove Kotlin 1.x project Replace dependencies to Kotlin 1.x with dependencies to Kotlin 2.x. Projects are intentionally not renamed yet, so that it's easier to compare with previous version. * Correct tests, rename modules * Rename libs from Kotlin2/Ksp2 to Kotlin/Ksp * Make checkstyle happy * Fix compilation errors * More compilation fixes - Use the `kotlin-base` and `java-base` plugins - Fix Groovy tests which use static import of TaskExecutors.IO (conflicts with java.lang.IO) * Fix Kotlin dependencies and BOM compatibility --------- Co-authored-by: Denis Stepanov <denis.s.stepanov@oracle.com> | 9 个月前 | |
Propagation context - scope values (#12509) | 5 个月前 | |
Allow KSP visitors to traverse Kotlin inner classes (#12535) - allow KSP visitor traversal of public Kotlin inner classes - remove the static-only restriction that skipped Kotlin `inner` nested test classes - keep bean-definition recursion behavior unchanged --------- Co-authored-by: multicode <multicode@yawk.at> | 2 个月前 | |
Update jackson monorepo (#12833) * Update jackson monorepo * Adapt missing creator property test to Jackson 3.2 Co-Authored-By: multicode <multicode@yawk.at> --------- Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: yawkat <jonas.konrad@oracle.com> Co-authored-by: multicode <multicode@yawk.at> | 26 天前 | |
Merge branch '4.7.x' into 4.8.x | 1 年前 | |
Update native-gradle-plugin version (#12378) Updated native-gradle-plugin version from 0.11.3 to 0.11.4. | 6 个月前 | |
Fix processing HttpClientResponseException with custom Http Status codes (#11390) Fixed #11383 | 1 年前 | |
Update native-gradle-plugin version (#12378) Updated native-gradle-plugin version from 0.11.3 to 0.11.4. | 6 个月前 | |
Honor configuration loading strategy during bootstrap (#12788) | 1 个月前 | |
Update dependency jakarta.data:jakarta.data-api to v1.1.0-M3 (#12905) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> | 9 天前 | |
Fix processing replaced executable methods (#12827) | 1 个月前 | |
Use standardized project names (#11354) * Use standardized project names This will make it easier to use Micronaut Core as an included build. This also simplifies some dependency substitution rules which were a bit awkward. * Convert all build scripts to Kotlin DSL For consistency and better IDE support. | 1 年前 | |
Integrate NullAway for whole project (#12368) | 6 个月前 | |
Update common files (#12178) | 9 个月前 | |
Update common files (#9977) | 2 年前 | |
Move from `javax.el` to `jakarta.el`. (#8966) | 3 年前 | |
Update common files (#12848) | 10 天前 | |
Update common files (#12660) | 3 个月前 | |
Merge pull request #12844 from micronaut-projects/jdk-25 Update JDK setup requirements | 1 个月前 | |
Text proofreading (#10038) Co-authored-by: Sergio del Amo <sergio.delamo@softamo.com> | 2 年前 | |
doc: Grammar fixes in docs (#9647) | 3 年前 | |
[core] Update common files for branch master (#3564) Co-authored-by: Alvaro Sanchez-Mariscal <alvaro.sanchezmariscal@gmail.com> Co-authored-by: Álvaro Sánchez-Mariscal <alvarosanchez@users.noreply.github.com> | 6 年前 | |
Update common files (#12676) | 3 个月前 | |
Nested each property and configuration properties (#12691) * Update example applications link in README * each prop with nested config prop in interface FIx with the help of GPT-5 > @Nullable nested config interface lookup was losing the active ConfigurationPath, so getDrcpConfiguration() returned null. Fixed in context/src/main/java/io/micronaut/runtime/context/env/ConfigurationIntroductionAdvice.java:139 by resolving nullable bean returns through a DefaultBeanResolutionContext with the captured configuration path, matching the non-null branch. * Potential fix for pull request finding Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> | 3 个月前 | |
Fixes in adoc format (#10037) | 2 年前 | |
Merge 4.2.x into 4.3.x (#10329) * fix(deps): update dependency ch.qos.logback:logback-classic to v1.4.14 (#10191) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * Update test (#10187) * KSP: Resolved type arguments shouldn't be marked as a type variable (#10193) * Optimize overrides-method check (#10195) * Fix error with duplicate builder methods (#10226) * fix(deps): update dependency io.netty.incubator:netty-incubator-codec-http3 to v0.0.23.final (#10222) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * Update ROADMAP.adoc (#10213) * Update ROADMAP.adoc Close #10205 * Update ROADMAP.adoc * fix(deps): update dependency com.github.javaparser:javaparser-symbol-solver-core to v3.25.7 (#10207) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * imp: don't send Content-length header for GET requests (#10218) * Allow context-path to be an empty String (#10231) * Allow context-path to be an empty String * Update ConfigurableUriNamingStrategySpec * Fix concurrent retrieval of expression resolvers (#10176) (#10229) * Change to public so that java doc is generated for Configuration Reference link in manual. (#10233) closes #10202 * KSP: Fix enum class values (#10240) * docs: add reactor context propagation example (#10220) * docs: add reactor context propagation example closes #10219 * fix test failures * add clarification about modified propagation context * improve example * fix code smell * refactor to fix code smell * change example to use custom context element * refine example * include example imports * KSP: Exclude static properties (#10245) * test: remove javax.persistence.Transient from Mapper (#10113) @Transient exclusion was removed in @transient since https://github.com/micronaut-projects/micronaut-core/pull/8072/files * Update breaking changes for Micronaut 4 (#10248) * Update breaks.adoc update to include breaking library changes * Update breaks.adoc * fix(deps): update dependency io.micronaut.aws:micronaut-aws-bom to v4.1.2 (#10249) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * KSP: Workaround for inner anonymous classes (#10247) * fix(deps): update dependency io.micronaut.rxjava2:micronaut-rxjava2-bom to v2.2.0 (#10241) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * fix(deps): update dependency io.micronaut.reactor:micronaut-reactor-bom to v3.2.0 (#10234) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * Add links to guides for Micronaut Core (#10269) * Allow Refreshable scope under test for Env.FUNCTION and ANDROID (#10264) It was seen in the Aws module that `@MockLambdaTest` and `@MockBean` did not work as expected. https://github.com/micronaut-projects/micronaut-aws/issues/1870 This is because: 1. `@MockBean` uses the Refreshable scope 2. `@MockLambdaTest` adds Environment.FUNCTION to the test context 3. The Refresh scope is disabled for the FUNCTION environment After this PR, RefreshScope is still disabled for Environment.FUNCTION... ...*UNLESS* Environment.TEST is also enabled. * test. ThreadSelection accept event loop in the handler in blocking and auto scenarios (#10104) * change comment copy * test. ThreadSelection accept event loop in the handler in blocking and auto scenarios The test is really flaky: https://ge.micronaut.io/scans/tests?search.timeZoneId=Europe%2FMadrid&tests.container=io.micronaut.http.server.netty.threading.ThreadSelectionSpec * disable test --------- Co-authored-by: yawkat <jonas.konrad@oracle.com> * [bug] EL fails when using primitive method arguments in expression (#10149) * Reproducer * Add Kotlin reproducer as well * Unbox primitive --------- Co-authored-by: Denis Stepanov <denis.s.stepanov@oracle.com> * fix(deps): update netty monorepo to v4.1.103.final (#10270) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * fix(deps): update managed.ksp to v1.9.21-1.0.16 (#10268) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * [skip ci] Release v4.2.2 * Back to 4.2.3-SNAPSHOT * Fix logged errors reported by fuzzing (#10273) * Fix logged errors reported by fuzzing There are two bugs fixed here: (1) Empty URI handling in HateoasErrorResponseProcessor ``` 10:18:18.775 [main] ERROR i.m.h.s.netty.RoutingInBoundHandler - Micronaut Server Error - No request state present. Cause: URI cannot be empty java.lang.IllegalArgumentException: URI cannot be empty at io.micronaut.http.hateoas.DefaultLink.<init>(DefaultLink.java:49) at io.micronaut.http.hateoas.Link.of(Link.java:115) at io.micronaut.http.server.exceptions.response.HateoasErrorResponseProcessor.processResponse(HateoasErrorResponseProcessor.java:69) at io.micronaut.http.server.RouteExecutor.createDefaultErrorResponse(RouteExecutor.java:214) at io.micronaut.http.server.netty.RoutingInBoundHandler.writeResponse(RoutingInBoundHandler.java:229) at io.micronaut.http.server.netty.NettyRequestLifecycle.lambda$handleException$2(NettyRequestLifecycle.java:147) at io.micronaut.core.execution.ImperativeExecutionFlowImpl.onComplete(ImperativeExecutionFlowImpl.java:132) at io.micronaut.http.server.netty.NettyRequestLifecycle.handleException(NettyRequestLifecycle.java:147) at io.micronaut.http.server.netty.NettyRequestLifecycle.handleNormal(NettyRequestLifecycle.java:89) at io.micronaut.http.server.netty.RoutingInBoundHandler.accept(RoutingInBoundHandler.java:220) [...] ``` Test input added to FuzzyInputSpec. FuzzyInputSpec has been adjusted to recognize logged errors. (2) Bad sorting in MediaType.orderedOf ``` 11:48:58.716 [41560@yawkat-oracle main] ERROR i.m.http.server.RouteExecutor - Unexpected error occurred: Comparison method violates its general contract! java.lang.IllegalArgumentException: Comparison method violates its general contract! at java.base/java.util.TimSort.mergeLo(TimSort.java:781) at java.base/java.util.TimSort.mergeAt(TimSort.java:518) at java.base/java.util.TimSort.mergeForceCollapse(TimSort.java:461) at java.base/java.util.TimSort.sort(TimSort.java:254) at java.base/java.util.Arrays.sort(Arrays.java:1307) at java.base/java.util.ArrayList.sort(ArrayList.java:1721) at io.micronaut.http.MediaType.orderedOf(MediaType.java:870) at io.micronaut.http.netty.NettyHttpHeaders.accept(NettyHttpHeaders.java:301) ``` Created a new MediaTypeFuzzTest that hits this issue. The sample input (crash-22df7f6e72bba86bdb1fdbd4bf92372fd4fa6bbe) reproduces the issue and will be run as part of the normal micronaut-http test suite now. Setting the env variable JAZZER_FUZZ=1 will enable exploratory fuzzing. (3) Added workaround for https://github.com/netty/netty/pull/13730 This does not appear to be an issue in the real world, only with EmbeddedChannel. I've added a workaround for the issue so that it doesn't trigger my fuzz tests anymore. --- None of these bugs appear security-relevant, (3) is not applicable outside a test env, (1) and (2) only produce additional error logs. * annotation * KSP: Fix `@Generated` processing (#10282) * Initialize classes at build time that can deadlock graal compiler (#10283) A class loading deadlock can occur when ConversionContext is initialised concurrently since it has static final fields that are sub interfaces which are also initialised causing a loop. This doesn't manifest on JIT likely because these classes are never initialised concurrently, but a deadlock can occur in the Graal compiler. A real fix would to be alter the code but unfortunately there is no way to do this in a backwards compatible way. A workaround in Graal is to explicitly initialise these classes at build time which happens very early, avoiding the concurrent access that causes the deadlock. * KSP: Do not store default empty string annotation value (#10284) * fix(deps): update netty monorepo to v4.1.104.final (#10276) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * chore(deps): update gradle/gradle-build-action action to v2.11.0 (#10252) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * Ensure responseWritten is called on discard (#10288) FullOutboundHandler needs to call responseWritten on discard, otherwise RoutingInboundHandler won't clean up request body. This can happen if the channel is closed while it's not writable, so there's a response backlog. * Javac: Extract type variable name using the element (#10293) * Publish service ready / stopped in consistent order (#10325) * Publish service ready / stopped in consistent order * Update test-suite/src/test/groovy/io/micronaut/EventListenerSpec.groovy Co-authored-by: Sergio del Amo <sergio.delamo@softamo.com> * Update test-suite/src/test/groovy/io/micronaut/EventListenerSpec.groovy Co-authored-by: Sergio del Amo <sergio.delamo@softamo.com> --------- Co-authored-by: Sergio del Amo <sergio.delamo@softamo.com> * [skip ci] Release v4.2.3 * Back to 4.2.4-SNAPSHOT * test: StreamPressureSpec ignore on macOs --------- Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: Denis Stepanov <denis.s.stepanov@oracle.com> Co-authored-by: Tim Yates <tim.yates@gmail.com> Co-authored-by: Jeremy Grelle <grellej@unityfoundation.io> Co-authored-by: rorueda <rorueda@gmail.com> Co-authored-by: Dean Wette <wetted@objectcomputing.com> Co-authored-by: hrothwell <46227616+hrothwell@users.noreply.github.com> Co-authored-by: yawkat <jonas.konrad@oracle.com> Co-authored-by: micronaut-build <micronaut-build-account@grails.org> Co-authored-by: Graeme Rocher <graeme.rocher@oracle.com> | 2 年前 | |
Update common files (#10074) | 2 年前 | |
Add shared GraalPy context execution APIs (#12849) | 27 天前 | |
remove deprecated netflix module links from docs | 1 个月前 | |
Update common files (#12737) | 2 个月前 | |
Update common files (#12737) | 2 个月前 | |
Merge remote-tracking branch 'core/5.2.x' into python-support | 1 个月前 | |
[core] Update common files for branch master (#3564) Co-authored-by: Alvaro Sanchez-Mariscal <alvaro.sanchezmariscal@gmail.com> Co-authored-by: Álvaro Sánchez-Mariscal <alvarosanchez@users.noreply.github.com> | 6 年前 |
Micronaut Framework
Micronaut Framework 是一个现代化的、基于 JVM 的全栈 Java 框架,旨在构建模块化、易于测试的 JVM 应用程序,并支持 Java、Kotlin 和 Groovy 语言。
Micronaut 框架最初由曾参与 Grails 框架开发的团队创建。该框架从多年来使用 Spring、Spring Boot 和 Grails 框架构建从单体应用到微服务的实际项目经验中汲取灵感。核心团队在 Micronaut Foundation 的支持下继续开发和维护 Micronaut 项目。
Micronaut Framework 致力于提供构建 JVM 应用程序所需的全部工具,包括:
- 依赖注入和控制反转 (IoC)
- 面向切面编程 (AOP)
- 合理的默认值和自动配置
借助 Micronaut Framework,您可以构建消息驱动应用程序、命令行应用程序、HTTP 服务器等。尤其对于微服务,Micronaut Framework 还提供:
- 分布式配置
- 服务发现
- HTTP 路由
- 客户端负载均衡
同时,Micronaut Framework 旨在通过以下特性避免 Spring、Spring Boot 和 Grails 等框架的缺点:
- 快速启动时间
- 减少内存占用
- 最小化反射使用
- 最小化代理使用
- 无运行时字节码生成
- 易于单元测试
这些优势通过在编译时预先计算框架基础结构来实现,从而减少了应用程序运行时所需的逻辑。
有关使用 Micronaut Framework 的更多信息,请参阅 micronaut.io 上的文档。
示例应用程序
Micronaut 示例应用程序可在 guides.micronaut.io 中找到
从源代码构建
要从源代码构建,请检出代码并运行:
./gradlew publishToMavenLocal
要构建文档,请运行 ./gradlew docs。文档将构建到 build/docs/index.html。
代码贡献
如果您希望为 Micronaut Framework 的开发做出贡献,请阅读 CONTRIBUTING.md。
版本控制
Micronaut Framework 采用语义化版本 2.0.0。要了解其具体含义,请参阅规范 文档。Micronaut Framework 公共 API 的排除项包括任何标注有 @Experimental 或 @Internal 的类,这些类位于 io.micronaut.core.annotation 包中。