For the best experience on desktop, install the Chrome extension to track your reading on news.ycombinator.com
Hacker Newsnew | past | comments | ask | show | jobs | submit | history | more umjames's commentsregister

Wouldn't u.getA() and u.getB() still be evaluated first so that their values can be passed to the debug method? Without the if statement, how is the debug method not being called?


In the original code, the debug call is guarded by a condition:

  if (log.isDebugEnabled()) { 
    log.debug("{}", expensiveOp(), debugModeOnlyOp()); 
  }
But in the new code, the calls to expensiveOp and debugModeOnlyOp will be called every time this sequence of code is run regardless of the condition:

  log.debug("{}", expensiveOp(), debugModeOnlyOp());
which is equivalent to the old code:

  var x = expensiveOp();
  var y = debugModeOnlyOp();

  if (log.isDebugEnabled()) { 
    log.debug("{} {}", x, y); 
  }
In most languages that do not support macros, it's impossible to correctly state the dependency of expensiveOp & debugModeOnlyOp on the log.isDebugEnabled() flag using log4j's new API.


I think he's saying exactly that. His post is kinda confusing because of how he quoted the article.


u.getA() and u.getB() will still be evaluated. However I believe the conversion of A and B to strings will not be carried out if debug is disabled.

Often it is the conversion to string that is an expensive operation.

Incidentally with lots of lazy loading (Hibernate I'm looking at you...) this can lead to errors only appearing when debug is turned off - not a nice situation to be in.


Or Robert Loggia. I hope they never remake that movie.


I loved Big! And Vice Versa (with Fred Savage). I think I fit their target demographic.


Here's a simple fix:

You currently have the games as <home team> vs <away team>, it would be clearer if it were <away team> at <home team> (with the time zone indicated, preferably eastern time).


Thanks for the input!

My plan was to UTC-ed all the time and present them to the visitor based on their local timezone (so no need to convert PST, EST, or even worse for international visitors).

But the concept of <away team> at <home team> is definitely better! Thanks a lot!


Done! (minus timezone, will be part of another bigger feature).


Isn't the browser a native app on every platform? So obviously a native app can do all the things that you say it can't do.

Could this discussion not degenerate into FUD and mudslinging, please?



This doesn't really explain much.

The way TextMate2 was going, I'd bet it's something like, it wasn't getting done, and the author was too busy or uninterested to continue, so open sourcing it probably is a way that it may actually ever get finished.


I suspect the success of SublimeText was a big part of it too. Everything TM2 promised - today, and cross-platform to boot.


Well, except for the slick UI and TextMate's still ahead on features & bundles. ST2 is promising but it's too early to call this race.


I don't see how TM2's UI differs in any meaningful way to say it looks nicer than ST2


Less appearance than quality of implementation: I tried ST2 for a couple months but the random hangs got old (e.g. the file / symbol search would often hang for noticeable periods of time).


You might try it again. I can positively and unexaggeratedly say that I've never had ST2 hang on me.


I'll give it a try - I spent a bit of time this spring trying to like ST2.


> This doesn't really explain much.

There is a tiny bit more info on the mailing list:

http://lists.macromates.com/textmate/2012-August/035206.html http://lists.macromates.com/textmate/2012-August/035208.html

--------------------------------------------------

> This is very cool, but it calls into question what your plans are for future commercial development (by you and your team) of TM2. Is it a dead parrot?

I will remain active working on TextMate and I hope we can still sell some licenses even though people can now do their own build (w/o any license enforcement).

--------------------------------------------------

> @allan will you (or do you now) work for someone then?

I’m still my own boss and I don’t plan for that to change :)

--------------------------------------------------


You don't think it has anything to do with Sandboxing requirements in the App Store and Mountain Lion having an option not to allow non-App Store applications? I'm seriously asking, not trying to start a flame war here.


Marco talked about the current status of TM2 on Build and Analyze a few weeks ago[1], and from what he said, it sounds like it has some structural performance problems that weren't getting addressed. In addition, he said that requests for bug fixes and features were constantly getting rejected by the developer, which to me hints at either a loss in interest in the project, or a lack of time to devote to developing it.

[1]: http://5by5.tv/buildanalyze/87


The original TextMate isn't on the App Store and I'd have to think the number of people who go into the Security settings and disallow running of non-App Store signed binaries is vanishingly small.


That setting only changes the ability to launch an app right after download by double clicking it. It doesn't actually prevent the program from running, you just have to take more steps to launch it the first time.

However TM is being kept out of the app store for other reasons, such as it's ability to prompt for an administrator password to allow writing to protected files.


Yeah, this is not true. There is a separate setting which controls a pop-up confirming whether or not you want to run an app that you downloaded, the first time you attempt to run it. The setting referred to here actually BLOCKS the running of new non-app-store (or, by default, non-signed) applications.

http://imgur.com/7bduA

Apparently, you can alt-click and select open, but my gut tells me that this was an oversight and will not last long. This feature was touted as a potential way to protect children, and if overriding it doesn't even require entering a password it fails at that pretty badly.


Control-Click. I don't think it is an oversight, because "Manual Override" is touted officially as a feature:

http://www.apple.com/osx/whats-new/features.html#gatekeeper

And even explicitly mentioned in a system dialogue:

http://cdn.arstechnica.net/wp-content/uploads/2012/07/gateke...

I am still not on Mountain Lion, so I don't know if you need to enter a password (which children shouldn't have) or right clicking is enough?



You can always just execute the command:

xattr -d com.apple.quarantine myTrojan.app

Now you can run the application no matter what the Gatekeeper setting is set to. No need to be paranoid. Gatekeeper isn't meant to lock down the Mac against yourself. It is a security feature only.


True. I just hope the day doesn't come when you can't run non-App Store signed binaries. That would be a dark day for users.


That's the day I'll finally try Linux as my full time OS! :P


TextMate 2 could still be distributed outside the Mac App Store, as a signed binary (with a certificate issued by Apple), and regular users wouldn’t need to change the default settings to run it.

You only need to change settings (or right-click and hit Open) if you are running unsigned binaries.


It might make sense if you were setting the computer up for a non-technical user that might install trojans. It also might be the default in the future.


The original had an update today that added signing


I'm pretty sure if you're using Textmate you can figure things like that out.


Thank you, I'm glad I'm not the only one who sees the benefits.

It's true, some jobs are soul-crushing enough that you'd rather not be there. You might have family and/or financial responsibilities that make you have to keep such a job. You may be bootstrapping a business on the side so you can escape from such a job, but in the meantime, you still need your regular paycheck.

Not every job has you working with self-motivated co-workers and great bosses. Some jobs put you in a cube farm in a room where everyone fights over the thermostat. Sometimes you have to head a weekly meeting where you have to explain to other programmers why you get NullPointerExceptions on line 5 when line 4 initializes the variable to null. Some jobs still make you use CVS. The office talk at some jobs is never about learning anything, but it sure is loud and distracting.

If you were offered a chance to work from home and avoid a lot of that, I'm sure you'd also jump at the opportunity. Getting a promotion in such a job isn't worth it.


That can actually turn into a good thing. When you're not facing the other person, you should become better and better at communicating what exactly is the issue. At the very worse this leaves a paper trail that can indicate "see I worked on this"


I'm interested.


Do you mean like the Fog ruby library is an abstraction over several services' APIs?


Yes :-) but I mean at a lower level of abstraction than a ruby library.


Project Awesome is an HTTP proxy which means it's even a higher abstraction than a Ruby library :)

In any case, you should have a look at Libcloud (http://libcloud.apache.org/), jclouds (http://jclouds.org), deltacloud (http://deltacloud.apache.org/) and other libraries. Deltacloud exposes a similar functionality through an HTTP interface. We have recently also started working on "Libcloud REST" which will expose all the Libcloud functionality through an HTTP interface which means you will be able to talk to it through an arbitrary language which can speak HTTP.


The problem is that the boss needs a way to tell if that help is falling on deaf ears. If the help isn't having a sufficiently positive effect, then you have someone who is not qualified to do the work. Is the boss really interested in making his team stronger all-around (not just a few star employees), or does he just not want to have to deal with answering questions from new hires who might be struggling?

I'm in this position right now. I'm not being conceited, but I am in the role of the highly-productive employee. My boss hires people (or we acquire new team members as the result of a company organizational change). Either way, before the new team members start, my boss inevitably asks me to make sure they can do the job. I've never seen anyone in my department fired due to incompetence. Whenever a team member has questions/problems, they almost always end up getting sent to me. It has gotten to the point where I now have to head a weekly developer meeting that is really just a glorified question and answer session.

The problem is that my team members are never weaned off of my help. My boss doesn't seem to care about this. I've overheard him say to people, who were trying to figure things out without having to ask me for help, to just ask me. I understand that it's more important to my boss to just get things done, but that creates an unnecessary dependency on me. I'm not scalable. Hire better employees or take a hands-on approach to training, but don't keep sending them to me all the time.

I can understand why the author's top employees didn't want be bothered with helping those who were struggling. You don't want to be in a position where you have to do your job plus some/most/all of someone else's.


Does Alzheimer's run in your family?

My mom drinks at least 3 big cups of tea daily. There's no way she doesn't have Alzheimer's or some other form of dementia. Although her mother had Alzheimer's also, so maybe caffeine isn't enough to overpower genetics.

I wonder if tea has the same effect as coffee in this case. They both have caffeine.


It was mentioned that the affects of caffeine or decaf coffee alone don't seem to do the same work as caffeinated coffee.


Consider applying for YC's Summer 2026 batch! Applications are open till May 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search:

HN For You