@Storm What Should I Do Now??
if I set a limit on ram and CPU it will use swap or not
No, but it will keep you computers RAM free for other tasks. JB's rider needs to swap because of limit of RAM if it doesn't you probably loose your work while working on it.
is there any safer solution
Hold on... I'll check the web if there's a safer solution.
This might something you that looks promising: Limit memory usage for a single Linux process - Unix & Linux Stack Exchange
is this Good to try ?
Another way to limit this is to use Linux's control groups. This is especially useful if you want to limit a process's (or group of processes') allocation of physical memory distinctly from virtual memory. For example:
cgcreate -g memory:myGroup
echo 500M > /sys/fs/cgroup/memory/myGroup/memory.limit_in_bytes
echo 5G > /sys/fs/cgroup/memory/myGroup/memory.memsw.limit_in_bytes
will create a control group named myGroup, cap the set of processes run under myGroup up to 500 MB of physical memory with memory.limit_in_bytes and up to 5000 MB of physical and swap memory together with memory.memsw.limit_in_bytes. More info about these options can be found here: https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/6/html/resource_management_guide/sec-memory
To run a process under the control group:
cgexec -g memory:myGroup pdftoppm
Note that on a modern Ubuntu distribution this example requires installing the cgroup-bin package and editing /etc/default/grub to change GRUB_CMDLINE_LINUX_DEFAULT to:
GRUB_CMDLINE_LINUX_DEFAULT="cgroup_enable=memory swapaccount=1"
and then running sudo update-grub and rebooting to boot with the new kernel boot parameters.
Looks good in my eye, but you might wait for a second opinion for safty, as I have no intention to test on my machine. I still think it's a bad idea to mess the OS memory allocations system, but that's just my opinion. 
thank You very much, @Storm
Btw I found this on the web
swap - How do I configure swappiness? - Ask Ubuntu
A swappiness setting of zero means that the disk will be avoided unless absolutely necessary (you run out of memory), while a swappiness setting of 100 means that programs will be swapped to disk almost instantly. -In topic
That's good found. I suggest you try that first, as it's easier to reverse if it goes wrong.
So my current swappiness is 60 and it's using 500Mb while rider is active,
I should make to 100 directly or something else
100 is to extreme try 80 first.
in terminal it shows 80

and
when i open it in text it shows 15


sudo nano /proc/sys/vm/swappiness
remember to reboot.
Does it work as expected?
No now using 77%Ram and 268mb swap
Also software runs with too much lag
Sad to hear that. Seems JB's rider is a resource hog, or memory leak perhaps?
Now What To DO????
I'm not sure, buy more RAM 
Perhaps another member would like to share their input on this matter.