This week's book giveaway is in the HTML Pages with CSS and JavaScript forum.
We're giving away four copies of Testing JavaScript Applications and have Lucas da Costa on-line!
See this thread for details.
Win a copy of Testing JavaScript Applications this week in the HTML Pages with CSS and JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

author name in java files ?

 
Ranch Hand
Posts: 163
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What is wrong in keeping personal name as author name in JAVA source files ?
My Lead asked all our team members to keep our team name as author name (for e.g. XYZ)
If we consider the same programmer works for longer time at the same company and same project:
If the author name consists the actual programmer name then, it will be easy to debug/enhance the program

In general What is the general practice in companies? and what is the suggested approach?
 
Bartender
Posts: 11445
19
Android Google Web Toolkit Mac Eclipse IDE Ubuntu Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This might be because of your company policy.
Check out the Java source code. You can find author names there too.
 
Ranch Hand
Posts: 116
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The team name as author approach seems odd to me. That has not been the practice on any of the projects that I have worked on so far.
 
author and iconoclast
Posts: 24203
43
Mac OS X Eclipse IDE Chrome
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Unless you're publishing the source code outside your organization, including metadata like author name in source files is just lame. That's what source control systems are for.
 
Marshal
Posts: 67420
173
Mac Mac OS X IntelliJ IDE jQuery Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Ernest Friedman-Hill wrote:Unless you're publishing the source code outside your organization, including metadata like author name in source files is just lame. That's what source control systems are for.


Quoted for truth.
 
Ranch Hand
Posts: 1855
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A class usually belongs to one owner, the one who created that class and gave birth to it.
 
author and jackaroo
Posts: 12199
280
Mac IntelliJ IDE Firefox Browser Oracle C++ Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Darya Akbari wrote:A class usually belongs to one owner, the one who created that class and gave birth to it.


I rarely see that in the workplace. I am more used to an individual writing the class and doing any initial modifications needed with it, after which time it can get worked on by anyone else within the organization (although often it is only those within an individual team who do modifications).

The rare occasions I have seen the code base staying with the original creator is when there are not enough unit tests and/or the original author has obfuscated the code (whether deliberately or not). In such cases other developers are often afraid of changing code that they don't own as they are afraid of what they might break. That single author can then become a bottleneck for the entire company - a really bad idea.

Personally I cant see why any company would want to have a single person "own" a class: what happens if that person ever leaves that company (as if that would ever happen!)? Or go on vacation or get sick? It just makes sense to have many people capable of adding features and supporting the code base.

Likewise I can see no reason why a developer would want to be in a position where they "own" classes for as long as they work at a company - talk about career limiting! How on earth could I ever move onto new and exciting projects when I must always own any code I have previously written?

Back to the original issue - I believe, as Ernest & Bear have indicated they believe, that meta data belongs in the code repository for any internal projects.
 
M K Rayapudi
Ranch Hand
Posts: 163
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thank you one and all for your valuable views/comments.
 
There's a hole in the bucket, dear Liza, dear Liza, a hole in the bucket, dear liza, a tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
    Bookmark Topic Watch Topic
  • New Topic