Giter VIP home page Giter VIP logo

Comments (6)

mordechaim avatar mordechaim commented on June 12, 2024

You need to create a direct download link, instead of the HTML interface
https://www.howtogeek.com/747810/how-to-make-a-direct-download-link-for-google-drive-files/

from update4j.

MatheusMarkies avatar MatheusMarkies commented on June 12, 2024

Failed: SocketTimeoutException: Read timed out
How can I change the timeout time?

from update4j.

mordechaim avatar mordechaim commented on June 12, 2024

The default timeout is 10 seconds defined here which should be well enough for most use cases. (I would assume increasing the timeout won't help, but there's an underlying problem).

You can override it by providing a custom update handler.

from update4j.

MatheusMarkies avatar MatheusMarkies commented on June 12, 2024

Thanks for the replies!
Using DropBox worked perfectly, I was able to download the .zip file.
Something that's still not clear to me is at what point does the Business application start?

from update4j.

mordechaim avatar mordechaim commented on June 12, 2024

First of all you shouldn't zip the assets, the point of update4j is to download just the changed files and load them onto the JVM. By zipping them you have to deal with unzipping and loading yourself.

When the business app starts really depends on your setup. In the default mode it starts right after updating, or right away if you used the "launch first" cli flag

from update4j.

MatheusMarkies avatar MatheusMarkies commented on June 12, 2024

I think the problem is in my business app launcher class, right?
Maybe in the Injection of the Stage component of JavaFx

public class Launcher implements org.update4j.service.Launcher {

    @Override
    public long version() {
        return 0;
    }

    @InjectTarget
    private Stage primaryStage;

    @PostInject
    private void getStartupView() {

    }
    private static Stage stage;

    @Override
    public void run(LaunchContext ctx) {
        System.setProperty("http.keepAlive", "true");
        System.setProperty("prism.forceGPU", "true");
        System.setProperty("file.encoding", "UTF-8");

        Platform.runLater(() -> {
            Thread.currentThread().setContextClassLoader(ctx.getClassLoader());
            stage = primaryStage;
        });

        Platform.runLater(() -> {
            var root = new ApplicationWindow();
            var antialiasing = Platform.isSupported(ConditionalFeature.SCENE3D)
                    ? SceneAntialiasing.BALANCED
                    : SceneAntialiasing.DISABLED;

            Scene scene = new Scene(root, ApplicationWindow.MIN_WIDTH + 80, 768, false, antialiasing);

            Application.setUserAgentStylesheet(new PrimerLight().getUserAgentStylesheet());

            scene.getStylesheets().add(getClass().getResource("/mspm/pages/DashboardCSS.css").toString());

            stage.setScene(scene);

            stage.setTitle("Brasens");

            Image brasensIcon = new Image(getClass().getResource("/mspm/resources/Icone File.png").toString());

            stage.getIcons().add(brasensIcon);
            stage.setScene(scene);

            stage.setOnCloseRequest(event -> {
                Platform.exit();
                System.exit(0);
            });

            stage.setMaximized(true);
            stage.show();
        });

    }

    private static boolean isEmptyDirectory(Path path) throws IOException {

        return false;
    }
}

from update4j.

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.