Categories
Programming

How fix Jmeter on a Mac ? Could not initialize class org.apache.jmeter.gui.util.FileDialoger

If you are facing the following error

2021-07-14 11:31:46.861 java[1419:13909] JavaNativeFoundation: GetGlobalVM: Failed to locate @rpath/libjvm.dylib for JNI_GetCreatedJavaVMs(). A JVM must be loaded before calling this function.

2021-07-14 11:31:46.979 java[1419:13909] JavaNativeFoundation: GetGlobalVM: Failed to locate @rpath/libjvm.dylib for JNI_GetCreatedJavaVMs(). A JVM must be loaded before calling this function.

Uncaught Exception java.lang.IllegalAccessError: class com.github.weisj.darklaf.ui.filechooser.DarkFilePaneUIBridge$DetailsTableModel (in unnamed module @0x157632c9) cannot access class sun.awt.shell.ShellFolder (in module java.desktop) because module java.desktop does not export sun.awt.shell to unnamed module @0x157632c9 in thread Thread[AWT-EventQueue-0,6,main]. See log file for details.
Uncaught Exception java.lang.NoClassDefFoundError: Could not initialize class org.apache.jmeter.gui.util.FileDialoger in thread 
Thread[AWT-EventQueue-0,6,main]. See log file for details.

The problem is that the team Dracula is failing

Solution is right below to change it to System

Jmeter => Look and Feel => System

Categories
Continuous Integration/Development Programming

SENIOR MOTTO

  • Is it going to fix something or make it more performant?
  • Can we afford it breaking what’s already working?
  • Does it require rewriting a lot of tests?
  • Do we really need to make that change?

From Mohamed Said – Laravel Team

Categories
Programming

Model and Reward Vulnerability on Your Team

Today’s Tip 
Model and Reward Vulnerability on Your Team
For a team to innovate, people must be willing to disagree, dissent, and challenge the status quo. As a leader, it’s your job to set the conditions for this kind of intellectual bravery. First, check yourself: Make sure you reward vulnerability, rather than punish it, and be mindful of the signals you’re sending, implicitly or explicitly, that discourage disagreement or outside-the-box thinking. Next, encourage your team members to think beyond their role and function. You can also specifically assign someone on your team to play the role of devil’s advocate — their job is to challenge a course of action or find flaws in a proposed decision. Make sure you rotate that role so you can get a variety of perspectives. Whenever you reject a suggestion, express gratitude for the idea and explain your reasoning. Finally, model vulnerability by sharing your mistakes, asking questions, and admitting what you don’t know. Laying the groundwork for open and honest discussions could help your team come up with your company’s next great idea.
This tip is adapted from “To Foster Innovation, Cultivate a Culture of Intellectual Bravery,” by Timothy R. Clark
Categories
Programming

How to Recognize Worthy Programming Tasks ?

Nowadays, IT departments have been jam-packed with a lot of nonsense and therefore a lot of Jira tickets, if you see what I mean. Here is a way to quickly assess the necessity of a task or a project to be executed. It is important to raise these questions during preliminary meetings. Once the project is launched, it will be difficult to backpedal according to my experience. Also great find in this tweet great ideas on how to tackle this question https://twitter.com/sebdedeyne/status/1271370141683638273

  • Is it going to fix something ?
  • Can we afford to break what’s already working ?
  • Do we really need to make that change ?
  • Is it going to improve performance ?

Here are the most critical questions :

  • How will this make users/customer live better ?
  • How is it going to make our developers lives better ?

Although these questions above may seem rational and logical, they can easily and will be easily swept away by some great irresponsible political bluffer developer/manager mentioning the security of a system or application. The word is dropped : Security. The winning argument, the selling point to any individual and to any of our dear IT companies, FEAR.

Although most of our infrastructure are covered with firewalls, proxies, CDN and heavy monitoring systems – I have seen Fear win the argument even if the chance of its occurring was inexistent

David Raleche

Categories
Programming Programming Language

What are VI / VIM editor helper commands ?

VIM-helper

https://devhints.io/vim

https://vim.rtorr.com/

vi command description

0 move to beginning of the current line $ move to end of line H move to the top of the current window (high) M move to the middle of the current window (middle) L move to the bottom line of the current window (low) 1G move to the first line of the file 20G move to the 20th line of the file G move to the last line of the file

SAVE QUIT

:wq or :x or ZZ - write (save) and quit

GO TO LINE

:n 	Go to line n
nG 	Go to line n

COPY

yy - yank (copy) a line
2yy - yank (copy) 2 lines
yw - yank (copy) the characters of the word from the cursor position to the start of the next word
y$ - yank (copy) to end of line

Paste

p - put (paste) the clipboard after cursor
P - put (paste) before cursor

DELETE

dd - delete (cut) a line
2dd - delete (cut) 2 lines
dw - delete (cut) the characters of the word from the cursor position to the start of the next word
D - delete (cut) to the end of the line
d$ - delete (cut) to the end of the line
x - delete (cut) character

Cursor movement

h - move cursor left
j - move cursor down
k - move cursor up
l - move cursor right
H - move to top of screen
M - move to middle of screen
L - move to bottom of screen
w - jump forwards to the start of a word

Working with multiple files

:e file - edit a file in a new buffer
:bnext or :bn - go to the next buffer
:bprev or :bp - go to the previous buffer
:bd - delete a buffer (close a file)
:ls - list all open buffers
:sp file - open a file in a new buffer and split window
:vsp file - open a file in a new buffer and vertically split window
Ctrl + ws - split window
Ctrl + ww - switch windows
Ctrl + wq - quit a window
Ctrl + wv - split window vertically
Ctrl + wh - move cursor to the left window (vertical split)
Ctrl + wl - move cursor to the right window (vertical split)
Ctrl + wj - move cursor to the window below (horizontal split)
Ctrl + wk - move cursor to the window above (horizontal split)

Search and replace

/pattern - search for pattern
?pattern - search backward for pattern
\vpattern - 'very magic' pattern: non-alphanumeric characters are interpreted as special regex symbols (no escaping needed)
n - repeat search in same direction
N - repeat search in opposite direction
:%s/old/new/g - replace all old with new throughout file
:%s/old/new/gc - replace all old with new throughout file with confirmations
:noh - remove highlighting of search matches

Search in multiple files

:vimgrep /pattern/ {file} - search for pattern in multiple files

e.g.:vimgrep /foo/ */

:cn - jump to the next match
:cp - jump to the previous match
:copen - open a window containing the list of matches
Categories
Perl Programming Programming Language

Can’t locate URI/URL.pm in @INC (@INC

yum install perl-CPAN.noarch
cpan install URI

Or

sudo yum install perl-libwww-perl
yum install perl-XML-SAX.noarch

No you are ready to go !

Categories
General Operating System Programming Technical

Unix – Composer Issue

Problem

[ErrorException]                                                                          

“continue” targeting switch is equivalent to “break”. Did you mean to use “continue 2”?

SOLUTION

#1 composer self-update

#2 composer update

Categories
Programming

Easy to update Drupal 7 latest security modules

ERROR
drupal Notice: Undefined variable: not_empty_panel in include() (line 15 of /sites/all/themes/garbage/nucleus/nucleus/tpl/panel.tpl.php).

Solution

Go to settings.php

go to
yourwebsite.com/update.php

455 vim sites/default/settings.php
457 yum search gd
458 yum install php73-gd.x86_64

459 service httpd restart
460 vim sites/default/settings.php

$update_free_access = FALSE;
to
$update_free_access = TRUE;

Execute again
yourwebsite.com/update.php

Categories
Continuous Integration/Development Programming Web API

How to step by step implement Continuous Integration and Continuous Development in your software team ?

Fast development and Integration according to David Raleche – Process

 

 

 

QA

  • Introducing new bugs after making a change (No proper regression test)
  • Increase Automation overall
  • Lack of transparency
  • Improve quality and testability
  • No Proper Api documentation (Swagger)

Developers

  • Duplicate code throughout the program
  • Reading or writing code which is difficult to understand (PSR-2)
  • No Peer Programming (Code Review) in place (Pull Request)

 

  • CLEAN CODE

 

  • DRY do not repeat yourself
  • KISS – Keep it Stupid Simple
  • PSR-2 Code Styling
  • PSR-3 Log for debug purposes
  • PSR-4 Comment Code Properly
  • Function no exceeding 40 lines

 

  • No ERRORS

 

  • PHP Code
    • No Errors
    • No Warnings
    • No Notices
  • Unit Testing – 2 per api calls

 

  • CREATE Functional API Test

 

    • 3 positive tests
    • 3 negatives

 

 

  • Final API Documentation (swagger)

 

 

  • Check PHP logs (Nagios)
    • PHP Code
      • No Errors
      • No Warnings
      • No Notices

 

  • Execute Regression Testing

  • Make sure unit testing reach out full Code coverage
Categories
Programming Scalability Symfony

Symfony Profiler – enjoy programming – symfony helper

http://symfony.app/_profiler