Skip to content

new feature: downloading, reading and deserializing json aws objects#8

Open
jlisok wants to merge 9 commits intochore/content-aws-writerfrom
feature/read-cloud-content
Open

new feature: downloading, reading and deserializing json aws objects#8
jlisok wants to merge 9 commits intochore/content-aws-writerfrom
feature/read-cloud-content

Conversation

@jlisok
Copy link
Copy Markdown
Owner

@jlisok jlisok commented Jun 29, 2020

No description provided.

Content input = cloudObjectContentGetter.getObjectContent(info);
logger.debug("Transfer Service - extracting content from cloud object - success.");
DeserializedContent deserializedContent = deserializer.deserialize(input, classToDeserialize);
logger.debug("Transfer Service - content deserialization - success.");
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

log x2

private final Logger logger = LogManager.getLogger(this.getClass());

@Override
public Content deserialize(JsonStorage jsonStorage, Type classTypeToDeserializeJson) throws ContentDeserializationException {
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Type -> Class< Content >

// given
ContentAndStatsStorage<ThreeElemContent> expectedStorage = mockContentAndStatsStorage(new ThreeElemContent(1590147349818750700L, -840762737, "ChristopherRobin"));
JsonStorage json = serializeContentAndStats(expectedStorage);
JsonDeserializer<ContentAndStatsStorage<ThreeElemContent>> deserializer = new JsonDeserializer<>();
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

also try creating a class XXX extends ContentAndStatsStorage

and see if it works with the XXX.class approach

new feature: object uploading on  AWS S3 cloud
@jlisok jlisok force-pushed the feature/read-cloud-content branch from 7c3b9b0 to e9aea44 Compare July 1, 2020 16:42

import java.util.Objects;

public class ThreeElemContentAndStatsStorage<ContentType> {
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove?


@Override
public JsonReadyForJsonWriter convertContent(ContentAndStatsStorage<Content> content) throws ContentConversion2ReadyToWriteException {
public Json convertContent(ContentAndStats<ContentType> content) throws ContentConversion2ReadyToWriteException {
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

JsonContent?

@jlisok jlisok force-pushed the feature/read-cloud-content branch from e9aea44 to 5c84ca5 Compare July 6, 2020 10:30
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