Win a copy of Transfer Learning for Natural Language Processing (MEAP) this week in the Artificial Intelligence and Machine Learning forum!

Maciej Kraskiewicz

Greenhorn
+ Follow
since Nov 03, 2017
Maciej likes ...
IntelliJ IDE Spring Java
Cows and Likes
Cows
Total received
1
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
4
Given in last 30 days
1
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Maciej Kraskiewicz

I declared user attribute in Keycloak admin gui


and created mapper for it:



However, when I post in postman for user details
`/auth/admin/realms/master/users/USERID`
In the response body instead if "test":true I get this:


Because of that, while I am using RestTemplate and trying to post for user details I cannot use such dto

because Test is String[] not String or boolean.
What am I doing wrong? I get a list in response not a single value. Can I somehow change the return type of my attribute?
3 weeks ago

Solved the problem,  thank you so much!
But now, well it works differently depending on how I run the application (From IDE or jar).
If I read this file in a Service, how  would you solve this disparity? Create two properties files and use different paths depending on the profile? (Different for ide and jar run?)
Or is there any convention for solving such differences in resources between Ide and jar?
1 month ago
I am trying to use file, when running application as JAR.
When I run application through Intelij, everything is fine. However when I try to run it via jar, I cannot access the file.
I tried to read few topics containing similar matter, but non of them help
(like https://stackoverflow.com/questions/20389255/reading-a-resource-file-from-within-jar or https://stackoverflow.com/questions/403256/how-do-i-read-a-resource-file-from-a-java-jar-file?rq=1
)
Here is my target tree, and resources


When I use


During intelij run, everything works.


In the case of jar, I tried:

and many other. They result in correct path, for example:

  • file:/D:/Projects/myProject/target/classes/static/assets/config/fileName (in case of toExternalForm)
  • /D:/Projects/myProject/target/classes/static/assets/config/fileName (in case of getFile)


  • However all of them results in null InputStream, when I try:


    I get an error:

    java.io.FileNotFoundException: D:\Projects\myProject\target\project-app-1.0.jar\BOOT-INF\classes\static\assets\config\fileName (The system cannot find the path specified)


    When the path in the project-app-1.0.jar when I open it by 7zip is exactly:

    D:\Projects\myProject\target\project-app-1.0.jar\BOOT-INF\classes\static\assets\config\fileName




    This is how my resource handler looks like:
    1 month ago
    Thank you so much for your answer.

    One more thing, as far as I know -> At the moment there are no study guides for OCP 11, am I right? If that is true, should I wait for them? Or maybe it is better to pass OCP 8?
    So by having 1Z0-808 and 1Z0-816 I will get OCP JAVA Se 11 developer title?
    (without  1Z0-815)
    Hello,

    Last year I have passed Exam 1Z0-808 (OCA 8)
    Well, java 8 is a bit old by now, however I wanted to get next certification - OCP.
    My question is:
    can I pass Java SE 11 Programmer II | 1Z0-816 right now? Or do I need to pass OCP 11 before?  (Which forces me to take one more exam?)
    or I should just pass OCP 8.
    Sorry for raising that topic  from dead, but I have got a similar question and I did not want to create a new topic. Is the knowledge gap between OCA and OCP is really so big?

    I just passed OCA with 82%, and I am thinking about my next step. As far as I read OCP Is much, much harder than OCA. Question is, I planned starting Udemy Spring course (Which takes 34h+) and then create some home-project. Fulfilling this plan will take me a few months. After that I wanted to start learning for OCP - hopefully at the end of this year.

    But after reading your posts, I wonder if it would be better to go for OCP straight ahead, so I remember more from OCA. But then I'll get less knowledge which will be usable in my work (I'm junior java developer)
    Thank you Setu, Pete.

    I'd like to know, if there is a big difference between OCA and OCP exam? In terms of knowledge I have to get?
    Is it a much harder exam? Is it worthy to give a try for OCP 8? (I heard that new java versions will now be released every half of the year.)
    2 years ago
    Finally, I passed my Java 8 Oracle Associate Exam! With the result of 82%. I am a Junior Java Developer, so it is quite important for me
    I must say, that during my preparation phase I made section tests after each chapter of 'Mala Gupta' book.
    Then I run whizlab tests.
    Diagnostic - 74%
    Practice I - 83%
    Practice II - 86%
    Practice III - 80%
    Practice IV - 80%
    Practice V - 79%
    Final - 86%

    However, on Whizlab tests, I had many problems with questions about strange methods, which DID NOT appear on the exam. Like String 'copyValueOf(char[] data, int offset, int count)'. Most questions were less tricky than enthuware and I have got the feeling, that Enthuware helped me much more.
    My enthuware results of tests were: (As I said, I made section tests before, so I can be taken as a bit cheating...)

    Foundation - 78%
    Test 1 - 90%
    Test 2 - 81%
    Test 3 - 81%
    Test 4 - 84%
    Test 5 - 87%
    Test 6 - 90%
    Test 7 - 100% :O
    Final test - 86%

    After each test, I was carefully reading explenations and took notes, additionaly I tried to code a bit (At the beginning in IDE, later I switched to notepad++ ). Whole Enthuware team helped me a lot, with explenation in the program, and on the forum.

    Many people said that reall exam is easier, but I did not get that feeling. Maybe questions were a bit less tricky, but stress is making the big difference. During my mock exams I was ready somehow between 15-25 minutes before end, and during real exam I was choosing last answer 3 seconds before the end!

    In the end I passed!
    Now next step before me!
    Do you know if the knowledge gap between OCA and OCP is very big?
    2 years ago
    After mail to the suport, I got the mail with Badge acceptance. Thank you for your help Pete!
    2 years ago
    Thank you!

    How can I issue a badge for youracclaim? I did not get any e-mail from them.
    I signed up and made an account, but I've got no idea how to add badge there.
    2 years ago
    Hello,

    I just passed my OCA java 8 exam!
    On the cert view I can see my scoring, and information about exam. I can print my exam, or send it to anyone by mail. However is there any url of my certification, so I could share it for example on Linkedin? Or anywhere else?
    2 years ago
    Ok, thanks a lot!

    Two more questions,

    Is there a possibility to change the currency? I can see, that I can buy exam only with USD instead of EUR or PLN (My Polish currency.) And because of currency restriction I would not be able to write exam in Poland if I pay by USD.

    What is more, is there a possibility to get an invoice for a company, from my exam?
    Hello,

    Finally i finished learning and doing mock exams, and I would like to pass certification. I know, that there are two ways to register on the exam, one is to Register at Pearson VUE website and buy exam there, the second is to Purchase Exam Voucher from Oracle University and Register at Pearson VUE.
    The problem is, that via first option I would have to choose the date of the exam before payment.
    And in my case, I would like to but a voucher, and choose the date later on. So I should buy voucher at oracle university, and later on, register on Pearson VUE.

    However, on oracle university I cannot choose certain exam. There are strange options like Oracle Certification Proctored Exam or Oracle Certification Master Assignments.

    Which one should I choose for Oracle Certified Associate, Java SE 8?