Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
    sorenvalentinjp
    @sorenvalentinjp
    Can you reproduce the problem on your end?
    Delegue Alexandre
    @larousso
    I am not sure
    I will try to work on this tomorrow
    sorenvalentinjp
    @sorenvalentinjp
    Thank you
    sorenvalentinjp
    @sorenvalentinjp

    I verified that the problem is also reproducable when using the play example project you made.
    https://github.com/MAIF/izanami/tree/master/example/example-play

    Works with 1.0.6, but cant connect on any versions above that.

    Delegue Alexandre
    @larousso
    @sorenvalentinjp I’ve released a 1.4.1 version. Can you test if it works for you ?
    sorenvalentinjp
    @sorenvalentinjp
    Yes i will do that right away
    sorenvalentinjp
    @sorenvalentinjp

    I get an exception Runtime:

    Exception in thread "main" java.lang.NoClassDefFoundError: scala/collection/compat/Factory$ at izanami.scaladsl.Features$.parseJson(scaladsl.scala:447)

    On boot
    Delegue Alexandre
    @larousso
    You use play 2.7 ?
    sorenvalentinjp
    @sorenvalentinjp
    Caused by: java.lang.ClassNotFoundException: scala.collection.compat.Factory$
    at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
    at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:335)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
    Yes I use play 2.7
    Let me try again.
    Delegue Alexandre
    @larousso
    ok
    I ve have this error on izanami server when i update to 2.7 and I don’t know why at the moment
    Delegue Alexandre
    @larousso
    Do you use reactive mongo ?
    On the server side, it works with "org.reactivemongo" %% "play2-reactivemongo" % "0.16.3-play26 » instead of "org.reactivemongo" %% "play2-reactivemongo" % "0.16.3-play27 »
    Dragan Raicici
    @DraganRaicici
    No,we do not.
    Delegue Alexandre
    @larousso
    I don’t really understand the pb but it seems play-json 2.7 evict the library collection-compat lib
    Could you try to add this to your dependencies : "org.scala-lang.modules" %% "scala-collection-compat" % « 0.1.1",
    Dragan Raicici
    @DraganRaicici
    yes, we can definitely try that :)
    sorenvalentinjp
    @sorenvalentinjp

    Still issues when we add the scala-collection-compat libarary

    Exception in thread "main" java.lang.NoSuchMethodError: play.api.libs.json.Reads$.traversableReads(Lscala/collection/compat/Factory;Lplay/api/libs/json/Reads;)Lplay/api/libs/json/Reads; at izanami.scaladsl.Features$.parseJson(scaladsl.scala:447)

    Delegue Alexandre
    @larousso
    Argggh
    sorenvalentinjp
    @sorenvalentinjp
    Is there any information I can give that will help?
    Delegue Alexandre
    @larousso
    May be some dependencies to be able to reproduce the problem
    sorenvalentinjp
    @sorenvalentinjp
    val akkaVersion = "2.5.19" // should match the version used by Play
    val akkaHTTPVersion = "10.1.7"
    
    libraryDependencies ++= Seq(
      ehcache,
      ws,
      guice,
      "org.scalatestplus.play"                  %% "scalatestplus-play"             % "4.0.1" % Test,
      "ch.qos.logback.contrib"                   % "logback-jackson"                % "0.1.4",
      "ch.qos.logback.contrib"                   % "logback-json-classic"           % "0.1.4",
      "org.mockito"                              % "mockito-core"                   % "2.12.0" % Test,
      "io.prometheus"                            % "simpleclient"                   % "0.6.0",
      "com.github.stijndehaes"                  %% "play-prometheus-filters"        % "0.5.0",
      "com.typesafe.play"                       %% "play-json-joda"                 % "2.7.1",
      "fr.maif"                                 %% "izanami-client"                 % "1.4.1",
      "com.github.pureconfig"                   %% "pureconfig"                     % "0.9.2",
      "com.amazonaws"                            % "aws-java-sdk-cloudsearch"       % "1.11.441",
      "com.typesafe.akka"                       %% "akka-http"                      % akkaHTTPVersion,
      "com.typesafe.akka"                       %% "akka-stream"                    % akkaVersion,
      "com.typesafe.akka"                       %% "akka-slf4j"                     % akkaVersion
    )
    resolvers += Resolver.jcenterRepo
    Delegue Alexandre
    @larousso
    ok thanks I will try that
    sorenvalentinjp
    @sorenvalentinjp
    Thanks alot!
    Delegue Alexandre
    @larousso
    @sorenvalentinjp I ve reproduced the problem and I’ve fixed it, a new release is coming soon
    Delegue Alexandre
    @larousso
    The new client should be published
    sorenvalentinjp
    @sorenvalentinjp
    That is awesome! I will try it out asap and report back to you
    Delegue Alexandre
    @larousso
    Cool ! 😎
    sorenvalentinjp
    @sorenvalentinjp
    Good news! It works!
    Delegue Alexandre
    @larousso
    Good, it was a fucking nightmare I don’t really know how I solved it …
    That ’s great if that works !
    sorenvalentinjp
    @sorenvalentinjp
    Well done, sir 🙂
    Dragan Raicici
    @DraganRaicici
    @larousso Thanks for looking into and fixing the problem! Good job!
    thomasblok98
    @thomasblok98
    Hi :) Is there any way to setup the API-keys to be read-only? We are trying to use Izanami from Angular project, so we are wondering if we can call the API without exposing the key and without setting up a proxy as you suggested in the documentation?
    Mathieu ANCELIN
    @mathieuancelin
    Maybe you can use it with an Otoroshi instance to handle api key
    Otoroshi can issue read only apikeys
    Mathieu ANCELIN
    @mathieuancelin
    still, I don't think it's a very good idea as it leaks too much informations
    Klaus Hebsgaard
    @khebbie
    Hi I am with Thomas Blok - @mathieuancelin how would you then recommend using izanami with angular?
    or would you maybe recommend that we do not use izanami with angular?
    sorenvalentinjp
    @sorenvalentinjp
    @larousso Do you have any experience on this matter?
    Mathieu ANCELIN
    @mathieuancelin
    @khebbie of course you can use izanami with an angular app, or any js app
    but we don't recommand using the api directly from the client app
    to avoid leaking too much information, like the izanami host, the path of the features, the apikeys, etc ...
    we recommand using a backend for frontend pattern
    Mathieu ANCELIN
    @mathieuancelin
    but of course you can do whatever you want :) nothing prevents you to use izanami directly from your angular app
    and you can use Otoroshi to handle same host issues, cors issues, read only apikeys, etc ...