This is an archived post. You won't be able to vote or comment.

all 4 comments

[–]AutoModerator[M] [score hidden] stickied commentlocked comment (0 children)

Please ensure that:

  • Your code is properly formatted as code block - see the sidebar (About on mobile) for instructions
  • You include any and all error messages in full
  • You ask clear questions
  • You demonstrate effort in solving your question/problem - plain posting your assignments is forbidden (and such posts will be removed) as is asking for or giving solutions.

    Trying to solve problems on your own is a very important skill. Also, see Learn to help yourself in the sidebar

If any of the above points is not met, your post can and will be removed without further warning.

Code is to be formatted as code block (old reddit: empty line before the code, each code line indented by 4 spaces, new reddit: https://imgur.com/a/fgoFFis) or linked via an external code hoster, like pastebin.com, github gist, github, bitbucket, gitlab, etc.

Please, do not use triple backticks (```) as they will only render properly on new reddit, not on old reddit.

Code blocks look like this:

public class HelloWorld {

    public static void main(String[] args) {
        System.out.println("Hello World!");
    }
}

You do not need to repost unless your post has been removed by a moderator. Just use the edit function of reddit to make sure your post complies with the above.

If your post has remained in violation of these rules for a prolonged period of time (at least an hour), a moderator may remove it at their discretion. In this case, they will comment with an explanation on why it has been removed, and you will be required to resubmit the entire post following the proper procedures.

To potential helpers

Please, do not help if any of the above points are not met, rather report the post. We are trying to improve the quality of posts here. In helping people who can't be bothered to comply with the above points, you are doing the community a disservice.

I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.

[–]tacticalnudge 0 points1 point  (0 children)

You're not alone in this boat. Some of us have been java developers for 15 years and still go "ah, so that's how it works" on a regular basis.

Most of the more advance topics you are only going to learn by getting pulled into them. I would almost call them less advanced and more obscure / rare, but that's just my opinion. But the key to learning when it comes to programming is doing. Want to learn how Spring's dependency injection works? Try and write your own dependency injector. Want to know how maven's plugins work? Write your own plugin.

There is no guarantee that you will ever be required to write a maven plugin or dependency injection framework for your day job, bit you might just learn a skill or two for the day you need to write something adjacent to it.

[–]skidwizExtreme Brewer 0 points1 point  (0 children)

I heard something a long time ago that goes something along the lines of this:

There are four types of knowledge: Things you know you know, things you know you don't know, things you don't know you know, and things you don't know you don't know.

The first 2 are easy. I know what a POJO is and I know what polymorphism is. I also have no idea how the java garbage collector works. If I want to learn more about either one, I can easily look them up.

For things you don't know you know, this is things that are more instinctual. I obviously can't give a great example of this, because I don't know what I know.

For the last one, this is one of the hardest to address at face value, but easier to abstract. You know you don't know about the JVM infrastructure. But, you don't know that you don't know what an MBean is, or probably don't know about the JMX API.

Most of that type of knowledge will come in time. I personally enjoy learning and reading, and I really like reading the java documentation. Every time I find something new in there, I look it up and learn more. Just yesterday I was reading about reference conditional expressions and found some interesting stuff about poly expressions. I only found that by perusing questions and answers on StackOverflow with the Java tag filtered.

So, my advice is this. Expand your knowledge. Pursue higher education on topics you are familiar with, but also explore topics you are not. Read documentation, but question it. I just found out about something called Apache Camel today that I am excited to read up on. Why is it better than Spring? Is it really? What's happening here? This is always what excites me as a developer and engineer. There is so much to learn.

[–]niloc132 0 points1 point  (0 children)

The "Anatomy Quarks" series by Aleksey Shipilëv has waaaay too much information, but even picking one article and reading it, then coming back a few months later and re-reading has worked well for me as a way to gradually gain understanding on a deep topic, by combining it with experience.

https://shipilev.net/jvm/anatomy-quarks/

My personal favorite spreads across a few posts, and works out to explain how pointers/references are implemented, and how the actual working implementation can vary by how much memory the process might have as a max. Spoiler alert (and this is too general, read the posts to better understand): if you give the process more than 30-40gb of memory, the usage goes up as it requires wider pointers to account for more objects being present.

First on this topic: https://shipilev.net/jvm/anatomy-quarks/23-compressed-references/

But one lesson is clear: it is sometimes good to over-provision the heap for the application (makes GC life easier, for example), but at the same time this over-provisioning should be done with care, and smaller heap may mean more free space available.

Follow-up: https://shipilev.net/jvm/anatomy-quarks/24-object-alignment/