Чашечка Java
Ir al canal en Telegram
Лучшие материалы по Java на русском и английском Разместить рекламу: @tproger_sales_bot Правила общения: https://tprg.ru/rules Другие каналы: @tproger_channels
Mostrar más8 291
Suscriptores
+324 horas
+127 días
-4930 días
Archivo de publicaciones
8 292
How to sort an Array in descending order in Java? Example Tutorial
Sorting an array is one of the common tasks in Programming and you have many algorithms to sort an array, like QuickSort, MergeSort which provides O(NLogN) time performance, and Bucket Sort, Counting...
Read: http://www.java67.com/2016/07/how-to-sort-array-in-descending-order-in-java.html
20 oct 2021, 03:18
8 292
Eclipse IDE 2021-09 Supports Java 17
The Eclipse Foundation released Eclipse IDE 2021-09, a quarterly update of its flagship project, on September 15, 2021. It supports Java 17 through a plugin and improves Java refactoring, code assist, Git history navigation, and the IDE's dark mode. The recently established Working Group has not reversed the decline in sub-project activities.
By Karsten Silz
Read: https://www.infoq.com/news/2021/10/eclipse-ide-java-17/
20 oct 2021, 01:44
8 292
Top 5 Courses to learn DevOps for Experienced Java Developers in 2021 - Best of Lot
Hello guys, you may know that DevOps is one of the most in-demand skills for both big and small organizations. Consequently, DevOps Engineer is also one of the highest-paid technical jobs for people...
Read: http://www.java67.com/2020/06/top-5-courses-to-learn-devops-in-2020.html
20 oct 2021, 01:22
8 292
3 Ways to Return Different Objects from Spring MVC Controller? @RequestMapping and ResponseEntity Example Tutorial
Hello guys, if you want to provide different types from a Controller in Spring MVC and wondering how to do that then you have come to the right place. In the past, I have shared the free...
Read: http://www.java67.com/2021/10/3-ways-to-send-different-content-types.html
19 oct 2021, 11:29
8 292
Хотите изучать Go глубже? Тогда вам на продвинутый онлайн-курс «Golang Developer. Professional»
Перед этим стоит проверить свои знания и пройти тест: https://otus.pw/B3Yj/
А чтобы попробовать учебный процесс заранее, можно сходить на бесплатные вебинары:
— «Demo Day курса»: https://otus.pw/miEg/
— «Примитивы синхронизации»: https://otus.pw/o5JI/
#ad
19 oct 2021, 09:30
8 292
Top 5 Free Amazon Web Services or AWS Courses to Learn in 2021- Best of Lot
Hello guys, if you are thinking about learning cloud technologies or cloud computing, and looking at the various cloud providers like AWS, GCP, or Azure, then you are going in the right direction....
Read: http://www.java67.com/2018/05/top-5-amazon-web-services-or-aws-courses-to-learn-online.html
19 oct 2021, 07:13
8 292
Top 10 Frontend Web Development Skills Beginners Should Learn in 2021 [UPDATED]
Hello guys, if you want to become a frontend developer and wondering which skills you should learn then you have come to the right place. In the past, I have shared free web development courses...
Read: http://www.java67.com/2020/10/best-frontend-skills-web-developer.html
19 oct 2021, 02:47
8 292
Java News Roundup: Grails 5.0, Spring Framework, Hibernate, WildFly and the Kotlin Multik Library
This week's Java roundup for October 11th, 2021 features news from OpenJDK, JDK 18, Spring Framework, Grails 5.0, Micronaut 3.1, Helidon 2.3.4, point and GA releases of Hibernate ORM and Reactive, updates related to the recent GA release of WildFly 25, GraalVM Native Build Tools 0.9.6, Apache Camel 3.11.3, Piranha 21.10.0 and JetBrains introducing the Multik multidimensional array library.
By Michael Redlich
Read: https://www.infoq.com/news/2021/10/java-news-roundup-oct11-2021/
19 oct 2021, 01:45
8 292
Top 5 Courses to learn Docker for Java Programmers in 2021 - Best of Lot
Hello Java programmer, if you want to learn Docker and looking for the best Docker Courses from Java and Spring Boto developer point of view, then you have come to the right place. Earlier, I shared...
Read: http://www.java67.com/2021/04/top-5-courses-to-learn-docker-for-java.html
19 oct 2021, 00:27
8 292
4 канала для тех, кто хочет прокачаться в определённом направлении программирования:
— разработка на Python: @zen_of_python
— мобильная разработка: @mobi_dev
— веб-разработка: @tproger_web
— основы программирования: @prog_point
18 oct 2021, 10:45
20 oct 2021, ~10:47
8 292
Top 10 Frequently asked SQL Query Interview Questions
In this article, I am giving some examples of SQL queries which is frequently asked when you go for a programming interview, having one or two year experience in this field. Whether you go for a Java...
Read: http://www.java67.com/2013/04/10-frequently-asked-sql-query-interview-questions-answers-database.html
18 oct 2021, 10:24
8 292
Ускорение Maven сборки в Docker
Ранее я описал различные методы ускорения ваших Maven сборок.
Сегодня я хотел бы расширить их область применения и сделать то же самое для сборок Maven внутри Docker.
Читать: https://habr.com/ru/post/583600/?utm_campaign=583600
18 oct 2021, 08:38
8 292
SSH – Load key “/Users/username/.ssh/id_rsa.pub”: invalid format
Suddenly the
git pushvia SSH failed, and the remote server returned something like invalid format for the public key id_rsa.pub?
Terminal
git push
Load key "/Users/username/.ssh/id_rsa.pub": invalid format
git@bitbucket.org: Permission denied (publickey).
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
Last week, everything still working fine, unsure what is the root cause of it?
1. Check ~/.ssh/config
Review the ~/.ssh/config file and ensure the IdentityFilepoints to the private key id_rsa, not the public key id_rsa.pub.
Note
For the ~/.ssh/config, the IdentityFileshould point to the private key that the SSH client uses to connect to the remote server (The remote server should have the public key id_rsa.pub`).
The common mistake is put the public key id_rsa.pubas the IdentityFilevalue.
Terminal
cat ~/.ssh/config
Host *
AddKeysToAgent yes
UseKeychain yes
IdentityFile ~/.ssh/id_rsa.pub
2. Solution
Open the ~/.ssh/configfile, update the IdentityFile, and point it to the private key id_rsa.
Terminal
nano ~/.ssh/config
~/.ssh/config
Host *
AddKeysToAgent yes
UseKeychain yes
IdentityFile ~/.ssh/id_rsa
References
* Configure SSH and two-step verification
* Git on the Server – Generating Your SSH Public Key
Read: SSH – Load key “/Users/username/.ssh/id_rsa.pub”: invalid format on Mkyong.com.18 oct 2021, 06:37
18 oct 2021, ~06:38
8 292
Neoflex проводит Hiring Week для Java-разработчиков и системных аналитиков
С 18 по 24 октября Neoflex приглашает Senior Java-разработчиков и системных аналитиков принять участие в Neoflex Hiring Week. Присоединяйся к нашей команде и получай welcome-бонус в размере одного оклада.
Как принять участие в Neo Hiring Week?
• Заполни заявку на сайте;
• Получи подтверждение от рекрутера;
• Пройди техническое собеседование;
• Прими оффер в течение 48 часов и получи welcome-бонус!
Читать: https://habr.com/ru/post/584056/?utm_campaign=584056
18 oct 2021, 06:09
18 oct 2021, ~06:13
8 292
Neoflex Hiring Week
Компания Neoflex ищет Senior Java-разработчиков и системных аналитиков из любого города России. Присоединяйтесь к команде Neoflex и получайте welcome-бонус в размере одного оклада.
Читать: «Neoflex Hiring Week»
18 oct 2021, 05:42
8 292
Maven error – invalid target release: 17
We upgraded the project from Java 11 to Java 17, and
mvn testhits the error compiling invalid target release: 17?
pom.xml
<properties<java.version17
Terminal
mvn test
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.8.1:compile (default-compile)
on project spring-boot-hello: Fatal error compiling: error: invalid target release: 17 -> [Help 1]
The Java version is already 17.
Terminal
java -version
openjdk version "17" 2021-09-14
OpenJDK Runtime Environment Homebrew (build 17+0)
OpenJDK 64-Bit Server VM Homebrew (build 17+0, mixed mode, sharing)
1. Find out the Java version in Maven
The Maven may be using a different Java version to compile the project, and we can use mvn -versionto find out the Maven details.
Terminal
mvn -version
Apache Maven 3.8.3 (ff8e977a158738155dc465c6a97ffaf31982d739)
Maven home: /usr/local/Cellar/maven/3.8.3/libexec
Java version: 11.0.10, vendor: Oracle Corporation, runtime: /usr/local/Cellar/openjdk@11/11.0.10/libexec/openjdk.jdk/Contents/Home
Default locale: en_MY, platform encoding: UTF-8
OS name: "mac os x", version: "11.6", arch: "x86_64", family: "mac"
Try print out the JAVA_HOMEenvironment variable; Maven finds JAVA_HOME for Java to compile.
Terminal
echo $JAVA_HOME
/usr/local/Cellar/openjdk@11/11.0.10/libexec/openjdk.jdk/Contents/Home
The Maven is still using Java 11.
2. Solution – Update JAVA_HOME
Updating the JAVA_HOME environment variable and ensuring it points to the correct JDK.
2.1 For macOS, open the ~/.zshenvand update the JAVA_HOMEto Java 17
The JAVA_HOMEis pointing to Java 11.
~/.zshenv
export JAVA_HOME=$(/usr/libexec/java_home -v 11)
We upgraded the JAVA_HOMEto Java 17.
~/.zshenv
export JAVA_HOME=$(/usr/libexec/java_home -v 17)
2.2 sourcethe ~/.zshenvor reopen the shell to reflect the change of the JAVA_HOME.
Terminal
source ~/.zshenv
2.3 Recheck Maven’s Java version.
Terminal
mvn -version
Apache Maven 3.8.3 (ff8e977a158738155dc465c6a97ffaf31982d739)
Maven home: /usr/local/Cellar/maven/3.8.3/libexec
Java version: 17, vendor: Oracle Corporation, runtime: /Users/yongmookkim/Library/Java/JavaVirtualMachines/openjdk-17/Contents/Home
Default locale: en_MY, platform encoding: UTF-8
OS name: "mac os x", version: "11.6", arch: "x86_64", family: "mac"
Note
For Windows or Linux, find the JAVA_HOMEenvironment variable and ensure it is pointing to the correct JDK.
References
* Maven error – invalid target release: 1.11
* Apache Maven Compiler Plugin
* What is new in Java 17
Read: Maven error – invalid target release: 17 on Mkyong.com.18 oct 2021, 04:51
18 oct 2021, ~04:51
8 292
Top 3 Books to Learn Hibernate for Java Developers in 2021 - Best of Lot
Hello guys, if you want to learn Hibernate and looking for the best Hibernate books to start with then you have come to the right place. In the past, I have shared the best Hibernate courses and...
Read: http://www.java67.com/2017/02/2-best-books-to-learn-hibernate-for-Java-Developers.html
18 oct 2021, 02:57
8 292
Top 6 Python Programming Courses for Beginners to Learn in 2021 - Best of Lot
Hello guys, if you want to learn Python coding in 2021 and looking for the best Python courses then you have come to the right place. There are a lot of resources to learn Python on the web,...
Read: http://www.java67.com/2020/05/top-5-courses-to-learn-python-in-depth.html
18 oct 2021, 00:20
18 oct 2021, ~02:00
8 292
GitHub keep asking for username password when git push
git cloneone of my existing repo (with SSH key added in the Github), modified some files and tried to git push, and it keeps asking for username and password for git pushoperation?
Terminal
git push
Username for 'https://github.com':
Password for 'https://github.com':
GitHub authentication is successful.
Terminal
ssh -T git@github.com
Hi mkyong! You've successfully authenticated, but GitHub does not provide shell access.
1. Password authentication was removed
Even if we enter the correct username and password, Github still does not allow for pushing because the password authentication was removed on August 13, 2021. Please use a personal access token instead.
Terminal
% git push
Username for 'https://github.com': username@gmail.com
Password for 'https://username@gmail.com@github.com':
remote: Support for password authentication was removed on August 13, 2021. Please use a personal access token instead.
remote: Please see https://github.blog/2020-12-15-token-authentication-requirements-for-git-operations/ for more information.
fatal: Authentication failed for 'https://github.com/mkyong/spring-boot/'
2. Use SSH, not HTTPS
The main reason for this problem is mistakenly git clonethe HTTPS URL; we need the SSH URL to use the SSH keys. The solution is to update the .git/configfile, urlvalue to SSH instead of HTTPS.
2.1 Go to the repo directory, open the file .git/config.
.git/config
[core]
repositoryformatversion = 0
filemode = true
bare = false
logallrefupdates = true
ignorecase = true
precomposeunicode = true
[remote "origin"]
url = https://github.com/mkyong/spring-boot
fetch = +refs/heads/*:refs/remotes/origin/*
[branch "master"]
remote = origin
merge = refs/heads/master
2.2 Update the urlfrom HTTPS https://github.com/mkyong/spring-bootto SSH git@github.com:mkyong/spring-boot.git.
Terminal
[core]
repositoryformatversion = 0
filemode = true
bare = false
logallrefupdates = true
ignorecase = true
precomposeunicode = true
[remote "origin"]
url = git@github.com:mkyong/spring-boot.git
fetch = +refs/heads/*:refs/remotes/origin/*
[branch "master"]
remote = origin
merge = refs/heads/master
Done, try git pushagain.
References
* Adding a new SSH key to your GitHub account
* Token authentication requirements for Git operations
Read: GitHub keep asking for username password when git push on Mkyong.com.17 oct 2021, 03:32
17 oct 2021, ~03:54
8 292
15 Machine Learning Interview Questions
Hello guys, if you are preparing for Machine Learning interviews and looking for frequently asked Machine Learning interview questions then you have come to the right place. In this article, I am...
Read: http://www.java67.com/2021/10/15-machine-learning-interview-questions.html
17 oct 2021, 03:17
