« first day (1809 days earlier)      last day (3117 days later) » 

12:05 AM
Hello is anyone online?
 
Hey there, @Matt.
 
12:35 AM
howdy! I have a question about java arrays. are you knowledgeable in this area?
 
/8ball Am I knowledgable about Java arrays?
 
@Michael Cannot predict now
 
You'll have to take a chance.
 
Ok so I have an android app. It's a IR remote control app. I am adding another type of remote, so I need to switch between 2 codesets [24 button, and each button has an array of numbers]
so I have set the array to be like: int[][] code1 = { {1,2,3,4}, {5,6,7,8} }; except it's much bigger but the scheme is code1[0] = button 1. And each button is an array, passed to ConsumerIR transmit (I forget the full name)
But it's not working right... anyway I just discovered the Debug in Android Studio, soo I'm trying to see exactly what is happening. give me asecond
Okay.. On second thought, the problem isn't actually with the array assignment, but rather the logic leading thereto... my bad
 
Arrays start getting confusing once they become N-dimensional, where N > 1.
Try to avoid it, if possible.
 
12:56 AM
Michael, thanks for your help.. it turns out that me being a java noob overlooked that you cannot use ( string1 == "this" ) rather ( string1.equals("this"))
that was the root cause, I thought it was the array but it wasn't! it was never being instantiated
have a good night! :)
 
An all-too-common mistake.
Good night.
 
1:45 AM
Morning java
 
2:00 AM
Two obejcts which are identical must have the same hashcode. But if their .equals() doesn't return 0, then they will be two separate objects in hashtable.
If we consider some other two objects which had returned same value for .equals() , will their hashcodes also becomes same?
Alright. Got this.
6
A: hashcode and equals contract vice versa

Rohit Jain I mean if it is true in the contract we should say "if two objects are equals they may return same hash code but which is not mandatory" No, it should not. This is because, whenever an object is searched let's say in a HashMap or a HashSet, then first it is searched on the basis of hashCod...

 
 
2 hours later…
4:01 AM
Hi everyone
Good morning
 
 
3 hours later…
6:45 AM
Switching from Java Web Development to Desktop development, will it be a wise decision?
I need your(As I consider you have much more experience than me) opinion. @Unihedron @Gemtastic @ItachiUchiha apologies if I bothered you by pinging
 
7:29 AM
@JudeNiroshan That would be a personal choice IMHO
I do both of them ;)
 
@ItachiUchiha Thanks for you input
 
 
1 hour later…
8:41 AM
@JudeNiroshan an apology is not enough
 
9:39 AM
@Unihedron why you gonna be so ruuuuuude ? Ok, Aplogies + Sorry -_-
 
I hate writing Atlassian Plugins
 
@wonderb0lt for what? JIRA ?
 
@JudeNiroshan Stash
No tutorial for 90% of plugin types, reference doesn't contain meainingful examples. And they're using ActiveObjects which can't cope with a OneToMany relationship. Just great.
 
@wonderb0lt first time I heard it. Really nice tool. Are you developing it to just for fun ?
 
internal project at work
 
9:49 AM
what's Stash?
 
On-Premise Bitbucket
 
cool..
 
yup. it's a hammer, as I still use CVS
 
lol,i use svn
 
I'd rather use GitHub enterprise, or GitLab.
first time in a hundred years asking a question on SO, makes sure to post in chat for maximum attention
 
10:04 AM
o/
 
10:23 AM
Morning
 
morn
 
..here is dinner time
 
It's lunch time here, but on the internet, it's always morning
 
soga~
 
And yaay for upvotes
 
10:45 AM
on the internet its always the time you want it to be
 
11:07 AM
@Gemtastic Why check for access before writing?
 
 
2 hours later…
1:36 PM
Morning, Java!
 
> Morning @Michael. ~Java, probably.
 
Heya @Madara
 
@JudeNiroshan you're the rude one here since you're the person who pinged
/me dodges reference
 
Dang it @Uni, stop being rude!!
 
yeah uni
u so rude
 
1:46 PM
How wwuude!
 
Elijah Wood?
 
@wonderb0lt Season finale of rick and morty made me upset
@MadaraUchiha Elijah Wude!
 
@Michael I'll just replace every message I'm going to say with ¯\_(ツ)_/¯ since you don't care enough to say anything helpful in reply anyway
 
Dang it @Uni! Just...dang it!!
 
¯\_(ツ)_/¯
 
1:53 PM
Did you know that there's no word in German for "to shrug".
 
I feel like we're in a bad sitcom...xD
 
@Michael They probably replace "to shrug" with: "to look at in contempt"
 
@Uni Wow, you're really going all the way with this, aren't you?
 
1:57 PM
¯\_(ツ)_/¯
 
Yup. He is.
 
at least I'm not freaking "rude" like some specific people just complain about whenever I judge, even if it's appropriate
 
Haters gonna hate hate hate hate hate hate.
 
¯\_(ツ)_/¯
 
There's a fine line between being honest and being rude.
The boundaries vary between individuals.
 
2:09 PM
@Michael You don't get to choose if someone else is offended. You only get to choose whether you give a fuck about it or not.
5
 
@Madara Mmm.
Off to work. Bye Java!
 
@MadaraUchiha lol brilliant
 
@Unihedron Louis C. K.
The man is a genius
 
2:52 PM
@MadaraUchiha Ahhhh I love that. I live my life by that statement lol
Good Ol' Louis
 
guys
i would like to make a desktop app using java with mvc design
 
please write my website for me.
 
using java swing i think to have this design :
1) view package : (Simple classes with methods setter for design)
2) model package : (Simple classes with methods for database )
3) controller package : ( Jframe classes )

where i am wrong ?
 
 
1 hour later…
4:01 PM
@gtzinos I recommend the Presenter First pattern for client-side UI apps.
 
@gtzinos: the controller should not be a "JFrame class", it should be a controller pure and simple. You will likely not want to have any classes extend JFrame as you rarely need to modify JFrame behavior, but regardless, by mixing control with GUI (something that should be in View) you're giving the class too much responsibility.
 
4:37 PM
so has anyone ever used log4j2 with log4js?
 
... why?
 
was that directed towards me or someone else?
 
yes you
why would anyone use log4j2 with log4js?
 
well since the website uses javascript i wanna log errors and events on there but also wanna log errors and events on the java side.
with the gui being on the web and the main program being on the java application side like the logic
 
you're using nodejs?
 
4:40 PM
nope, just regular javascript
maybe its log4javascript then
 
why are you using javascript for a website?
when you're already using java
 
This is why you should avoid commenting when down-voting an answer.
 
@Unihedron wat
 
@MadaraUchiha assuming partial stack
@HovercraftFullOfEels when someone asks for downvoting reason, flag it as too chatty or NC
 
@HovercraftFullOfEels Done. Removed all comments (plus the answer)
 
4:43 PM
no point wasting your time with stupid people, you can quote me on that - and asking for stuff like that is NC
 
@Unihedron its just the design decision that was made. dont ask
 
@Unihedron Did you seriously just ask why his web application has JavaScript in it?
 
@MadaraUchiha I'm asking why it was made out of Javascript and Java.
 
@Unihedron Because the front-end has to be JavaScript, and they chose Java for the back end
It's not that uncommon, however much I dislike it.
 
@MadaraUchiha yes that is why
 
4:45 PM
so basically, you already assumed what the entire stack is without even a brief hint
you can help out this gentleman with his problem than
 
@Unihedron I haven't yet assumed anything
He said there's no nodejs in his stack, and that he has Java and JavaScript
He also said Java was the server-side
I don't understand where you got confused here.
 
@HovercraftFullOfEels off topic, but there's this specific high rep user who posts crappy regex answers all the time, and spamming "why was this downvoted??????/" comments all over
pretty sure I've net over 50 helpful comment flags from him
 
haha thats what i am gonna do now post crappy questions and ask why was i downvoted
 
@jgr208 As for error logging
 
4:47 PM
oh wait i already do post crappy questions so i just now need to add why was this downvoted :)
 
I don't have a specific error framework for JavaScript
I don't really need it, because I just don't get that many errors
I have a catch-all error handler that POSTs the request to some sort of /errorReporting endpoint, and let the server write it to whatever logger it has defined
Often into a store of some sort
 
gotcha. this is mostly so when customer says i clicked a b c then this happened we can go back and see they did press a b c or if it was actually a d e they pressed instead to get an error
 
@jgr208 Your own unit tests and integration tests need to find those things before the users
If they don't, you need to work on improving your infrastructure.
 
we have already done that. but this is for those one in a million scenarios that just cant be replicated until a very unique situation that is off the wall you can say
 
@jgr208 If you're considering using a fullfledged logging framework, apparently there's a bigger problem than "one in a million"
Because I know what "one in a million" looks like, it's very nice, and not many companies get there.
@jgr208 For context, I email myself all of my exceptions on most of my products
And I get about 3 emails a year
 
4:51 PM
i was just exploring it. wasn't probably gonna go that way probably but wanted some knowldge about it to back up why i would chose against it.
lucky, we can't send emails to us from our application
 
@jgr208 Unlike in Java, any library, and 3rd party, any asset you add on the client-side causes the site to load considerably slower
That is a big problem, and it's an even bigger problem when you consider mobile users with a crappy 3G connection
 
didnt think about that very valid point.
ahhh yes when they have to go on the old EDGE network
 
I think twice and thrice before I add any sort of library to my code, and most of my products today don't have any 3rd party library in them (only my very tuned abstractions)
For instance, jQuery weighs 30kb compressed
 
@Michael & @HovercraftFullOfEels thank you very much guys
 
For users with an EDGE connection downloading at 10kb/s, it would take 3 whole seconds just to download jQuery
Now add 10 more frameworks that every site seems so anxious to add
And you get a fucking mess that no mobile user would ever want to visit.
 
4:54 PM
ah yes we cant really be downloading stuff on the gui side either due to regulations we have on the system
 
@jgr208 You are downloading stuff on the client-side.
 
nope
 
Of course you are.
You're downloading the HTML document and all of the CSS files and JS files and images
 
and have to avoid needing to at all cost
sorry
i meant downloading any 3rd party stuff from an off site server or whateever
 
Those have a very considerable impact.
 
4:56 PM
but the connection is no problem
 
@jgr208 Is it?
Are you sure?
Because I'm not sure, and I'll argue that my servers are stronger than yours
 
nope connection isnt, just needing to be very secure is the problem
 
Regardless of how much things you have from external servers, minimizing the number of requests and the actual file sizes you serve have a very big impact
@jgr208 By now I'm guessing you work on some sort of governmental or corporate thing with secrecy involved
You have a few things to consider in that case, but performance is still definitely one of them.
 
oh yes we are thinking baout that still
 
Do NOT sacrifice UX for security
 
4:59 PM
we dont want to blast the network
 
Server people often think it's ok to do it. Trust me when I tell you, it is NOT.
 
luckily i am not only a server person ;) some of the time
 
@jgr208 Sadly, I'm willing to bet that your supervisors are, or their supervisors are etc.
There are very very few places where client-side folks actually have high ranking management jobs, and not for a good reason
 
surpisingly we are not. we have like 5 or 6 engineers total here and 4 other workers
 
So here is what I recommend that you do, in general points:
Your server should not care which client is connecting to it. Don't rely on the client to do job that the server is supposed to do.
Alternatively, don't do job on the server that's better done in the client.
HTTPS EVERYWHERE
Keep it small, keep it simple. Only add the libraries you need.
Your server should be fast too, don't take too long to respond.
Seriously, HTTPS EVERYWHERE!!!
I don't know where you live, but in many places on the globe there are actually MORE mobile users than desktop users. Take that into consideration.
 
5:03 PM
I disagree with #3 and #6
 
yes only HTTPS if not we dont get approved for use
 
@Unihedron Why?
 
but all very good points
 
@jgr208 What do you mean?
Wait, @jgr208 will you have a login system?
Will you ask of a user to insert their private details?
Will you ask of them, god forbid, to pay you over the application?
 
no login system since its a private network they are on that is impossible really impossible to get on unless you are where the network is
haha no they wont pay over the application
 
5:06 PM
@jgr208 Application isn't web facing?
(That is, you can't access to the internet on the same network?)
 
nope you can not access public internet
 
Proper certificates are expensive; Cheap certificates require the user to accept things they don't understand from a browser scary red dialog.
Most CDNs are free for HTTP. Moving to HTTPS with Cloudflare would cost an additional of $20 per month, for example.
All resources of a HTTPS page must use SSL+ too. That probably includes websockets and API endpoints.
Time is better spent elsewhere.
 
@jgr208 So I'll excuse you from having HTTPS everywhere (although, it's not that much of a pain to have it regardless)
 
No security issue related to the HTTP protocol has been observed yet.
 
@Unihedron Very soon we will get a free, quality service for HTTPS certificates.
@Unihedron Except for, you know, MITM?
 
5:07 PM
@MadaraUchiha that very soon time you're talking about isn't now
 
well it is a requirment anyways so we have to use it anyway and its not a cost to us only our customer
 
@Unihedron No, it's within a month or two.
 
but I do know that
@MadaraUchiha yes
so my stance may change by then, but for now, I'm skeptical about the impact if your site isn't getting ddosed once every month yet
 
TLS adds absolutely nothing to the HTTP protocol, it's still the exact same protocol
@Unihedron How does HTTPS prevent DDoS...?
HTTPS prevents MITM
And MITMs are not a theory, there are proven cases in recent history.
 
@MadaraUchiha it doesn't, but if your site isn't getting that much malicious attention worrying about MITM is OTT
 
5:09 PM
reminds me of mr robot with this talk just started watching that show love it
 
@Unihedron It's not.\
MITM is not targeted against your site
It's targeted against your users
HTTPS doesn't only keep you safe and covers your ass, it helps keep your users' communications safe.
I would never enter my email or password or any other pseudo-secret I have on a site that doesn't offer HTTPS everywhere
Unless it's a specifically made dummy for that site only
Are you kidding me? How would I know that my own ISP isn't listening to me typing this?
Only the fact that I'm connected through HTTPS and WSS
Also, if it's an internal application on a network of which all nodes you control, you can sign the certificate yourself and install it on the nodes in your network
There, easy and free HTTPS.
Admittedly it doesn't mean that much, but it's better than nothing.
 
you can be paranoid but I'm skeptical about worrying over your ISP eavesdropping when security is being discussed
 
@Unihedron I'm not making that up, it happened
8 mins ago, by Madara Uchiha
https://blog.ryankearney.com/2013/01/comcast-caught-intercepting-and-altering-yo‌​ur-web-traffic/
 
1. 2013
2. That *is* an ISP
 
But even if it's not some big conspiracy by the ISP to sell your browsing details to ad companies so that they can make your life miserable, I want to access the app on the train without having some asstwat listen to the crappy unencrypted WiFi.
Can I?
I've gotten (and presented) with a live demonstration on how to take people's password in a train station
 
5:20 PM
yes, you can be paranoid
 
It's so trivial it's frightening
 
@MadaraUchiha even if they use a VPN?
 
So if the risk is low, the gain is high, and the difficulty is none, yeah I'm paranoid.
@Unihedron Again, not talking about their specific user case
13 mins ago, by Madara Uchiha
@jgr208 So I'll excuse you from having HTTPS everywhere (although, it's not that much of a pain to have it regardless)
 
@MadaraUchiha a crappy unencrypted WiFi is highly specific
 
@Unihedron Is it?
 
5:21 PM
Yes.
 
Every cafe I've met, every train station with a wifi, every train with a wifi, every bus with a wifi
Every single one of them has unencrypted WiFi networks that thousands of people use daily to access the internet without blowing their browsing package
 
The train station's wifi here has an unencrypted channel and an encrypted channel under WPA.
 
@Unihedron Not here.
 
ok then, so it's not that specific
 
And you can be damn sure that "Not elsewhere" either, for plenty of definitions for "elsewhere"
Moreover, people can listen on your data connection if they're connected to the same cell tower
I shit you not, I've seen this happen
(On 3G and worse)
Maybe, hopefully it was fixed with LTE
Haven't checked.
So with that in mind, why wouldn't I be paranoid?
Last but not least, being a paranoid doesn't mean they aren't out to get you :)
 
5:25 PM
haha
i dont blame you @MadaraUchiha
 
@jgr208 If you tell me that all communication is either done over a trusted private network, or over an encrypted VPN connection, then HTTPS is not that important.
For anything else, I claim that without it, your users will not feel safe, and justly so.
 
i know we are just forced to do it by the costumer and since they are paying for the certificates we dont complain
 
@jgr208 Sure thing
So leaving the HTTPS matter aside
 
fge
In 2015, an upcoming website without HTTPS is a joke
You can do it, just do it
 
@fge In 2 months, letsencrypt is expected to be live
Apache and Nginx have support for HTTP2 with a simple configuration switch, and all major browsers today already support HTTP2
So yes, things are looking up
I do get and agree with what @Unihedron is saying though. As it stands today, right now, buying an HTTPS certificate that's worth the bytes it takes on disk is costly, and wrongfully so.
Hopefully, that's all about to change.
And all those scammy CA businesses will start crumbling one by one
 
5:29 PM
can always hope
 
fge
Yeah, the CA "business" is a mess
 
Paying $500 a year for a few bytes on some remote hard-drive is a fucking scam, there's no other word for it.
 
anyway, as I was saying, the http protocol is fine. It's usually the users' fault unless the infrastructure support at that place really is a problem, which I don't notice
 
Leaving the HTTPS matter aside,
 
5:32 PM
@jgr208 Your server should be able to serve a browser, a Java client, and a mobile native application.
It's not that hard once you understand what job is up to the server and what is up to the client
Another thing to keep under check is how much bytes of stuff you make your client download, parse and execute.
Aside from that, there's not much advice I can think of :P
 
thank you very much!
 
5:52 PM
http://www.commitstrip.com/en/2015/10/06/before-timestamp-0/
CommitStrip - Blog relating the daily life of web agencies developers
Before timestamp 0
CommitStrip
1444153710
 
6:17 PM
Ola mi amigos
 
Yokoso!
 
So what's this javascript thing I've been hearing about? Do I just set a fancy editor font in IntelliJ?
 

« first day (1809 days earlier)      last day (3117 days later) »