ServiceRegistrationJpaImpl implements ServiceRegistration { @Override public String toString() { return getServiceType() + "@" + getHost(); } ServiceRegistrationJpaImpl();  ServiceRegistrationJpaImpl(HostRegistrationJpaImpl hostRegistration, String serviceType, String path);  ServiceRegistrationJpaImpl(HostRegistrationJpaImpl hostRegistration, String serviceType, String path,
          boolean jobProducer); Long getId(); void setId(Long id); @Override Date getOnlineFrom(); void setOnlineFrom(Date onlineFrom); @Override String getServiceType(); @Override String getPath(); void setPath(String path); @Override ServiceState getServiceState(); void setServiceState(ServiceState serviceState); void setServiceState(ServiceState state, int triggerJobSignature); @Override Date getStateChanged(); void setStateChanged(Date stateChanged); @Override int getWarningStateTrigger(); void setWarningStateTrigger(int warningStateTrigger); @Override int getErrorStateTrigger(); void setErrorStateTrigger(int errorStateTrigger); @Override boolean isActive(); void setActive(boolean isActive); @Override boolean isOnline(); void setOnline(boolean online); @Override boolean isJobProducer(); void setJobProducer(boolean isJobProducer); @Override boolean isInMaintenanceMode(); @Override String getHost(); HostRegistrationJpaImpl getHostRegistration(); void setHostRegistration(HostRegistrationJpaImpl hostRegistration); @PostLoad void postLoad(); @Override int hashCode(); @Override boolean equals(Object obj); @Override String toString();  }
@Test public void testToString() throws Exception { Job newJob = new JobImpl(3L, "test", "test_org", 0L, "simple", "do", null, DISPATCHING, "localhost", "remotehost", null, null, null, 100L, 200L, "result", 3L, 1L, true, null, 1.5F); JpaJob jpaJob = JpaJob.from(newJob); String jobString = "Job {id:3, operation:do, status:DISPATCHING}"; assertEquals(jpaJob.toString(), jobString); }