Git Product home page Git Product logo

Comments (5)

LeiYangGH avatar LeiYangGH commented on June 19, 2024 1

Hi @kalintsenkov
I deployed in China Ali cloud. Db and web is in the same server.
I use mysql so i modified many db types and i found mysql ef lib cannot set auto increase id correctly, so my db actually cannot correctly setup.

I'll try your ways to use release version as well as skip db init. and feedback.

==========update===========
I just

  1. skipped Initialize
  2. ran dotnet publish -c Release and start the generated binary BlazorShop.Web.Server, and now the load time reduced to 3 seconds.

Not satisfied but progressing...

Do you need a server to host the demo? if you need i can provide my server as a ci live demo server.(i use mysql)

====update===
i also hosted dotnet built in blazor sample project here: http://leiyang.icu:8080/. it loads within 1 second.

from blazorshop.

kalintsenkov avatar kalintsenkov commented on June 19, 2024

Hi, @LeiYangGH,

  1. You should deploy release version
  2. You can skip the db initialization if you remove .Initialize() method from Startup class in Web.Server project
public void Configure(IApplicationBuilder app, IWebHostEnvironment env)
            => app
                .UseExceptionHandling(env)
                .UseValidationExceptionHandler()
                .UseHttpsRedirection()
                .UseBlazorFrameworkFiles()
                .UseStaticFiles()
                .UseRouting()
                .UseAuthentication()
                .UseAuthorization()
                .UseEndpoints()
                .Initialize(); // this one
  1. That's true.
  2. I don't have live demo, but I will add it in future. 🙂
  • Where did you deploy the app? Make sure database and web app are deployed in same region.

from blazorshop.

harirajrv avatar harirajrv commented on June 19, 2024

The latest version code is not working.

Commented the .Initialize();

Only the loading gif is showing, tried Release, and Debug modes with VS.

from blazorshop.

LeiYangGH avatar LeiYangGH commented on June 19, 2024

too long no response. so the test env metioned above might be gone.

from blazorshop.

harirajrv avatar harirajrv commented on June 19, 2024

I took the repository into a new folder then it worked well, this time I used the console window to run it as mentioned in the ReadMe

And I was doing some changes in the CSS and razor HTML files, also I saw the changes I did, it was working normally.

After a while today it's stopped working again, now it's showing only the loading image.

I didn't do anything specific to the environment or C# code.

from blazorshop.

Related Issues (11)

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.