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

Added /description endpoint and StandardizedLiteralEnum #94

Conversation

alexgordtop
Copy link
Contributor

I've added a generic /description endpoint, that is automatically added to the repository components.
In the http modules a *ServiceDescriptionConfiguration has to be implemented, that configures which Profiles are provided.

The Profiles use a modified Profile Enum from the registry projects, extended by an additional interface StandardizedLiteralEnum, which allows a simplified de-/serialization configuration for enums with custom serializations.

Known issues:

    SimpleModule module = new SimpleModule();
    module.addSerializer(StandardizedLiteralEnum.class, new StandardizedLiteralEnumSerializer<>());
    module.addDeserializer(Profile.class, new StandardizedLiteralEnumDeserializer<>(Profile.class));
    module.addSerializer(Enum.class, new EnumSerializer());
    ReflectionHelper.ENUMS.forEach(x -> module.addDeserializer(x, new EnumDeserializer<>(x)));

AAS4J introduced a reflection based serialization approach, which only works as the one and only solution. In combination which the other two serializers, it leads to infinite loops.

@FrankSchnicke FrankSchnicke merged commit 284548b into eclipse-basyx:main Oct 10, 2023
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants