Örnek
Şöyle yaparız
Şöyle yaparız
@Service("myService")
public class MyService implements org.apache.camel.Service {
@Override
public void start() throws Exception {
...
}
@Override
public void stop() throws Exception {
...
}
}
Kullanmak için şöyle yaparız@Autowired
private MyService myService;
@Autowired
private CamelContext context;
@PostConstruct
public void setupCamelContext() throws Exception {
....
context.addService(myService);
}
Hiç yorum yok:
Yorum Gönder