it.unimi.dsi.jai4j.JobManager<BubingJob>
, org.jgroups.MembershipListener
, org.jgroups.MessageListener
, org.jgroups.Receiver
public class Agent extends it.unimi.dsi.jai4j.jgroups.JGroupsJobManager<BubingJob>
it.unimi.dsi.jai4j.jgroups.JGroupsJobManager.JAI4JAddress
Modifier and Type | Field | Description |
---|---|---|
static java.lang.String |
JGROUPS_CONFIGURATION_PROPERTY_NAME |
The name of the system property that, if set, makes it possible to choose a JGroups configuration file.
|
static java.lang.String |
JMX_REMOTE_PORT_SYSTEM_PROPERTY |
The name of the standard Java system property that sets the JMX service port (it must be set for the agent to start).
|
protected MessageThread |
messageThread |
|
protected QuickMessageThread |
quickMessageThread |
assignmentStrategy, droppingThreadFactory, identifier2RemoteJobManager, jGroupsChannel, jGroupsGroupName, jGroupsView, jmxServiceURL, jobListener, jobQueue, name, pendingMessagesStrategy, remoteSelf, selfObjectName, weight
Constructor | Description |
---|---|
Agent(java.lang.String hostname,
int jmxPort,
RuntimeConfiguration rc) |
block, close, connect, createJobMessage, createJobMessageFromByteArray, drop, fromByteArray, fromInputStream, getAliveCount, getRemoteJobManagers, getState, getSuspectedCount, isConnected, local, poll, receive, receive, receive, receive, refresh, register, remoteJobManagers, setListener, setState, submit, submit, suspect, toOutputStream, toString, unblock, viewAccepted
public static final java.lang.String JMX_REMOTE_PORT_SYSTEM_PROPERTY
public static final java.lang.String JGROUPS_CONFIGURATION_PROPERTY_NAME
protected final MessageThread messageThread
MessageThread
protected final QuickMessageThread quickMessageThread
QuickMessageThread
public Agent(java.lang.String hostname, int jmxPort, RuntimeConfiguration rc) throws java.lang.Exception
java.lang.Exception
public BubingJob fromString(java.lang.String s)
fromString
in interface it.unimi.dsi.jai4j.JobManager<BubingJob>
fromString
in class it.unimi.dsi.jai4j.jgroups.JGroupsJobManager<BubingJob>
public byte[] toByteArray(BubingJob job) throws java.lang.IllegalArgumentException
java.lang.IllegalArgumentException
public BubingJob fromByteArray(byte[] array, int offset) throws java.lang.IllegalArgumentException
java.lang.IllegalArgumentException
public int getKnownCount()
RemoteJobManager
.
Note that this number will be larger than that returned by JGroupsJobManager.getAliveCount()
if there are suspected agents.
RemoteJobManager
.public void stop()
public void pause()
public void resume()
public void flush() throws java.io.IOException, java.lang.InterruptedException
java.io.IOException
java.lang.InterruptedException
public void addBlackListedIPv4(java.lang.String address) throws ConfigurationException, java.io.FileNotFoundException
ConfigurationException
java.io.FileNotFoundException
public void addBlackListedHost(java.lang.String host) throws ConfigurationException, java.io.FileNotFoundException
ConfigurationException
java.io.FileNotFoundException
public java.lang.String getManager(java.lang.String url) throws it.unimi.dsi.jai4j.NoSuchJobManagerException
public void setDnsThreads(int dnsThreads) throws java.lang.IllegalArgumentException
java.lang.IllegalArgumentException
public int getDnsThreads()
public void setFetchingThreads(int fetchingThreads) throws java.lang.IllegalArgumentException, java.security.NoSuchAlgorithmException, java.io.IOException
java.lang.IllegalArgumentException
java.security.NoSuchAlgorithmException
java.io.IOException
public int getFetchingThreads()
public void setParsingThreads(int parsingThreads) throws java.lang.IllegalArgumentException
java.lang.IllegalArgumentException
public int getParsingThreads()
public void setFetchFilter(java.lang.String spec) throws ParseException
ParseException
public java.lang.String getFetchFilter()
public void setScheduleFilter(java.lang.String spec) throws ParseException
ParseException
public java.lang.String getScheduleFilter()
public void setParseFilter(java.lang.String spec) throws ParseException
ParseException
public java.lang.String getParseFilter()
public void setFollowFilter(java.lang.String spec) throws ParseException
ParseException
public java.lang.String getFollowFilter()
public void setStoreFilter(java.lang.String spec) throws ParseException
ParseException
public java.lang.String getStoreFilter()
public void setResponseBodyMaxByteSize(int responseBodyMaxByteSize)
public long getResponseBodyMaxByteSize()
public void setKeepAliveTime(int keepAliveTime)
public long getKeepAliveTime()
public void setSchemeAuthorityDelay(long schemeAuthorityDelay)
public long getUrlDelay()
public void setIpDelay(long ipDelay)
public long getIpDelay()
public void setMaxUrls(long maxUrls)
public long getMaxUrls()
public void setSocketTimeout(int socketTimeout)
public int getSocketTimeout()
public void setConnectionTimeout(int connectionTimeout)
public int getConnectionTimeout()
public void setRobotsExpiration(long robotsExpiration)
public long getRobotsExpiration()
public void setWorkbenchMaxByteSize(long workbenchSize)
public long getWorkbenchMaxByteSize()
public void setUrlCacheMaxByteSize(long urlCacheSize)
public long getUrlCacheMaxByteSize()
public long getWorkbenchByteSize()
public long getStoreSize()
public long getArchetypes()
public long getArchetypesOther()
public long getArchetypes1xx()
public long getArchetypes2xx()
public long getArchetypes3xx()
public long getArchetypes4xx()
public long getArchetypes5xx()
public java.lang.String getArchetypeOutdegree()
public java.lang.String getArchetypeExternalOutdegree()
public java.lang.String getArchetypeContentLength()
public long getArchetypeContentTypeText()
public long getArchetypeContentTypeImage()
public long getArchetypeContentTypeApplication()
public long getArchetypeContentTypeOthers()
public long getRequests()
public long getResources()
public long getBytes()
public long getReceivedURLs()
public long getDuplicates()
public double getDuplicatePercentage()
public long getReadyURLs()
public long getFetchingThreadWaits()
public long getFetchingThreadTotalWaitTime()
public long getURLsInQueues()
public double getURLsInQueuesPercentage()
public int[] getQueueDistribution()
public long getUnresolved()
public long getBroken()
public double getEntryAverage()
public double getEntryMax()
public double getEntryMin()
public double getEntryVariance()
public int getVisitStates()
public long getResolvedVisitStates()
public long getIPOnWorkbench()
public long getVisitStatesOnWorkbench()
public long getToDoSize()
public int getActiveFecthingThreads()
public int getReadyToParse()
public int getUnknownHosts()
public long getBrokenVisitStates()
public long getBrokenVisitStatesOnWorkbench()
public int getWaitingVisitStates()
public long getVisitStatesOnDisk()
public long getRequiredFrontSize()
public static void main(java.lang.String[] arg) throws java.lang.Exception
java.lang.Exception