Skip to content
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

4367 doc update for java marshaller deprecation #4441

Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 1 addition & 9 deletions docs/se/grpc/09_marshalling.adoc
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
///////////////////////////////////////////////////////////////////////////////

Copyright (c) 2019, 2021 Oracle and/or its affiliates.
Copyright (c) 2019, 2022 Oracle and/or its affiliates.

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -32,14 +32,6 @@ Protobuf marshaller will be used by default for any request and response classes

That means that you don't need any special handling or configuration in order to support Protobuf serialization of requests and responses.

=== Java Serialization Marshalling
klustria marked this conversation as resolved.
Show resolved Hide resolved

By default, any class that doesn't extend `com.google.protobuf.MessageLite` will be serialized using `JavaMarshaller`, which uses Java serialization.

`JavaMarshaller` is useful for quick prototypes, but it is not recommended for production use. For one, it only supports gRPC-based communication between Java clients and servers, which is quite limiting. It is also not very efficient, and last but not least, it introduces security vulnerabilities.

Because of the issues above, `JavaMarshaller` has been deprecated in Helidon 2.3, and will be permanently removed in Helidon 3.0. In the meantime, it is disabled by default and has to be explicitly enabled by setting `grpc.marshaller.java.enabled` configuration property to `true`. Otherwise, the `UnsupportedOperationException` will be thrown if you attempt to use it.

== Custom Marshalling

Helidon makes the use of custom marshallers trivial, and provides one custom implementation, `JsonbMarshaller`, out of the box.
Expand Down
3 changes: 1 addition & 2 deletions docs/sitegen.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# Copyright (c) 2018, 2021 Oracle and/or its affiliates.
# Copyright (c) 2018, 2022 Oracle and/or its affiliates.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -46,7 +46,6 @@ pages:
- includes:
- "**/*.adoc"
excludes:
- "se/grpc/09_marshalling.adoc"
- "common/**"
- "shared/**"
backend:
Expand Down