I want to delete metadata of host-aggregates , but parameter lost after map serialization。
This is my code.
IClient client = clientService.getClient(controllerId);
Map<String, String> metadata = new HashMap<>();
metadata.put("pinned", null);
client.compute().hostAggregates().setMetadata(id, metadata);
This request must run this code.
String content = ObjectMapperSingleton.getContext(this.request.getEntity().getClass()).writer().writeValueAsString(this.request.getEntity());
There are the following parameters in class of org.openstack4j.core.transport.ObjectMapperSingleton:
mapper.setSerializationInclusion(Include.NON_NULL);
HOW CAN I CHANGE THIS CONFIG TO
mapper.setSerializationInclusion(Include.ALWAYS);
THANK YOU !!