question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Login Error React UI

See original GitHub issue
Overview of the issue

Cannot log in React with OAUTH2 in Monolyth

Motivation for or Use Case

Out of the box generated code does not work

Reproduce the error
  1. Generate project
  2. Run docker-compose -f src/main/docker/keycloak.yml up (tested to work http://localhost:9080/)
  3. Run gradlew
  4. Run npm start
  5. Log in with default user

Result

image image

JHipster Version(s)

6.8.0

JHipster configuration
.yo-rc.json file
{
  "generator-jhipster": {
    "promptValues": {
      "packageName": "com.somesite.someproj"
    },
    "jhipsterVersion": "6.8.0",
    "applicationType": "monolith",
    "baseName": "someproj",
    "packageName": "com.somesite.someproj",
    "packageFolder": "com/somesite/someproj",
    "serverPort": "8080",
    "authenticationType": "oauth2",
    "cacheProvider": "ehcache",
    "enableHibernateCache": false,
    "websocket": "spring-websocket",
    "databaseType": "mongodb",
    "devDatabaseType": "mongodb",
    "prodDatabaseType": "mongodb",
    "searchEngine": false,
    "messageBroker": false,
    "serviceDiscoveryType": false,
    "buildTool": "gradle",
    "enableSwaggerCodegen": false,
    "embeddableLaunchScript": false,
    "useSass": true,
    "clientPackageManager": "npm",
    "clientFramework": "react",
    "clientTheme": "flatly",
    "clientThemeVariant": "dark",
    "creationTimestamp": 1587919421213,
    "testFrameworks": ["cucumber"],
    "jhiPrefix": "jhi",
    "entitySuffix": "",
    "dtoSuffix": "DTO",
    "otherModules": [],
    "enableTranslation": false,
    "blueprints": []
  }
}
JDL for the Entity configuration(s) entityName.json files generated in the .jhipster directory
JDL entity definitions

Environment and Tools

java version “11.0.7” 2020-04-14 LTS Java™ SE Runtime Environment 18.9 (build 11.0.7+8-LTS) Java HotSpot™ 64-Bit Server VM 18.9 (build 11.0.7+8-LTS, mixed mode)

git version 2.25.1.windows.1

node: v12.0.0

npm: 6.9.0

Docker version 19.03.5, build 633a0ea

docker-compose version 1.25.4, build 8d51620a

INFO! Congratulations, JHipster execution is complete!

JDL for the Entity configuration(s) entityName.json files generated in the .jhipster directory
JDL entity definitions

Environment and Tools

java version “11.0.7” 2020-04-14 LTS Java™ SE Runtime Environment 18.9 (build 11.0.7+8-LTS) Java HotSpot™ 64-Bit Server VM 18.9 (build 11.0.7+8-LTS, mixed mode)

git version 2.25.1.windows.1

node: v12.0.0

npm: 6.9.0

Docker version 19.03.5, build 633a0ea

docker-compose version 1.25.4, build 8d51620a

INFO! Congratulations, JHipster execution is complete!

Browsers and Operating System

Windows 10 Pro Chrome Version 81.0.4044.122 (Official Build) (64-bit) Firefox 75.0 (64-bit)

  • Checking this box is mandatory (this is just to show you read everything)

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:7 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
mraiblecommented, May 2, 2020
1reaction
mraiblecommented, May 2, 2020

@SudharakaP Do you have a link to the PR that updates the docs?

Read more comments on GitHub >

github_iconTop Results From Across the Web

React: How to display error on incorrect user login
First off, in your handleClick() method, you are trying to directly modify your component's state instead of using React's built-in ...
Read more >
React Error Handling and Logging Best Practices
This article will go over best practices for error handling and logging in React for different scenarios. Let's get started.
Read more >
Handling Sign In Error in React - DevCamp
So first let's just test this out, I'm going to type in some wrong credentials. So if I try to log in right...
Read more >
How to show an error message in React - Educative.io
Simple, straightforward method. One way to display error messages is to have a state that stores them. Let's call this state errorMessage :...
Read more >
React Logging and Error Handling Best Practices - Tek-Tools
Understand the relationship between error handling and logging as well as best practices for handling errors in React and logging them ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found