Is there any way to be invisible to just one user on my Pidgin buddy list, and visible to everyone else? It is a Yahoo Messenger user in case that matters.
We are having a problem with our web application, and are currently monitoring performance via munin. We have defined a list of URLs that are causing problems, and am hoping for munin to find out from the apache logs when those urls are being hit. Does anyone know how to set this up? Thanks! :)
what do the various USB charge while sleeping modes mean? my new laptop has these sleep while charging modes :
mode 4
mode 3
mode 2
mode 1
the list box doesn't tell me what these modes mean or do. I noticed that my iphone is charging really slowly on mode 4. What is it going to do to my power consumption if I change it to something like 1 or 2 ?
My goal: given a list of files on local server, show any differences to the files with the same absolute path on remote server; e.g. compare local /etc/init.d/apache to same file on remote server.
"Difference" for me means different checksum. I don't care about file modification times. I also do not want to sync the files (yet); only show the diffs.
I have rsync 3.0.6 on both local and remote servers, which should be able to do what I want. However, it is claiming that local and remote files, even with identical checksums, are still different.
Here's the command line:
$ rsync --dry-run -avi --checksum --files-from=/home/me/test.txt --rsync-path="cd / && rsync" / me@remote:/
where:
"me" = my username; "remote" = remote server hostname
current working directory is '/'
test.txt contains one line reading "/etc/init.d/apache"
OS: Linux 2.6.9
Running cksum on /etc/init.d/apache on both servers yields the same result. The files are the same.
However, rsync output is:
me@remote's password:
building file list ... done
.d..t...... etc/
cd+++++++++ etc/init.d/
<f+++++++++ etc/init.d/apache
sent 93 bytes received 21 bytes 20.73 bytes/sec
total size is 2374 speedup is 20.82 (DRY RUN)
The output codes (see http://www.samba.org/ftp/rsync/rsync.html) mean that rsync thinks
/etc is identical except for mod time
/etc/init.d needs to be changed
/etc/init.d/apache will be sent to the remote server
I don't understand how, with --checksum option, and the files having identical checksums, that rsync should think they're different. (I've tried with other files having identical mod times, and those files are not flagged as different.)
I did run this in /, and made sure (AFAIK) that it's run remotely in /, so even relative pathnames will still be correct.
I ran rsync with -avvvi for more debug info, but saw nothing remarkable.
I'm wondering:
is rsync still looking at file mod times, even with --checksum?
am I somehow not setting up the path(s) right?
what am I doing wrong?
I have a spring scheduled job (@Scheduled) that sends emails from my system according to a list of recipients in the DB.
This method is annotated with the @Scheduled annotation and it invokes a method from another interface, the method in the interface is annotated with the @Transactional annotation.
Now, when i invoke the scheduled method manually, it works perfectly. But when the method is invoked by spring scheduler i get the LazyInitFailed exception in the method implementing the said interface.
What am I doing wrong?
code:
The scheduled method:
@Component
public class ScheduledReportsSender {
public static final int MAX_RETIRES = 3;
public static final long HALF_HOUR = 1000 * 60 * 30;
@Autowired
IScheduledReportDAO scheduledReportDAO;
@Autowired
IDataService dataService;
@Autowired
IErrorService errorService;
@Scheduled(cron = "0 0 3 ? * *") // every day at 2:10AM
public void runDailyReports() {
// get all daily reports
List<ScheduledReport> scheduledReports = scheduledReportDAO.getDaily();
sendScheduledReports(scheduledReports);
}
private void sendScheduledReports(List<ScheduledReport> scheduledReports) {
if(scheduledReports.size()<1) {
return;
}
//check if data flow ended its process by checking the report_last_updated table in dwh
int reportTimeId = scheduledReportDAO.getReportTimeId();
String todayTimeId = DateUtils.getTimeid(DateUtils.getTodayDate());
int yesterdayTimeId = Integer.parseInt(DateUtils.addDaysSafe(todayTimeId, -1));
int counter = 0;
//wait for time id to update from the daily flow
while (reportTimeId != yesterdayTimeId && counter < MAX_RETIRES) {
errorService.logException("Daily report sender, data not ready. Will try again in one hour.", null, null, null);
try {
Thread.sleep(HALF_HOUR);
} catch (InterruptedException ignore) {}
reportTimeId = scheduledReportDAO.getReportTimeId();
counter++;
}
if (counter == MAX_RETIRES) {
MarketplaceServiceException mse = new MarketplaceServiceException();
mse.setMessage("Data flow not done for today, reports are not sent.");
throw mse;
}
// get updated timeid
updateTimeId();
for (ScheduledReport scheduledReport : scheduledReports) {
dataService.generateScheduledReport(scheduledReport);
}
}
}
The Invoked interface:
public interface IDataService {
@Transactional
public void generateScheduledReport(ScheduledReport scheduledReport);
}
The implementation (up to the line of the exception):
@Service
public class DataService implements IDataService {
public void generateScheduledReport(ScheduledReport scheduledReport) {
// if no recipients or no export type - return
if(scheduledReport.getRecipients()==null || scheduledReport.getRecipients().size()==0 || scheduledReport.getExportType() == null) {
return;
}
}
}
Stack trace:
ERROR: 2012-09-01 03:30:00,365 [Scheduler-15] LazyInitializationException.<init>(42) | failed to lazily initialize a collection of role: com.x.model.scheduledReports.ScheduledReport.recipients, no session or session was closed
org.hibernate.LazyInitializationException: failed to lazily initialize a collection of role: com.x.model.scheduledReports.ScheduledReport.recipients, no session or session was closed
at org.hibernate.collection.AbstractPersistentCollection.throwLazyInitializationException(AbstractPersistentCollection.java:383)
at org.hibernate.collection.AbstractPersistentCollection.throwLazyInitializationExceptionIfNotConnected(AbstractPersistentCollection.java:375)
at org.hibernate.collection.AbstractPersistentCollection.readSize(AbstractPersistentCollection.java:122)
at org.hibernate.collection.PersistentBag.size(PersistentBag.java:248)
at com.x.service.DataService.generateScheduledReport(DataService.java:219)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:616)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:309)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:183)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:150)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:110)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:202)
at $Proxy208.generateScheduledReport(Unknown Source)
at com.x.scheduledJobs.ScheduledReportsSender.sendScheduledReports(ScheduledReportsSender.java:85)
at com.x.scheduledJobs.ScheduledReportsSender.runDailyReports(ScheduledReportsSender.java:38)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:616)
at org.springframework.util.MethodInvoker.invoke(MethodInvoker.java:273)
at org.springframework.scheduling.support.MethodInvokingRunnable.run(MethodInvokingRunnable.java:65)
at org.springframework.scheduling.support.DelegatingErrorHandlingRunnable.run(DelegatingErrorHandlingRunnable.java:51)
at org.springframework.scheduling.concurrent.ReschedulingRunnable.run(ReschedulingRunnable.java:81)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
at java.util.concurrent.FutureTask.run(FutureTask.java:166)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$101(ScheduledThreadPoolExecutor.java:165)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
at java.lang.Thread.run(Thread.java:636)
ERROR: 2012-09-01 03:30:00,366 [Scheduler-15] MethodInvokingRunnable.run(68) | Invocation of method 'runDailyReports' on target class [class com.x.scheduledJobs.ScheduledReportsSender] failed
org.hibernate.LazyInitializationException: failed to lazily initialize a collection of role: com.x.model.scheduledReports.ScheduledReport.recipients, no session or session was closed
at org.hibernate.collection.AbstractPersistentCollection.throwLazyInitializationException(AbstractPersistentCollection.java:383)
at org.hibernate.collection.AbstractPersistentCollection.throwLazyInitializationExceptionIfNotConnected(AbstractPersistentCollection.java:375)
at org.hibernate.collection.AbstractPersistentCollection.readSize(AbstractPersistentCollection.java:122)
at org.hibernate.collection.PersistentBag.size(PersistentBag.java:248)
at com.x.service.DataService.generateScheduledReport(DataService.java:219)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:616)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:309)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:183)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:150)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:110)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:202)
at $Proxy208.generateScheduledReport(Unknown Source)
at com.x.scheduledJobs.ScheduledReportsSender.sendScheduledReports(ScheduledReportsSender.java:85)
at com.x.scheduledJobs.ScheduledReportsSender.runDailyReports(ScheduledReportsSender.java:38)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:616)
at org.springframework.util.MethodInvoker.invoke(MethodInvoker.java:273)
at org.springframework.scheduling.support.MethodInvokingRunnable.run(MethodInvokingRunnable.java:65)
at org.springframework.scheduling.support.DelegatingErrorHandlingRunnable.run(DelegatingErrorHandlingRunnable.java:51)
at org.springframework.scheduling.concurrent.ReschedulingRunnable.run(ReschedulingRunnable.java:81)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
at java.util.concurrent.FutureTask.run(FutureTask.java:166)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$101(ScheduledThreadPoolExecutor.java:165)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
at java.lang.Thread.run(Thread.java:636)
I use open emails as my todo list in Outlook 2007. For instance, when I look at my Inbox in the morning, I open all emails which I need to respond to, and throughout the day read, respond to and close each one. It's an odd system but it's how I manage my emails.
Are there any addons available which will save open emails and reopen them if Outlook is restarted? I'm looking for behavior like Firefox's tabs, which will reopen each one if the process gets killed.
By default, when you apply changes to a Bugzilla entry, the web interface advances to the next bug in your list.
I would like to disable this feature since it is almost never what I desire, planning to make further updates later. Further, I often update the wrong bug subsequently due to its changing the current bug without my noticing.
How do I configure Bugzilla to not advance like this?
I'm doing some massive DB cleanups at the moment. We have two DBs both approaching 400GB and I'm wanting to split the DB's into departments.
To do that I need to know the total size of mailboxes within an OU. I've run this: http://stackoverflow.com/questions/9796101/exchange-listing-mailboxes-in-an-ou-with-their-mailbox-size but this only gives me a list and I need a combined totalitemsize so know how big I need the new DB's to be.
Thanks
This is my dir list on my NFS:
macbook-pro-andrey-k:Download Andrey$
ls
1289816143_PL_t1181913
1289816171_PL_t1183807
1290117075_BFD_DVD02(Drums)
I can't delete "1290117075_BFD_DVD02(Drums)" using
sudo rm -Rf
1290117075_BFD_DVD02(Drums)
because I get error message
-bash: syntax error near unexpected
token `('
Hlp plz, how can I either rename the dir so that the error message would not show up or delete the dir right away omitting rename procedure?
Thank you.
Just a minor question, but I notice with aircrack when it lists networks, it does not list the encryption type of each network.
Which seems fair enough, as you can use Kismet, however on my machine when I end kismet and the server, the monitor interface is not removed and I cannot remove it manually, which screws with aircrack.
SO, is kismet needed to view encryption types of networks, and if so how do you use it peacefully in unison with aircrack?
I have a Silverlight solution that references a third-party web service. This web service generates XML, which is then processed into objects for use in Silverlight binding. At one point we the processing of XML to objects was done client-side, but we ran into performance issues and decided to move this processing to the proxies in the hosting web project to improve performance (which it did). This is obviously a gross over-simplification, but should work. My basic project structure looks like this.
Solution
Solution.Web - Holds the web page
that hosts Silverlight as well as
proxies that access web services and
processes as required and obviously
the references to those web
services).
Solution.Infrastructure - Holds
references to the proxy web services
in the .Web project, all genned code
from serialized objects from those
proxies and code around those objects
that need to be client-side.
Solution.Book - The particular
project that uses the objects in
question after processed down into
Infrastructure.
I've defined the following Interface and Class in the Web project. They represent the type of objects that the XML from the original third-party gets transformed into and since this is the only project in the Silverlight app that is actually server-side, that was the place to define and use them.
//Doesn't get much simpler than this.
public interface INavigable
{
string Description { get; set; }
}
//Very simple class too
public class IndexEntry : INavigable
{
public List<IndexCM> CMItems { get; set; }
public string CPTCode { get; set; }
public string DefinitionOfAbbreviations { get; set; }
public string Description { get; set; }
public string EtiologyCode { get; set; }
public bool HighScore { get; set; }
public IndexToTabularCommandArguments IndexToTabularCommandArgument { get; set; }
public bool IsExpanded { get; set; }
public string ManifestationCode { get; set; }
public string MorphologyCode { get; set; }
public List<TextItem> NonEssentialModifiersAndQualifyingText { get; set; }
public string OtherItalics { get; set; }
public IndexEntry Parent { get; set; }
public int Score { get; set; }
public string SeeAlsoReference { get; set; }
public string SeeReference { get; set; }
public List<IndexEntry> SubEntries { get; set; }
public int Words { get; set; }
}
Again; both of these items are defined in the Web project. Notice that IndexEntry implments INavigable. When the code for IndexEntry is auto-genned in the Infrastructure project, the definition of the class does not include the implmentation of INavigable. After discovering this, I thought "no problem, I'll create another partial class file reiterating the implmentation". Unfortunately (I'm guessing because it isn't being serialized), that interface isn't recognized in the Infrastructure project, so I can't simply do that. Here's where it gets really weird. The BOOK project CAN see the INavigable interface. In fact I use it in Book, though Book has no reference to the Web Service in the Web project where the thing is define, though Infrastructure does. Just as a test, I linked to the INavigable source file from indside the Infrastructure project. That allowed me to reference it in that project and compile, but causes havoc in the Book project, because now there's a conflick between the one define in Infrastructure and the one defined in the Web project's web service. This is behavior I would expect.
So, to try and sum up a bit. Web project has a web service that process data from a third-party service and has a class and interface defined in it. The class implements the interface. The Infrastructure project references the web service in the Web Project and the Book project references the Infrastructure project. The implmentation of the interface in the class does NOT serialize down, so the auto-genned code in INfrastructure does not show this relationship, breaking code further down-stream. The Book project, whihc is further down-stream CAN see the interface as defined in the Web Project, even though its only reference is through the Infrastructure project; whihc CAN'T see it.
Am I simple missing something easy here? Can I apply an attribute to either the Interface definition or to the its implmentation in the class to ensure its visibility downstream? Anything else I can do here?
I know this is a bit convoluted and anyone still with me here, thanks for your patience and any advice you might have.
Cheers,
Steve
Hello,
CentOS 5.3
After booting up. I am wondering what is the name of the log file that contains if all services where successfully loaded or not?
For example when computer boots you get a list of start services and they can be OK or FAILED.
Is there a log file where this information is kept? I had a look in the following directory /var/log/ but not sure which one will contain the informaiton that I need.
Many thanks for any advice,
In Nautilus "list view" subfolders can be opened by clicking the "+" icon next to it. Would it possible to open all subfolders recursively in one click? I tried various combinations of ctrl/alt/shift-clicking but none seems to work.
I've got an Airport Extreme and an external USB Hard Drive formatted with NTFS. (And a LAN of Windows XP Machines.)
The drive works perfectly when connected directly to a PC.
When it's connected to the AE, however, the Airport Utility sees the drive and lists it in the Disks list, but the drive doesn't appear on the network (as near as I can tell.)
Can the AE handle NTFS formatted disks? The documentation is vague on that point.
I copied a dll to the system32 directory. I want to register it, which requires me to be Administrator. If I right click on cmd.exe and run as Administrator and list the directory, the dll isn't shown. However, if I start cmd.exe normally, I can see the file, but can't register it.
I would like to write things like this in /etc/apt/sources.list:
deb sftp://[email protected]/path other stuff
When I try this, apt-get complains that there is no sftp method for apt:
# apt-get update
E: The method driver /usr/lib/apt/methods/sftp could not be found.
Has anyone written a patch to add the sftp method for apt? All I could find in Google was this spec for Ubuntu.
Thanks for your help.
In windows command prompt, say we are running a command (batch file)
runtest
but we typo as
runtet
Then when we press F8 next time at 'run',it will still pop with 'runtet'.
Is there any way to remove this incorrect command from auto completion list without restarting the cmd prompt? Or a better way to achieve this?
Without restarting because, there are other commands which are relevant for auto completion and also the environment (though it can be set by batch file).
I regularly plug my Macbook Pro into a network at work, but because of the way Mac networking works, my computer's name instantly becomes available to any other Mac on the network. Is there a way to hide my computer's name so that I do not appear on the network list of other people's computers? Also, can I set this up so as a network specific profile? For instance, I would like my computer's name to show up on my home network, but not my work network.
I've got a hard disk that has damaged blocks. I'm now copying it using ddrescue to an external drive.
I've got a file with the list of the damaged blocks, how can I find out which files are located in the damaged blocks?
I have installed Tomcat6 using the 32-bit/64-bit Windows Service Installer download version. In the setup instructions, it is recommended that "For optimal security, the service should be run as a separate user, with reduced permissions". I created a new local/standard user (Tomcat) to run the service. The Tomcat service is listed in my list of Services and it's running under my user profile. However, I can't figure out how to set/change which user to start it as.
I wonder if we can force notepad++ to respect the previous whitespace character when it autoindents a new line:
list[CR][LF]
····item1[CR][LF]
····item2[CR][LF]
--->|
(notepadd++ screenshot recreation showing hidden characters, because I don't have enough reputation to post images, sorry xP)
If I am indenting with tabs I want a tab when notepad++ does an autoindent.
But if I am indenting with spaces, I do want spaces.
The new PC I just finished building has eSATA support. I use a USB stick/thumb drive all the time on my PC for stuff, is there an equivalent available anywhere for eSATA?
Please list one product per post, and provide a link to the manufacturer's product page.
Also see the USB-3 version of this question.
When I'm using auctex with emacs to write LaTeX documents, I would like to be able to add a couple more options to the list of environment types that auctex "recognises" and can autocomplete, namely Theorem, Lemma, Proof, itemize* and a couple of others. Which variable to I need to edit? I have played around in customize-apropos LaTeX and auctex, but I haven't found it.
(lisp code snippet to add to my .emacs would be preferred, I don't quite understand the syntax yete)