Git Product home page Git Product logo

Comments (10)

siderakis avatar siderakis commented on April 28, 2024

I have seen the same issue when using the newest version of Jetty. I couldn't replicate this; it might be specific to running on Windows. It looks like there might be an issue with loading static resources when using Jetty and Bazel. We are planning to switch the demos to use Maven which might fix this.

In the WORKSPACE file can you try switching the jetty-server version to look like this (lines 119-126):

transitive_maven_jar(
name = "dependencies",
artifacts = [
# "org.eclipse.jetty:jetty-server:9.3.8.v20160314",
# static resources are not found for newer version
"org.eclipse.jetty:jetty-server:jar:9.4.8.v20171121",
]
)

from rejoiner.

bmweller avatar bmweller commented on April 28, 2024

Thanks for the suggestion, I've given that a try and had the same result. Is the resource folder meant to be included in the jar file contents? I noted a change from Dec 17 where BUILD file under the graphqlserver directory specifically dropped that directory as part of the java_binary/data directive and moved into the same directive at the examples directory level... I'm a bazel novice so this probably isn't related

from rejoiner.

siderakis avatar siderakis commented on April 28, 2024

I setup a gradle build for the helloworld graphqlserver example, if you want to try it here are the steps:

  • check out the "gradle" branch
  • cd examples
  • ./gradlew installDist
  • ./build/install/examples/bin/helloworld-graphqlserver
  • visit http://localhost:8080/

from rejoiner.

bmweller avatar bmweller commented on April 28, 2024

Thanks, seems like two maven repo dependacies are unavailable

./gradlew installDist
:helloworldGraphqlServer FAILED

FAILURE: Build failed with an exception.

  • What went wrong:
    Could not resolve all files for configuration ':runtime'.

Could not find com.google.api.graphql:rejoiner:0.0.1-SNAPSHOT.
Searched in the following locations:
https://repo1.maven.org/maven2/com/google/api/graphql/rejoiner/0.0.1-SNAPSHOT/maven-metadata.xml
https://repo1.maven.org/maven2/com/google/api/graphql/rejoiner/0.0.1-SNAPSHOT/rejoiner-0.0.1-SNAPSHOT.pom
https://repo1.maven.org/maven2/com/google/api/graphql/rejoiner/0.0.1-SNAPSHOT/rejoiner-0.0.1-SNAPSHOT.jar

Required by:
project :

Could not find com.google.api.graphql:execution:0.0.1-SNAPSHOT.
Searched in the following locations:
https://repo1.maven.org/maven2/com/google/api/graphql/execution/0.0.1-SNAPSHOT/maven-metadata.xml
https://repo1.maven.org/maven2/com/google/api/graphql/execution/0.0.1-SNAPSHOT/execution-0.0.1-SNAPSHOT.pom
https://repo1.maven.org/maven2/com/google/api/graphql/execution/0.0.1-SNAPSHOT/execution-0.0.1-SNAPSHOT.jar

Required by:
project :

from rejoiner.

siderakis avatar siderakis commented on April 28, 2024

Can you try updating build.gradle to include the snapshots repo.

repositories {
mavenCentral()
mavenLocal()
maven {
url 'https://oss.sonatype.org/content/repositories/snapshots/'
}
}

For example the execution jar is here: http://oss.sonatype.org/content/repositories/snapshots/com/google/api/graphql/execution/0.0.1-SNAPSHOT/execution-0.0.1-20180124.221530-1.jar

from rejoiner.

siderakis avatar siderakis commented on April 28, 2024

I've updated the gradle branch and tested it on a second machine. Seems to be working.

from rejoiner.

bmweller avatar bmweller commented on April 28, 2024

Gradle build now successful, however getting slf4j dependency error on startup

./build/install/examples/bin/helloworld-graphqlserver
SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
SLF4J: Defaulting to no-operation (NOP) logger implementation
SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details.

from rejoiner.

siderakis avatar siderakis commented on April 28, 2024

I got those errors too. Were you able to visit http://localhost:8080 ?

from rejoiner.

siderakis avatar siderakis commented on April 28, 2024

Switching to gradle in #11 should fix this issue. I'm closing this issue, please reopen is the issue persists. Thanks!

from rejoiner.

bmweller avatar bmweller commented on April 28, 2024

my apologies, I had assume it was a fatal error having not printed out the localhost:8080 url. It does work, will close this issue.

from rejoiner.

Related Issues (20)

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.