GithubHelp home page GithubHelp logo

meshmap's People

Contributors

jamsesso avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

meshmap's Issues

Add transient nodes

Transient nodes are nodes that can read from the cluster, but are not used for storage.

Most recent version does not compile

> Task :compileJava FAILED
C:\Users\Jiankai\IdeaProjects\meshmap\src\main\java\jamsesso\meshmap\MeshMapServer.java:49: error: cannot find symbol
          socket.connect(node.getAddress());
                             ^
  symbol:   method getAddress()
  location: variable node of type Node
C:\Users\Jiankai\IdeaProjects\meshmap\src\main\java\jamsesso\meshmap\MeshMapServer.java:70: error: constructor BroadcastResponse in class BroadcastResponse cannot be applied to given types;
          return new BroadcastResponse(node, message(node, message));
                 ^
  required: no arguments
  found:    Node,Message
  reason: actual and formal argument lists differ in length
C:\Users\Jiankai\IdeaProjects\meshmap\src\main\java\jamsesso\meshmap\MeshMapServer.java:77: error: constructor BroadcastResponse in class BroadcastResponse cannot be applied to given types;
          return new BroadcastResponse(node, Message.ERR);
                 ^
  required: no arguments
  found:    Node,Message
  reason: actual and formal argument lists differ in length
C:\Users\Jiankai\IdeaProjects\meshmap\src\main\java\jamsesso\meshmap\MeshMapServer.java:80: error: invalid method reference
      .collect(Collectors.toMap(BroadcastResponse::getNode, BroadcastResponse::getResponse));
                                ^
  cannot find symbol
    symbol:   method getNode()
    location: class BroadcastResponse
C:\Users\Jiankai\IdeaProjects\meshmap\src\main\java\jamsesso\meshmap\MeshMapServer.java:80: error: invalid method reference
      .collect(Collectors.toMap(BroadcastResponse::getNode, BroadcastResponse::getResponse));
                                                            ^
  cannot find symbol
    symbol:   method getResponse()
    location: class BroadcastResponse
C:\Users\Jiankai\IdeaProjects\meshmap\src\main\java\jamsesso\meshmap\MeshMapServer.java:86: error: cannot find symbol
      serverSocket = new ServerSocket(self.getAddress().getPort());
                                          ^
  symbol:   method getAddress()
  location: variable self of type Node
C:\Users\Jiankai\IdeaProjects\meshmap\src\main\java\jamsesso\meshmap\MeshMapImpl.java:38: error: cannot find symbol
    switch (message.getType()) {
                   ^
  symbol:   method getType()
  location: variable message of type Message
C:\Users\Jiankai\IdeaProjects\meshmap\src\main\java\jamsesso\meshmap\MeshMapImpl.java:52: error: cannot find symbol
        delegate.put(entry.getKey(), entry.getValue());
                          ^
  symbol:   method getKey()
  location: variable entry of type Entry
C:\Users\Jiankai\IdeaProjects\meshmap\src\main\java\jamsesso\meshmap\MeshMapImpl.java:52: error: cannot find symbol
        delegate.put(entry.getKey(), entry.getValue());
                                          ^
  symbol:   method getValue()
  location: variable entry of type Entry
C:\Users\Jiankai\IdeaProjects\meshmap\src\main\java\jamsesso\meshmap\MeshMapImpl.java:87: error: constructor Entry in class Entry cannot be applied to given types;
          .map(entry -> new Entry(entry.getKey(), entry.getValue()))
                        ^
  required: no arguments
  found:    Object,Object
  reason: actual and formal argument lists differ in length
C:\Users\Jiankai\IdeaProjects\meshmap\src\main\java\jamsesso\meshmap\MeshMapImpl.java:106: error: cannot find symbol
      .filter(response -> TYPE_SIZE.equals(response.getType()))
                                                   ^
  symbol:   method getType()
  location: variable response of type Message
C:\Users\Jiankai\IdeaProjects\meshmap\src\main\java\jamsesso\meshmap\MeshMapImpl.java:202: error: cannot infer type arguments for TypedEntry<>
      entries.add(new TypedEntry<>((K) localEntry.getKey(), (V) localEntry.getValue()));
                  ^
  reason: cannot infer type-variable(s) K,V
    (actual and formal argument lists differ in length)
  where K,V are type-variables:
    K extends Object declared in class TypedEntry
    V extends Object declared in class TypedEntry
C:\Users\Jiankai\IdeaProjects\meshmap\src\main\java\jamsesso\meshmap\MeshMapImpl.java:209: error: cannot find symbol
        entries.add(new TypedEntry<>((K) remoteEntry.getKey(), (V) remoteEntry.getValue()));
                                                    ^
  symbol:   method getKey()
  location: variable remoteEntry of type Entry
C:\Users\Jiankai\IdeaProjects\meshmap\src\main\java\jamsesso\meshmap\MeshMapImpl.java:209: error: cannot find symbol
        entries.add(new TypedEntry<>((K) remoteEntry.getKey(), (V) remoteEntry.getValue()));
                                                                              ^
  symbol:   method getValue()
  location: variable remoteEntry of type Entry
C:\Users\Jiankai\IdeaProjects\meshmap\src\main\java\jamsesso\meshmap\MeshMapImpl.java:209: error: cannot infer type arguments for TypedEntry<>
        entries.add(new TypedEntry<>((K) remoteEntry.getKey(), (V) remoteEntry.getValue()));
                    ^
  reason: cannot infer type-variable(s) K,V
    (actual and formal argument lists differ in length)
  where K,V are type-variables:
    K extends Object declared in class TypedEntry
    V extends Object declared in class TypedEntry
C:\Users\Jiankai\IdeaProjects\meshmap\src\main\java\jamsesso\meshmap\MeshMapImpl.java:316: error: cannot find symbol
    if (!TYPE_GET.equals(response.getType())) {
                                 ^
  symbol:   method getType()
  location: variable response of type Message
C:\Users\Jiankai\IdeaProjects\meshmap\src\main\java\jamsesso\meshmap\MeshMapImpl.java:329: error: constructor Entry in class Entry cannot be applied to given types;
    Message putMsg = new Message(TYPE_PUT, new Entry(key, value));
                                           ^
  required: no arguments
  found:    Object,Object
  reason: actual and formal argument lists differ in length
C:\Users\Jiankai\IdeaProjects\meshmap\src\main\java\jamsesso\meshmap\MeshMapImpl.java:362: error: cannot find symbol
    if (!TYPE_REMOVE.equals(response.getType())) {
                                    ^
  symbol:   method getType()
  location: variable response of type Message
C:\Users\Jiankai\IdeaProjects\meshmap\src\main\java\jamsesso\meshmap\MeshMapImpl.java:393: error: TypedEntry is not abstract and does not override abstract method getValue() in Entry
  private static class TypedEntry<K, V> implements Map.Entry<K, V> {
                 ^
  where V is a type-variable:
    V extends Object declared in class TypedEntry
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
19 errors

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':compileJava'.
> Compilation failed; see the compiler error output for details.

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

* Get more help at https://help.gradle.org

Deprecated Gradle features were used in this build, making it incompatible with Gradle 7.0.
Use '--warning-mode all' to show the individual deprecation warnings.
See https://docs.gradle.org/6.7.1/userguide/command_line_interface.html#sec:command_line_warnings

BUILD FAILED in 2s
1 actionable task: 1 executed

Provide an API to deterministically calculate cluster ring position

Nodes are randomly placed on the cluster ring. It would be beneficial to add an API for users to place nodes on the ring in predetermined positions (in cases where server A has 2x memory of server B, the position of server A should be such that ~2/3 of the data is stored on server A)

Improve network performance of putAll

Currently a putAll naively calls put on each entry supplied. Instead, the method should group the entries by target node and put the entries in each group in batches.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.