Skip to content

Conversation

@MaggieNgWu
Copy link
Contributor

Interfaces include

  • Channel
  • MsgHandler
  • Network

@MaggieNgWu MaggieNgWu requested review from cyjseagull and wheatli July 10, 2020 12:49
@ghost
Copy link

ghost commented Jul 10, 2020

Warnings are found on analyzing the commit c4640bd.

5 warnings:

We recommend to address them as possible, for example, update outdated dependencies, fix the tool's configuration, configure sider.yml, turn off unused tools, and so on.

If you are struggling with these errors or warnings, feel free to ask us via chat. 💬


import org.fisco.bcos.sdk.model.Message;
import org.fisco.bcos.sdk.model.MsgType;
import java.util.Collection;
Copy link

Choose a reason for hiding this comment

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

[PMD Java] Avoid unused imports such as 'java.util.Collection' (view)

Rule Ruleset Priority
UnusedImports Best Practices 4

References:

You can close this issue if no need to fix it. Learn more.

import org.fisco.bcos.sdk.model.MsgType;
import java.util.Collection;
import java.util.List;
import java.util.Map;
Copy link

Choose a reason for hiding this comment

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

[PMD Java] Avoid unused imports such as 'java.util.Map' (view)

Rule Ruleset Priority
UnusedImports Best Practices 4

References:

You can close this issue if no need to fix it. Learn more.

* ResponseCallback is to define a callback to handle response from node
*/
public abstract class ResponseCallback {
private Message message;
Copy link

Choose a reason for hiding this comment

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

[PMD Java] Avoid unused private fields such as 'message'. (view)

Rule Ruleset Priority
UnusedPrivateField Best Practices 3

References:

You can close this issue if no need to fix it. Learn more.

* Messages between sdk and FISCO BCOS node.
*
*/
public class Message implements Serializable{
Copy link

Choose a reason for hiding this comment

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

[PMD Java] Classes implementing Serializable should set a serialVersionUID (view)

Rule Ruleset Priority
MissingSerialVersionUID Error Prone 3

References:

You can close this issue if no need to fix it. Learn more.


import org.fisco.bcos.sdk.model.Message;
import org.fisco.bcos.sdk.model.MsgType;
import java.util.Collection;
Copy link

Choose a reason for hiding this comment

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

[Checkstyle] Wrong lexicographical order for 'java.util.Collection' import. Should be before 'org.fisco.bcos.sdk.model.MsgType'. (view)

Rule Severity
CustomImportOrderCheck warning

References:

You can close this issue if no need to fix it. Learn more.

* @param groupId
* @param callback
*/
void sendToGroup(Message out, String groupId, ResponseCallback callback);
Copy link

Choose a reason for hiding this comment

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

[Checkstyle] 'method def modifier' has incorrect indentation level 4, expected level should be 2. (view)

Rule Severity
IndentationCheck warning

References:

You can close this issue if no need to fix it. Learn more.

*/
void sendToGroup(Message out, String groupId, ResponseCallback callback);

/**
Copy link

Choose a reason for hiding this comment

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

[Checkstyle] First sentence of Javadoc is missing an ending period. (view)

Rule Severity
SummaryJavadocCheck warning

References:

You can close this issue if no need to fix it. Learn more.

/**
* Broadcast to all peer
*
* @param out
Copy link

Choose a reason for hiding this comment

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

[Checkstyle] At-clause should have a non-empty description. (view)

Rule Severity
NonEmptyAtclauseDescriptionCheck warning

References:

You can close this issue if no need to fix it. Learn more.

* Broadcast to all peer
*
* @param out
* @param callback
Copy link

Choose a reason for hiding this comment

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

[Checkstyle] At-clause should have a non-empty description. (view)

Rule Severity
NonEmptyAtclauseDescriptionCheck warning

References:

You can close this issue if no need to fix it. Learn more.

* @param out
* @param callback
*/
void broadcast(Message out, ResponseCallback callback);
Copy link

Choose a reason for hiding this comment

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

[Checkstyle] 'method def modifier' has incorrect indentation level 4, expected level should be 2. (view)

Rule Severity
IndentationCheck warning

References:

You can close this issue if no need to fix it. Learn more.

@sonarqubecloud
Copy link

Kudos, SonarCloud Quality Gate passed!

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities (and Security Hotspot 0 Security Hotspots to review)
Code Smell A 0 Code Smells

No Coverage information No Coverage information
No Duplication information No Duplication information

import org.fisco.bcos.sdk.model.MsgType;

public interface Channel {
/**
Copy link

Choose a reason for hiding this comment

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

[Checkstyle] First sentence of Javadoc is missing an ending period. (view)

Rule Severity
SummaryJavadocCheck warning

References:

You can close this issue if no need to fix it. Learn more.

* @param filepath config file path.
* @return
*/
Channel build(String filepath);
Copy link

Choose a reason for hiding this comment

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

[Checkstyle] 'method def modifier' has incorrect indentation level 4, expected level should be 2. (view)

Rule Severity
IndentationCheck warning

References:

You can close this issue if no need to fix it. Learn more.

* Add a message handler to handle specific type messages. When one message comes the handler
* will be notified, handler.onMessage(ChannleHandlerContext ctx, Message msg) called.
*
* @param type
Copy link

Choose a reason for hiding this comment

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

[Checkstyle] At-clause should have a non-empty description. (view)

Rule Severity
NonEmptyAtclauseDescriptionCheck warning

References:

You can close this issue if no need to fix it. Learn more.

* will be notified, handler.onMessage(ChannleHandlerContext ctx, Message msg) called.
*
* @param type
* @param handler
Copy link

Choose a reason for hiding this comment

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

[Checkstyle] At-clause should have a non-empty description. (view)

Rule Severity
NonEmptyAtclauseDescriptionCheck warning

References:

You can close this issue if no need to fix it. Learn more.

* @param type
* @param handler
*/
void addMessageHandler(MsgType type, MsgHandler handler);
Copy link

Choose a reason for hiding this comment

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

[Checkstyle] 'method def modifier' has incorrect indentation level 4, expected level should be 2. (view)

Rule Severity
IndentationCheck warning

References:

You can close this issue if no need to fix it. Learn more.

/**
* Send to an random peer
*
* @param out
Copy link

Choose a reason for hiding this comment

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

[Checkstyle] At-clause should have a non-empty description. (view)

Rule Severity
NonEmptyAtclauseDescriptionCheck warning

References:

You can close this issue if no need to fix it. Learn more.

* Send to an random peer
*
* @param out
* @param callback
Copy link

Choose a reason for hiding this comment

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

[Checkstyle] At-clause should have a non-empty description. (view)

Rule Severity
NonEmptyAtclauseDescriptionCheck warning

References:

You can close this issue if no need to fix it. Learn more.

* @param out
* @param callback
*/
void sendToRandom(Message out, ResponseCallback callback);
Copy link

Choose a reason for hiding this comment

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

[Checkstyle] 'method def modifier' has incorrect indentation level 4, expected level should be 2. (view)

Rule Severity
IndentationCheck warning

References:

You can close this issue if no need to fix it. Learn more.

*/
void sendToRandom(Message out, ResponseCallback callback);

/**
Copy link

Choose a reason for hiding this comment

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

[Checkstyle] First sentence of Javadoc is missing an ending period. (view)

Rule Severity
SummaryJavadocCheck warning

References:

You can close this issue if no need to fix it. Learn more.

*
* @return List of connection information
*/
List<ConnectionInfo> getConnectionInfo();
Copy link

Choose a reason for hiding this comment

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

[Checkstyle] 'method def modifier' has incorrect indentation level 4, expected level should be 2. (view)

Rule Severity
IndentationCheck warning

References:

You can close this issue if no need to fix it. Learn more.

@MaggieNgWu MaggieNgWu closed this Jul 13, 2020
kyonRay added a commit that referenced this pull request Nov 13, 2025
* <fix>(build): update dependencies version, add UT with AI.

* Add unit tests to increase JaCoCo coverage from 30.1% to 30.7% (#1)

* Initial plan

* Initial setup: Upgrade Gradle to 7.6.4 for Java 17 compatibility and fix duplicate resources handling

Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com>

* Add unit tests for model classes and exceptions to improve coverage

Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com>

* Add more unit tests for model and enum classes to increase coverage

Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com>

* Add unit tests for crypto exception classes to increase coverage

Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com>

* Downgrade Gradle version to 6.3

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com>

* Add unit tests for SDK v3 client and transaction packages (#2)

* Initial plan

* Add unit tests for client and transaction packages - part 1

Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com>

* Add more unit tests for client protocol response and transaction dto classes

Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com>

* Add unit tests for LogFilterRequest, model BO classes and CommonConstant

Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com>

* Fix ResultCodeEnumTest to avoid mutating enum state in tests

Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com>

* <fix>(test): fixed tests path.

* Add comprehensive test coverage for uncovered utility, protocol, and codec classes (#4)

* Initial plan

* Add comprehensive tests for ByteUtils, ThreadPoolService, SystemInformation, SecureRandomUtils, and LinuxSecureRandom

Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com>

* Add comprehensive tests for JsonRpcRequest and TopicTools

Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com>

* Address code review feedback - fix resource cleanup and remove redundant tests

Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com>

* <fix>(CI): fix windows ci version to 2025.

* <fix>(build): update publish url to central.sonatype.

---------

Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
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.

1 participant